Create Or Update Webhook

Register or update the webhook URL for this account.

If a webhook already exists, it will be updated. A new secret is generated each time.

contextLimit: Number of recent messages to include in webhook payloads (0-50, default: 10). Set to 0 to disable history in webhooks.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Headers

X-Sub-Account-IdstringOptional

Target a sub-account. Pass a sub-account ID to scope this request. Omit to use the master account.

Request

This endpoint expects an object.
urlstringRequiredformat: "uri"1-2083 characters
contextLimitinteger or nullOptional
timeoutinteger or nullOptional

Response

Successful Response
idstring
urlstring
secretstring
statusstring
contextLimitinteger
timeoutinteger
createdAtdatetime

Errors

422
Unprocessable Entity Error