<Intro>

<EndpointHeader />

<Description>

Sends a signed synthetic event to the endpoint's URL and returns the outcome
synchronously: whether your endpoint accepted it, the HTTP status it returned, and the
round-trip latency. Use it to verify your receiver is reachable and its signature
verification is correct. An unreachable endpoint is reported in the response body as
`status: failed`, not as a request error. Your endpoint has 10 seconds to respond.

The test body is a minimal JSON stub carrying only the event `type` (it does not
mirror a real event payload), signed exactly like a real delivery. Test sends go
straight to your endpoint: they work on a paused endpoint and are not recorded in
[List delivery attempts](/docs/api/reference/list-webhook-attempts).

A `412` means the endpoint cannot be tested yet: it has no valid signing secret, or no
subscribed event types to fall back on when `event_type` is omitted.

</Description>

</Intro>

<Payload kind="request">

<Field name="event_type" type="string">

<Description>

Event type to simulate. Any type from the event catalog is accepted, whether or not the endpoint subscribes to it; an unknown type returns a `422`. When omitted, the endpoint's first subscribed event type is used.

</Description>

</Field>

</Payload>

<Payload kind="response">

<Field name="status" type="string" required>

<Description>

Whether your endpoint accepted the test event. `delivered` means it returned a `2xx` status; `failed` means it returned a non-`2xx` status or could not be reached (see `error` for the latter).

</Description>

<Description>

Possible values: `delivered`, `failed`

</Description>

</Field>

<Field name="response_status_code" type="nullable integer" required>

<Description>

HTTP status returned by your endpoint. Null when no response was received (timeout, connection error, DNS failure).

</Description>

</Field>

<Field name="response_body" type="string">

<Description>

Response body returned by your endpoint, truncated to the first 1024 bytes. Omitted when your endpoint returned no body or could not be reached.

</Description>

</Field>

<Field name="response_duration_ms" type="integer" required>

<Description>

Round-trip delivery latency in milliseconds.

</Description>

</Field>

<Field name="event_payload" type="object">

<Description>

The full event body delivered to your endpoint. Test sends use a minimal synthetic body rather than a full event payload, so this field is omitted.

</Description>

<FieldChildren kind="response">

<Field name="type" type="string" prefix="event_payload." required>

<Description>

Event type.

</Description>

<Description>

Possible values: `whatsapp.sent`

</Description>

</Field>

<Field name="timestamp" type="string" prefix="event_payload." required>

<Description>

Time Bird handed the message to Meta for delivery.

</Description>

</Field>

<Field name="data" type="object" prefix="event_payload." required>

<Description>

Payload of the whatsapp.sent event.

</Description>

<FieldChildren kind="response">

<Field name="whatsapp_id" type="string" prefix="event_payload.data." required>

<Description>

ID of the WhatsApp message.

</Description>

</Field>

<Field name="workspace_id" type="string" prefix="event_payload.data." required>

<Description>

ID of the workspace.

</Description>

</Field>

<Field name="direction" type="string" prefix="event_payload.data." required>

<Description>

Whether the message was sent by the business (`outbound`) or received from the contact (`inbound`).

</Description>

<Description>

Possible values: `outbound`, `inbound`

</Description>

</Field>

<Field name="from" type="object" prefix="event_payload.data." required>

<Description>

Sender of the message. On outbound messages, the business number it was sent from.

</Description>

<FieldChildren kind="response">

<Field name="phone_number" type="string" prefix="event_payload.data.from.">

<Description>

Phone number in E.164 format, when known.

</Description>

</Field>

<Field name="bsuid" type="string" prefix="event_payload.data.from.">

<Description>

Business-scoped user ID, Meta's identifier for the WhatsApp user. Present only on the WhatsApp-user side of the message.

</Description>

</Field>

</FieldChildren>

</Field>

<Field name="to" type="object" prefix="event_payload.data." required>

<Description>

Recipient of the message. On outbound messages, the WhatsApp contact.

</Description>

<FieldChildren kind="response">

<Field name="phone_number" type="string" prefix="event_payload.data.to.">

<Description>

Phone number in E.164 format, when known.

</Description>

</Field>

<Field name="bsuid" type="string" prefix="event_payload.data.to.">

<Description>

Business-scoped user ID, Meta's identifier for the WhatsApp user. Present only on the WhatsApp-user side of the message.

</Description>

</Field>

</FieldChildren>

</Field>

<Field name="tags" type="nullable array" prefix="event_payload.data." required>

<Description>

Tags provided on the send request, echoed on every event for the message. Null when the message carried no tags.

</Description>

</Field>

<Field name="metadata" type="nullable object" prefix="event_payload.data." required>

<Description>

The metadata object provided on the send request, echoed on every event for the message. Null when the message carried no metadata.

</Description>

</Field>

</FieldChildren>

</Field>

</FieldChildren>

</Field>

<Field name="error" type="string">

<Description>

A short explanation of why the event could not be delivered. Present only when your endpoint could not be reached.

</Description>

</Field>

</Payload>