Create webhook
Create a new webhook configuration. Maximum 10 webhooks per user.
name, url and events are required. url must be a valid URL and events must contain at least one event. Whitespace is trimmed from url before validation.
Webhooks are automatically disabled after 10 consecutive delivery failures.
API key authentication - use your Zernio API key as a Bearer token
In: header
Webhook name (1-50 characters)
1 <= length <= 50Webhook endpoint URL (must be a valid URL, whitespace trimmed)
uriSecret key for HMAC-SHA256 signature verification
Events to subscribe to (at least one required)
1 <= itemsEnable or disable webhook delivery. Defaults to true when omitted.
trueCustom headers to include in webhook requests
Response Body
application/json
application/json
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.webhooks.createWebhookSettings({ body: { name: 'Example', url: 'https://example.com', events: [ 'post.scheduled', ], },});console.log(data);{
"success": true,
"webhook": {
"_id": "string",
"name": "string",
"url": "http://example.com",
"secret": "string",
"events": [
"post.scheduled"
],
"isActive": true,
"lastFiredAt": "2019-08-24T14:15:22Z",
"failureCount": 0,
"customHeaders": {
"property1": "string",
"property2": "string"
}
}
}{
"error": "Unauthorized"
}Get inbox messaging volume GET
Daily inbox messaging volume + breakdowns. Folds the raw messaging events into three projections so the client can render the volume chart, KPI strip, and per-platform stacked bar from a single call. Max date range is 365 days.
List webhook delivery logs GET
Retrieve recorded webhook delivery attempts for the authenticated user, most recent first. Logs are retained for 30 days. Supports filtering by status, event type, webhook ID, and event ID, plus offset-based pagination.