Skip to main content
POST
Create webhooks

Authorizations

Authorization
string
header
required

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

Body

application/json

Register an outbound webhook endpoint for the current workspace. Scramble reads these rules to document the request body. Mirrors the validation in the in-app WebhooksController::store.

The platform POSTs a JSON envelope to the registered url whenever a subscribed event fires. When a signing secret is configured the request carries an X-Wachat-Signature header (HMAC-SHA256 of the body).

url
string<uri>
required

Public HTTPS endpoint the platform POSTs events to. Required.

Maximum string length: 2048
name
string | null

Optional friendly label shown in the dashboard.

Maximum string length: 191
secret
string | null

Optional HMAC signing secret. When set, deliveries carry an X-Wachat-Signature header so receivers can verify authenticity.

Maximum string length: 191
active
boolean | null

Whether the endpoint is active and should receive events. Defaults to true.

events
string[] | null

Event names to subscribe to. Omit (or pass [""]) to receive all. Supported events fired by the system: message_received — inbound message received message_sent — outbound message sent message_delivered — outbound message delivered message_read — outbound message read message_failed — outbound message failed broadcast_created — broadcast created broadcast_status_updated — broadcast status changed broadcast_message_status_updated — per-recipient broadcast status changed campaign_created — campaign created campaign_status_updated — campaign status changed campaign_contact_status_updated — per-contact campaign status changed campaign_contact_clicked — campaign contact clicked a link campaign_contact_replied — campaign contact replied contact_opt_in — contact opted in contact_updated — contact updated device_status_updated — device (number) status changed "" — subscribe to every event

Maximum string length: 64

Response

Resource created successfully.

data
any[]
required
meta
string
required