Skip to main content
POST
/
webhooks
/
{webhook_id}
/
test
Test webhook delivery
curl --request POST \
  --url https://api.engine.usesophic.com/webhooks/{webhook_id}/test \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "event": {
    "name": "<string>",
    "data": {}
  }
}
'
{
  "id": "<string>",
  "webhook": "<string>",
  "event": "<string>",
  "status": "pending",
  "payload": {},
  "succeeded_at": "2023-11-07T05:31:56Z",
  "failed_at": "2023-11-07T05:31:56Z",
  "next_attempt_at": "2023-11-07T05:31:56Z",
  "attempts": [
    {
      "id": "<string>",
      "outcome": "succeeded",
      "response": {
        "status": 123,
        "duration": 123
      },
      "error": {
        "error_type": "http",
        "message": "<string>"
      },
      "created_at": "2023-11-07T05:31:56Z",
      "modified_at": "2023-11-07T05:31:56Z"
    }
  ],
  "created_at": "2023-11-07T05:31:56Z",
  "modified_at": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

webhook_id
string
required

The ID of the webhook to test.

Body

application/json
event
TestWebhookDeliveryEvent · object
required

The event to send in the test delivery.

Response

Accepted

Webhook delivery resource.

id
string
required

Unique resource identifier.

webhook
string
required

The webhook this delivery targets.

event
string | null
required

The event being delivered. Null for test deliveries.

status
enum<string>
required

The delivery lifecycle status.

Available options:
pending,
in_progress,
succeeded,
failed
payload
Payload · object
required

The payload that will be delivered.

succeeded_at
string<date-time> | null
required

The time the delivery succeeded.

failed_at
string<date-time> | null
required

The time the delivery permanently failed (after all retries were exhausted).

next_attempt_at
string<date-time> | null
required

The time the next delivery attempt is scheduled. Populated only after the first failed attempt, when the delivery enters a retry loop.

attempts
WebhookDeliveryAttempt · object[]
required

The delivery attempts.

created_at
string<date-time>
required

The timestamp (in ISO-8601 format) of when the resource was created.

modified_at
string<date-time>
required

The timestamp (in ISO-8601 format) of when the resource was last modified.