v1

latestOpenAPI 3.1.02026-07-141045121.7 KB
Subscriptions

List all events for a webhook subscription

🔑

Required OAuth scope: webhooks:read.

📖

This endpoint is paginated with a page size of 250 webhook events. For more information, see the Pagination guide.

Lists all events for a given webhook subscription.

get/api/v2/webhooks/subscriptions/{subscriptionId}/events

Path parameters

subscriptionIdstring ObjectId required
Example:507f1f77bcf86cd799439011

The unique ID of the webhook subscription.

Query parameters

ltstring date-time

Filter on dates lower than the given one

gtestring date-time

Filter on dates greater than or equal the given one

Filter on createdAt property with LHS bracket notation.

Expected value format is a date (YYYY-MM-DDThh:mm:ss.sssZ). The milliseconds are always set to 0.

{
  "lt": "2020-01-01T10:30:26.000Z",
  "gte": "2020-01-01T10:30:26.000Z"
}
eq'delivered' | 'failed' | 'pending' | 'sending'

Filter on values equal to the given one

Filter on status property with LHS bracket notation.

Expected value format is a string (delivered, failed, pending, sending).

{
  "eq": "delivered"
}

Headers

360-api-version'v2.0' required

The version of the API.

Response

Returns one page of 250 webhook events.

_idstring required

The unique ID of the webhook event. It corresponds to the header value webhook-id in the webhook event request delivered to your endpoint.

createdAtstring date-time required

The date and time when the webhook event was created, in the YYYY-MM-DDThh:mm:ss.sssZ format (ISO 8601 in Coordinated Universal Time (UTC)).

status'delivered' | 'failed' | 'pending' | 'sending' required

The status of the webhook event. Options are:

  • delivered: The event was successfully delivered.
  • failed: The event failed to be delivered after all the retries.
  • pending: The event delivery process is not yet started.
  • sending: The event delivery is in progress following the retry schedule.
payloadobject required

The payload sent in the webhook event.

Example response

[
  {
    "_id": "msg_1srOrx2ZWZBpBUvZwXKQmoEYga2r"
  }
]