Webhook endpoints
Webhook endpoints of your organization, their state and delivery log. Needs the webhooks:read permission and a key for all workspaces and campaigns.
#The WebhookEndpoint object
A webhook endpoint of your organization and its state. The full URL is not returned because its path can be a secret: only the host. Additional header values are not returned either, only their names.
Attributes
objectstringObject type, alwayswebhook_endpoint.idstring (uuid)Endpoint id.statusstringactivereceives events,pausedis paused,disabledwas turned off: by itself or by a 410 from the receiver. Values:activepauseddisableddisabled_reasonstring or nullWhy the endpoint is off or paused:gone(the receiver answered 410),failing_72h(errors for more than 3 days),plan(the plan has no webhooks),other.nullfor a working endpoint. Values:gonefailing_72hplanotherhoststringHost of the receiver. Up to 253 characters.descriptionstring or nullDescription from the app, ornull. Up to 500 characters.event_typesarray of stringEvent types the endpoint receives. Up to 20 items.workspace_idsarray of string or nullWorkspaces whose events the endpoint receives.null: all workspaces. Up to 50 items.campaign_idsarray of string or nullCampaigns whose events the endpoint receives.null: all campaigns. Up to 500 items.include_message_textbooleanWhether the lead's reply text is sent.header_namesarray of stringNames of additional headers, without values. Up to 5 items.failing_sincestring (date-time) or nullSince when the endpoint does not accept events, ornullif the last attempt succeeded.consecutive_failuresintegerFailed attempts in a row.last_success_atstring (date-time) or nullTime of the last successful delivery, ornull.versionintegerVersion of the endpoint settings. Grows with every change.created_atstring (date-time)When the endpoint was added.updated_atstring (date-time)When the endpoint settings last changed.deliveriesobjectDelivery summary.Child attributes
pendingintegerHow many events wait to be sent.succeeded_24hintegerDelivered in the last 24 hours.failed_24hintegerNot delivered in the last 24 hours.last_finished_atstring (date-time) or nullWhen the last delivery finished, ornull.last_status_codeinteger or nullReceiver's response code for the last delivery, ornull.last_error_classstring or nullClass of the last error:invalid_url,dns,ssrf_blocked,connect,tls,timeout,http,payload_too_large,unknownornull. Values:invalid_urldnsssrf_blockedconnecttlstimeouthttppayload_too_largeunknown
{
"object": "webhook_endpoint",
"id": "6b2d9f40-3c1e-4a7b-8f5d-2e9c0a1b7d64",
"status": "active",
"disabled_reason": null,
"host": "hooks.example.com",
"description": "CRM",
"event_types": [
"lead.first_message_sent",
"lead.replied"
],
"workspace_ids": null,
"campaign_ids": null,
"include_message_text": false,
"header_names": [
"x-api-key"
],
"failing_since": null,
"consecutive_failures": 0,
"last_success_at": "2026-10-27T09:15:03.000Z",
"version": 2,
"created_at": "2026-10-20T08:00:00.000Z",
"updated_at": "2026-10-22T12:30:00.000Z",
"deliveries": {
"pending": 0,
"succeeded_24h": 38,
"failed_24h": 0,
"last_finished_at": "2026-10-27T09:15:03.000Z",
"last_status_code": 200,
"last_error_class": null
}
}#The WebhookDelivery object
One delivery of an event to a webhook endpoint. No lead data: the event feed returns the event itself by event_id.
Attributes
objectstringObject type, alwayswebhook_delivery.idstring (uuid)Delivery id.endpoint_idstring (uuid)Webhook endpoint.event_idstringEvent id: the same as in thewebhook-idheader and in the event feed. Format^evt_[a-f0-9]{32}$.event_typestring or nullEvent type,webhook.testfor a test event,unknownfor an unknown one, ornullif the event is gone. Values:lead.first_message_sentlead.repliedmessage.receivedlead.status_changedcampaign.status_changedaccount.status_changedmessage.sentmessage.delivery_unknownwebhook.testunknownstatusstringpendingwaits,deliveringis being sent,succeededdelivered,failednot delivered,cancelledcancelled. Values:pendingdeliveringsucceededfailedcancelledunknowncancel_reasonstring or nullWhy the delivery was cancelled:scope_changed,endpoint_deleted,expired,other.nullif not cancelled. Values:scope_changedendpoint_deletedexpiredotherattemptintegerNumber of attempts.next_attempt_atstring (date-time) or nullWhen the next attempt is due. Only forpending, otherwisenull.last_status_codeinteger or nullReceiver's response code for the last attempt, ornull.last_error_classstring or nullError class of the last attempt, ornull. Values:invalid_urldnsssrf_blockedconnecttlstimeouthttppayload_too_largeunknownlast_duration_msinteger or nullDuration of the last attempt in milliseconds, ornull.created_atstring (date-time)When the event was queued for delivery.finished_atstring (date-time) or nullWhen the delivery finished, ornull.
{
"object": "webhook_delivery",
"id": "7c4e1a85-2d9b-4f63-a0e8-5b3f9c7d2e16",
"endpoint_id": "6b2d9f40-3c1e-4a7b-8f5d-2e9c0a1b7d64",
"event_id": "evt_1f8a3c5e7b9d4a2c6e0f8b1d3a5c7e9f",
"event_type": "lead.replied",
"status": "succeeded",
"cancel_reason": null,
"attempt": 1,
"next_attempt_at": null,
"last_status_code": 200,
"last_error_class": null,
"last_duration_ms": 184,
"created_at": "2026-10-27T09:15:02.000Z",
"finished_at": "2026-10-27T09:15:03.000Z"
}#List webhook endpoints
GET/v1/webhook-endpoints
Webhook endpoints of your organization and their state: whether they accept events, since when they fail, the last error and deliveries in the last 24 hours, oldest first. Needs a key for all workspaces and campaigns: webhooks belong to the whole organization.
Parameters
- Number of objects to return per page. From 1 to 100. Defaults to
50. - The
next_cursorvalue from the previous response. Other filters must match the first request. - Only endpoints in this state. Values:
activepauseddisabled
Response
A list: object, data (an array of WebhookEndpoint objects), has_more, next_cursor. See Pagination.
Endpoint-specific errors
cursor_mismatch: The cursor is corrupted, was issued for a different route or filters, or the key's permissions and scope have changed.scope_required: The key does not permit the operation. A command requires its kind permission.not_found: The object was not found or is outside the key's scope. An unknown path also returns 404.cursor_expired: The cursor expired: 15 minutes for lists, 30 days for the event feed.
Common errors are described in Errors.
curl https://api.melioralab.io/v1/webhook-endpoints \
-H "Authorization: Bearer $MELIORA_API_KEY"const res = await fetch('https://api.melioralab.io/v1/webhook-endpoints', {
headers: { Authorization: `Bearer ${process.env.MELIORA_API_KEY}` },
});
if (!res.ok) throw new Error(`Meliora API: ${res.status}`);
const body = await res.json();import os
import requests
resp = requests.get(
"https://api.melioralab.io/v1/webhook-endpoints",
headers={"Authorization": f"Bearer {os.environ['MELIORA_API_KEY']}"},
timeout=15,
)
resp.raise_for_status()
body = resp.json(){
"object": "list",
"data": [
{
"object": "webhook_endpoint",
"id": "6b2d9f40-3c1e-4a7b-8f5d-2e9c0a1b7d64",
"status": "active",
"disabled_reason": null,
"host": "hooks.example.com",
"description": "CRM",
"event_types": [
"lead.first_message_sent",
"lead.replied"
],
"workspace_ids": null,
"campaign_ids": null,
"include_message_text": false,
"header_names": [
"x-api-key"
],
"failing_since": null,
"consecutive_failures": 0,
"last_success_at": "2026-10-27T09:15:03.000Z",
"version": 2,
"created_at": "2026-10-20T08:00:00.000Z",
"updated_at": "2026-10-22T12:30:00.000Z",
"deliveries": {
"pending": 0,
"succeeded_24h": 38,
"failed_24h": 0,
"last_finished_at": "2026-10-27T09:15:03.000Z",
"last_status_code": 200,
"last_error_class": null
}
}
],
"has_more": false,
"next_cursor": null
}#Get a webhook endpoint
GET/v1/webhook-endpoints/{id}
One webhook endpoint by id. A deleted endpoint gives 404.
Parameters
- Webhook endpoint id.
Response
Returns a WebhookEndpoint object.
Endpoint-specific errors
scope_required: The key does not permit the operation. A command requires its kind permission.not_found: The object was not found or is outside the key's scope. An unknown path also returns 404.
Common errors are described in Errors.
curl https://api.melioralab.io/v1/webhook-endpoints/ \
-H "Authorization: Bearer $MELIORA_API_KEY"const res = await fetch('https://api.melioralab.io/v1/webhook-endpoints/', {
headers: { Authorization: `Bearer ${process.env.MELIORA_API_KEY}` },
});
if (!res.ok) throw new Error(`Meliora API: ${res.status}`);
const body = await res.json();import os
import requests
resp = requests.get(
"https://api.melioralab.io/v1/webhook-endpoints/",
headers={"Authorization": f"Bearer {os.environ['MELIORA_API_KEY']}"},
timeout=15,
)
resp.raise_for_status()
body = resp.json(){
"object": "webhook_endpoint",
"id": "6b2d9f40-3c1e-4a7b-8f5d-2e9c0a1b7d64",
"status": "active",
"disabled_reason": null,
"host": "hooks.example.com",
"description": "CRM",
"event_types": [
"lead.first_message_sent",
"lead.replied"
],
"workspace_ids": null,
"campaign_ids": null,
"include_message_text": false,
"header_names": [
"x-api-key"
],
"failing_since": null,
"consecutive_failures": 0,
"last_success_at": "2026-10-27T09:15:03.000Z",
"version": 2,
"created_at": "2026-10-20T08:00:00.000Z",
"updated_at": "2026-10-22T12:30:00.000Z",
"deliveries": {
"pending": 0,
"succeeded_24h": 38,
"failed_24h": 0,
"last_finished_at": "2026-10-27T09:15:03.000Z",
"last_status_code": 200,
"last_error_class": null
}
}#Delivery log
GET/v1/webhook-endpoints/{id}/deliveries
Event deliveries to one endpoint, newest first: state, attempts, response code and error. Helps find out why your CRM did not get an event. The event feed returns the event itself by event_id.
Parameters
- Webhook endpoint id.
- Number of objects to return per page. From 1 to 100. Defaults to
50. - The
next_cursorvalue from the previous response. Other filters must match the first request. - Only deliveries in this state. Values:
pendingdeliveringsucceededfailedcancelled
Response
A list: object, data (an array of WebhookDelivery objects), has_more, next_cursor. See Pagination.
Endpoint-specific errors
cursor_mismatch: The cursor is corrupted, was issued for a different route or filters, or the key's permissions and scope have changed.scope_required: The key does not permit the operation. A command requires its kind permission.not_found: The object was not found or is outside the key's scope. An unknown path also returns 404.cursor_expired: The cursor expired: 15 minutes for lists, 30 days for the event feed.
Common errors are described in Errors.
curl https://api.melioralab.io/v1/webhook-endpoints//deliveries \
-H "Authorization: Bearer $MELIORA_API_KEY"const res = await fetch('https://api.melioralab.io/v1/webhook-endpoints//deliveries', {
headers: { Authorization: `Bearer ${process.env.MELIORA_API_KEY}` },
});
if (!res.ok) throw new Error(`Meliora API: ${res.status}`);
const body = await res.json();import os
import requests
resp = requests.get(
"https://api.melioralab.io/v1/webhook-endpoints//deliveries",
headers={"Authorization": f"Bearer {os.environ['MELIORA_API_KEY']}"},
timeout=15,
)
resp.raise_for_status()
body = resp.json(){
"object": "list",
"data": [
{
"object": "webhook_delivery",
"id": "7c4e1a85-2d9b-4f63-a0e8-5b3f9c7d2e16",
"endpoint_id": "6b2d9f40-3c1e-4a7b-8f5d-2e9c0a1b7d64",
"event_id": "evt_1f8a3c5e7b9d4a2c6e0f8b1d3a5c7e9f",
"event_type": "lead.replied",
"status": "succeeded",
"cancel_reason": null,
"attempt": 1,
"next_attempt_at": null,
"last_status_code": 200,
"last_error_class": null,
"last_duration_ms": 184,
"created_at": "2026-10-27T09:15:02.000Z",
"finished_at": "2026-10-27T09:15:03.000Z"
}
],
"has_more": true,
"next_cursor": "v1.k1.Qm9hcmRfMWZ4.c3RyaWN0bHlfb3BhcXVl.dGFnX2V4YW1wbGU.bWFjX2V4YW1wbGVfdmFsdWU"
}