Transport and Payload
This section covers the transport protocol for webhook notifications, including the structure of the event payload.
Transport Protocol
Webhook notifications are delivered via HTTP POST
requests with the following characteristics:
- Content Type:
application/json
- Request Method:
POST
Each notification is sent as a JSON payload, containing structured information about the event and data specific to the event type.
Payload Structure
Every webhook payload follows a standard JSON structure, ensuring consistent fields for easy processing. Below is the format for a webhook notification payload:
{
"idempotency_key": "00000000-0000-0000-0000-000000000000", // Unique identifier for each event
"type": "type.event_kind", // Type and kind of event (e.g., application.created)
"created_at": "2024-11-06T08:38:49.867Z", // Timestamp in RFC3339 format
"data": { } // Event-specific data
}
Key Fields
idempotency_key
: A unique identifier for each event. Use this key to prevent duplicate processing of the same event.type
: Specifies the type and kind of the event, combining both in a dot notation (e.g.,application.approved
). This allows you to react differently based on the type of object and the event that occurred.created_at
: The timestamp when the event occurred, in RFC3339 format (e.g.,2006-01-02T15:04:05.000Z
).data
: An object containing details specific to the event type. The fields within data vary based on the event type.