webhooks

Update

POST
Updates the requested webhook.

Request

This endpoint expects an object.
id
stringRequired
ID for the webhook.
action
enumOptional
The action to update the webhook's status.
Allowed values: activatedeactivate
event_types
objectOptional
secret
stringOptional
If provided, updates the secret that's used when verifying webhook events, which must be between 8 and 32 bytes (inclusive). Otherwise if empty, then a new secret is generated. If the webhook is active, then its status will transition to the 'unverified' state and it won't receive any object events until successfully verified.
url
stringOptional
The webhook's updated URL. If the webhook is active, then the webhook's status will transition to the 'unverified' state and it won't receive any object events until successfully verified.

Response

This endpoint returns an object
webhook
object
POST
1curl -X POST https://api.devrev.ai/webhooks.update \
2 -H "Authorization: <apiKey>" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "id": "don:integration:<partition>:devo/<dev-org-id>:webhook/<webhook-id>"
6}'
200Successful
1{
2 "webhook": {
3 "id": "id",
4 "secret": "secret",
5 "status": "active",
6 "url": "url",
7 "created_date": "2023-01-01T12:00:00Z",
8 "display_id": "display_id",
9 "event_types": [
10 "account_created"
11 ],
12 "modified_date": "2023-01-01T12:00:00Z"
13 }
14}