Checklist webhooks

Hey,

My app’s listening to changes on cards using webhooks. For the new feature I need to get info about changes to checklists(create/update/delete checklists, create/update/delete check items).

The problem is that when something happens to checklist, webhook data doesn’t contain card data. Seems weird, especially that when there’s any change to check item, webhook data has card data included. I guess it would make sense if both sources sent card data in webhooks(and it would help me a lot :D)

Is there a chance for such change in webhooks api?

Reference:

  • update on check item: webhooks sends info about card, board, checklist and checkitem objects under the “data” key

  • update on checklist: checklist and board info only

Can you elaborate on the differences here? Specifically, what data is missing that you expect to be included?

Here are two webhook payloads - one for addChecklistToCard (something happening to checklist) and one for updateCheckItemStateOnCard (something happening to a check item). They both appear to have the same data:

addChecklistToCard

{
  "card": {
    "id": "5d8bcf47ca1a1914392a3d5b",
    "name": "Test Card",
    "idShort": 531,
    "shortLink": "HcmR6mWs"
  },
  "checklist": {
    "id": "5e5695afff956a7632ae78e3",
    "name": "Ok"
  },
  "board": {
    "id": "586e8f681d4fe9b06a928307",
    "name": "Best Test Board",
    "shortLink": "d2EnEWSY"
  }
}

updateCheckItemStateOnCard

{
  "board": {
    "id": "586e8f681d4fe9b06a928307",
    "name": "Best Test Board",
    "shortLink": "d2EnEWSY"
  },
  "card": {
    "id": "5d8bcf47ca1a1914392a3d5b",
    "name": "Test Card",
    "idShort": 531,
    "shortLink": "HcmR6mWs"
  },
  "checklist": {
    "id": "5e5695afff956a7632ae78e3",
    "name": "Ok"
  },
  "checkItem": {
    "id": "5e5695b0e023568424849b3a",
    "name": "ok",
    "state": "complete"
  }
}

In general, we intentionally send the minimal amount of data necessary for looking up more specific information about the context of an action. Webhooks are intended to be used as a trigger for an integration to go and look up the specific data they need when an action occurs.

Sorry for the unclear description, should’ve added example payload. Here you are:

updateChecklist action

{
  "old" : {
    "name": "Test"
  },
  "checklist": {
    "name": "Test checklist update",
    "id": "5e4bbf940cb5fa6db2fd0e6c"
   },
   "board": {
    "id": "5d66403e07c6ea8d936ed35b",
    "name": "Webhooks test",
    "shortLink": "mBsMXiHm"
   }
}

That payload seems to be missing “card” data - it’s present in both of your examples.
I think it would make sense to add it here as well since checklist is strongly connected with card

Thanks! You’re definitely correct that that action type doesn’t return any card data. I’ll certainly pass along the request to our team to add more, but, as I mentioned, we try to be as lean as possible in sending data related to the change and recommend making a follow-up API call to the checklists endpoint after you receive this action to gather additional information you may need.

In the meantime, if it is critical that you receive the card ID via the webhook, you could add the card ID as a query parameter to the callback URL when creating the webhook. Then, when you receive the webhook, you can parse the query parameters and know which card ID this checklist belongs to.

Thanks for your help :slight_smile:

I’m using board’s webhook so adding card id to it won’t work. I guess I need to wait for the change in API.
Do you think it’s likely that the change will happen soon? It it a matter of days or weeks?

How about next Monday?

1 Like