[RELEASED] New webhook types for sub-item events!

Exciting news! We’re happy to announce a highly requested feature is now available.

You’ve heard of webhooks on main items, but get ready for webhooks on sub-items! :zap:

Sub-item webhooks include the same events as the main item webhooks:

  • When a sub-item is created;
  • When any sub-item column changes;
  • When a sub-item name changes;
  • When an update is posted in sub-items;
  • When a specific sub-item column changes;
  • When a sub-item Status changes;

You can add those recipes from within our Integration Center by using the Webhooks Integration:

For recipes that support sub-items, you’ll be able to select a column from the sub-item level:

You will receive a payload like this, which is identical to the main item’s payload. It will include the subhttps://community.monday.com/c/developers/dev-guides/70-item board ID, which you can use to distinguish between Main items and Sub-items.

Currently, the event type will also be the same as for main items. You can include a query param for your webhook URL when creating webhooks for sub-item events in order to differentiate between updates to main items and subitems.

For example, if my base webhook URL is https://alexscoolwebhook.com/, I can add /?subitemCreate=true to the end of the URL to get the following result:

https://alexscoolwebhook.com/?subitemCreate=true

You will then see the output with this query param included:

To create webhooks for sub-item events via the API, use the following sub-item webhook event types:

  • change_subitem_column_value - equivalent of “When any sub-item column changes”
  • create_subitem;
  • create_subitem_update;
  • change_subitem_name;

Note: At this time, it is not possible to use the API to create a webhook for Sub-item Status column changes, or for a specific Sub-item column change. We recommend creating a “change_subitem_column_value” webhook, and check the column ID that was updated.

In your API call, use the Main Board ID. For example:

mutation {
create_webhook (board_id: 1544542904, url:"yourURL/?yourQueryParam", event: change_subitem_column_value)   {
id
board_id
   }
}

Here’s a cURL example too:

​​curl --location --request POST 'https://api.monday.com/v2' \
--header 'Authorization: yourApiKey' \
--header 'Content-Type: application/json' \
--data-raw '{"query":"mutation { create_webhook (board_id: mainBoardId, url: \"yourWebhookUrl\", event: change_subitem_column_value) { id board_id}}"}'

I hope this helps building more complex workflows with sub-items :slight_smile:

-Alex

3 Likes