Create Webhook
Register an endpoint to receive real-time event notifications
Creates a new webhook configuration for your organization. Returns a webhook ID and a secret key for signature verification. The secret key is only returned once at creation time — store it securely.
Requires a valid api_key in the JSON request body
Tip: Send {"help": true} as the request body to receive full usage documentation, the complete list of supported events, and best practices directly from the endpoint.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
api_key |
body | string |
Yes | Your Zyntro API key |
org_id |
body | string |
Yes | Your organization UUID |
wh_name |
body | string |
Yes | Display name for the webhook (max 100 characters) |
wh_endpoint |
body | string |
Yes | Destination URL — must be a valid, publicly accessible HTTPS URL |
wh_events |
body | array |
Yes | Array of event slugs to subscribe to. At least one event is required. See Supported Events below. |
wh_auth_type |
body | string |
No | Authentication type for requests to your endpoint: none (default), bearer, basic, api_key, or custom_header |
wh_auth_data |
body | object |
No | Auth credentials — structure depends on auth_type. For bearer: {"value": "your-token"}. For api_key: {"header": "X-Key", "value": "abc"}. For basic: {"username": "...", "password": "..."}. |
wh_timeout |
body | integer |
No | Request timeout in seconds (5-120). Default: 30 |
Request Body
Content-Type: application/json
Example
json
{
"org_id": "YOUR_ORG_ID",
"api_key": "YOUR_API_KEY",
"wh_name": "CRM Sync Webhook",
"wh_events": [
"new_contact",
"form_filled",
"appointment_booked",
"invoice_paid"
],
"wh_timeout": 30,
"wh_endpoint": "https://example.com/zyntro-webhook",
"wh_auth_data": {
"value": "your-bearer-token"
},
"wh_auth_type": "bearer"
}
Code Samples
bash
curl -X POST https://app.zyntrohq.com/public/account/createWebhook \
-H "Content-Type: application/json" \
-d '{
"api_key": "YOUR_API_KEY",
"org_id": "YOUR_ORG_ID",
"wh_name": "CRM Sync Webhook",
"wh_endpoint": "https://example.com/zyntro-webhook",
"wh_events": ["new_contact", "form_filled", "invoice_paid"],
"wh_auth_type": "bearer",
"wh_auth_data": {"value": "your-bearer-token"}
}'
Response
200
Webhook created
json
{
"data": {
"wh_id": "d4e5f6a7-b8c9-0123-defg-456789012345",
"action": "created",
"secret_key": "a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2"
},
"status": "success",
"message": "Webhook created successfully"
}
200
Invalid events
json
{
"hint": "Send {\"help\": true} to see the full list of supported events",
"status": "error",
"message": "Invalid event(s): invalid_event_name"
}
Warning: The secret_key is only returned once — at creation time. It cannot be retrieved later. Store it securely. Use it to verify webhook signatures on incoming payloads via HMAC-SHA256.
Supported Events
| Category | Event Slugs |
|---|---|
| Contact Events | new_contact, contact_email_verified, contact_phone_verified, contact_dnc_added, contact_dnc_lifted, contact_auto_engage_on, contact_auto_engage_off, contact_signal_intercepted, contact_signal_processed |
| Notes & Profile | new_note, new_profile |
| Call Events | new_call_initiated, call_ended, call_failed |
| Email Events | email_sent, email_opened, email_clicked, email_optout, email_bounce, email_complaint, email_reply, email_reply_response_posted |
| SMS Events | sms_sent, sms_delivered, sms_optout, sms_reply, sms_reply_response_posted |
| Appointment Events | appointment_booked, appointment_cancelled, appointment_rescheduled |
| Form & Analytics | form_filled, analytics_event_occurred, analytics_anomaly_detected |
| Content Events | content_posted_to_website, content_posted_to_social, content_produced, video_produced, image_produced |
| Pipeline Events | pipeline_phase_move, pipeline_stage_move, pipeline_action_required, pipeline_action_failed |
| Invoice Events | invoice_generated, invoice_paid, invoice_cancelled, invoice_viewed |
| Subscription Events | subscription.created, subscription.updated, subscription.cancelled, subscription.paused, subscription.resumed, subscription.past_due, subscription.payment.succeeded, subscription.payment.failed, subscription.payment.requires_action |
| Billing Events | wallet_debited, wallet_credited, wallet_balance_low, billing_failed |
| Trigger Billing | trigger.captured, trigger.failed, trigger.pending_client, trigger.client_paid, trigger.enrollment.paused, trigger.enrollment.cancelled, billing_customer.created, billing_customer.suspended |
| CMA Events | cma_report_produced, cma_report_failed, cma_report_sent |
| System Events | account_suspended, terms_violation |
| Webinar Events | webinar_registration, attendee_attended, attendee_no_show, webinar_replay_watched, webinar_feedback_given |
Errors
| Code | Message | Resolution |
|---|---|---|
MISSING_API_KEY |
Missing API Key The api_key is missing. |
Include your API key. |
INVALID_API_KEY |
Invalid API Key No active user matches. |
Verify your key. |
MISSING_FIELDS |
wh_name / wh_endpoint / wh_events is required Required fields are missing. |
Include all required fields. |
INVALID_URL |
Invalid endpoint URL The wh_endpoint is not a valid URL. |
Provide a valid HTTPS URL. |
INVALID_EVENTS |
Invalid event(s): ... One or more event slugs are not recognized. |
Send {"help": true} to see the full list. |
INVALID_ORG |
Invalid organization The org does not belong to the user. |
Verify the org_id. |
INSERT_FAILED |
Failed to create webhook Database insert failed. |
Retry the request. |