Update a webhook subscription

Examples

Let's establish some of our data that will be used in the following examples:

  • Workspace ID: a1405560-c8d3-4b1a-877d-3f449ad95352

  • Organization ID: 823fbfaf-f14e-4693-b55a-8ec1c17d649e

  • Webhook subscription to be updated ID: 0edf722b-93b4-4451-8a5d-4fafba5cdf8b

  • AccessKey: abcd

Deactivating a webhook subscription

If you want to quickly stop receiving event notifications, you can update the webhook subscription status to inactive. The following request exemplify how to proceed.

curl -X PATCH "https://api.bird.com/organizations/823fbfaf-f14e-4693-b55a-8ec1c17d649e/workspaces/{{workspaceId}}/webhook-subscriptions/0edf722b-93b4-4451-8a5d-4fafba5cdf8b" \
-H "Content-Type: application/json" \
-H "Authorization: AccessKey abcd" \
-d '{
  "status": "inactive"
}'

Updating a webhook subscription URL

If you want to change the destination which the event notifications should go, you can update the URL. The following request exemplify how to proceed.

curl -X PATCH "https://api.bird.com/organizations/823fbfaf-f14e-4693-b55a-8ec1c17d649e/workspaces/{{workspaceId}}/webhook-subscriptions/0edf722b-93b4-4451-8a5d-4fafba5cdf8b" \
-H "Content-Type: application/json" \
-H "Authorization: AccessKey abcd" \
-d '{
  "url": "https://webhook.another-example-url/68be485e-5faa-4363-8033-2e3d236830db"
}'

Last updated