What is the default webhook?
The default webhook does not belong to a channel. It applies to every channel in the workspace that has no active webhook of its own, including channels created after it. Use it when all your channels send events to the same system: you register the URL once instead of creating a webhook on each channel. When a channel needs a different destination, create a channel webhook on it, and the default webhook stops applying to that channel.Authentication to your URL, HMAC signing and payload formats work as in the other webhook types. See the Introduction.
Who receives each event
For each event of a channel, Omni Z-API decides once:- The channel has at least one active webhook of its own: only the channel’s webhooks that subscribe to that event receive it. The default webhook receives nothing from that channel.
- The channel has no active webhook of its own: the active default webhooks that subscribe to that event receive it.
status ENABLED and at least one subscribed event, in any format, including CHATWOOT. A channel webhook with status DISABLED does not count: if it is the channel’s only webhook, the default webhook applies to the channel again.
A deleted channel does not receive events through the default webhook.
Accepted events
The default webhook accepts the same events as the channel webhook:
Because the default webhook applies to channels of different types, events are not checked against each channel’s type: an event the channel does not emit simply never arrives.
Template events are not accepted (
422). To receive them, use template webhooks.
Formats
The default webhook acceptspayloadFormat DEFAULT (when omitted) and Z_API. The body you receive is the same as a channel webhook’s in the same format. See Payload structure.
The CHATWOOT format is rejected, because each channel has its own Chatwoot inbox:
Limit per workspace
Each workspace has up to 5 default webhooks, counting enabled and disabled ones. Above that, creation responds422:
Who can manage it
Any valid secret key of an active workspace can manage the default webhook. The ENTERPRISE role is not required. The secret key is still subject to the workspace’s allowed IP list. A deleted workspace gets422 on every route:
404 with {"error": "Webhook not found"}.
When a change takes effect
Creating, updating or deleting a default webhook usually applies from the next event. If there is a delay, the change takes effect within 5 minutes.Management
Create default webhook
Register a URL for the events of every channel.
List default webhooks
See the workspace’s default webhooks.
Get default webhook
Retrieve a specific default webhook.
Update default webhook
Update URL, events, authentication, format or status.
Delete default webhook
Delete a default webhook and free the slot.
Payload structure
Examples of the payloads received for each message type.