Skip to content
Sections

API reference

Webhooks

Signed event deliveries to your endpoints, for stock changes and account changes.

List webhook endpoints

get/v1/webhook-endpoints

The calling account’s endpoints, or the calling partner’s.

Called by
Any client
Scope
webhooks:write

Responses

200Endpoints.Show
  • dataarray of WebhookEndpointrequired
    Child attributes
    • created_atstring (date-time)required

      e.g. 2026-11-09T08:00:00Z

    • descriptionstring | nullrequired
    • disabled_reasonstring | nullrequired
    • event_typesarray of stringrequired

      One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

    • failing_sincestring (date-time) | nullrequired

      e.g. 2026-11-09T08:00:00Z

    • idstringrequired

      e.g. whe_01jd…

    • previous_secret_expires_atstring (date-time) | nullrequired

      During a rotation, the old secret still verifies until this time.

      e.g. 2026-11-09T08:00:00Z

    • secretstring

      Standard Webhooks secret (whsec_…). Returned once, on create and rotate.

    • statusstringrequired

      One of enabled, disabled

    • updated_atstring (date-time)required

      e.g. 2026-11-09T08:00:00Z

    • urlstring (uri)required
  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X GET 'https://suppliers.presslane.ai/v1/webhook-endpoints' \
  -H "Authorization: Bearer $TOKEN"
Response · 200
{
  "data": [
    {
      "created_at": "2026-11-09T08:00:00Z",
      "description": "string",
      "disabled_reason": "string",
      "event_types": [
        "account.activated"
      ],
      "failing_since": "2026-11-09T08:00:00Z",
      "id": "whe_01jd…",
      "previous_secret_expires_at": "2026-11-09T08:00:00Z",
      "status": "enabled",
      "updated_at": "2026-11-09T08:00:00Z",
      "url": "https://example.com"
    }
  ]
}
Try it in the sandbox

Create a webhook endpoint

post/v1/webhook-endpoints

HTTPS, resolving to a public address. The signing secret is returned once. Deliveries are signed the Standard Webhooks way (webhook-id, webhook-timestamp, webhook-signature: HMAC-SHA256 over id.timestamp.body). A 2xx within 10 seconds is a success; otherwise retries follow at about 30 s, 2 min, 10 min, 1 h, 6 h and 24 h, then daily. After 3 days of failures the endpoint is disabled. Events can arrive more than once and out of order: ignore an id already seen.

Called by
Any client
Scope
webhooks:write

Headers

  • Idempotency-Keystring

    A repeat within 24 hours returns the first response.

    at most 255 characters

Request body · application/json

  • descriptionstring | null
  • event_typesarray of string

    Default: every type this client can receive.

    One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

  • urlstring (uri)required

    HTTPS, resolving to a public address.

Responses

201Created, with its secret.Show
  • created_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • descriptionstring | nullrequired
  • disabled_reasonstring | nullrequired
  • event_typesarray of stringrequired

    One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

  • failing_sincestring (date-time) | nullrequired

    e.g. 2026-11-09T08:00:00Z

  • idstringrequired

    e.g. whe_01jd…

  • previous_secret_expires_atstring (date-time) | nullrequired

    During a rotation, the old secret still verifies until this time.

    e.g. 2026-11-09T08:00:00Z

  • secretstring

    Standard Webhooks secret (whsec_…). Returned once, on create and rotate.

  • statusstringrequired

    One of enabled, disabled

  • updated_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • urlstring (uri)required
  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 409Conflict, including a reused Idempotency-Key (idempotency_conflict).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X POST 'https://suppliers.presslane.ai/v1/webhook-endpoints' \
  -H "Authorization: Bearer $TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{"url":"https://example.com"}'
Response · 201
{
  "created_at": "2026-11-09T08:00:00Z",
  "description": "string",
  "disabled_reason": "string",
  "event_types": [
    "account.activated"
  ],
  "failing_since": "2026-11-09T08:00:00Z",
  "id": "whe_01jd…",
  "previous_secret_expires_at": "2026-11-09T08:00:00Z",
  "status": "enabled",
  "updated_at": "2026-11-09T08:00:00Z",
  "url": "https://example.com"
}
Try it in the sandbox

Get a webhook endpoint

get/v1/webhook-endpoints/{id}
Called by
Any client
Scope
webhooks:write

Path parameters

  • idstringrequired

    Webhook endpoint ID (whe_…).

Responses

200The endpoint.Show
  • created_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • descriptionstring | nullrequired
  • disabled_reasonstring | nullrequired
  • event_typesarray of stringrequired

    One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

  • failing_sincestring (date-time) | nullrequired

    e.g. 2026-11-09T08:00:00Z

  • idstringrequired

    e.g. whe_01jd…

  • previous_secret_expires_atstring (date-time) | nullrequired

    During a rotation, the old secret still verifies until this time.

    e.g. 2026-11-09T08:00:00Z

  • secretstring

    Standard Webhooks secret (whsec_…). Returned once, on create and rotate.

  • statusstringrequired

    One of enabled, disabled

  • updated_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • urlstring (uri)required
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 404Not found (not_found).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X GET 'https://suppliers.presslane.ai/v1/webhook-endpoints/{id}' \
  -H "Authorization: Bearer $TOKEN"
Response · 200
{
  "created_at": "2026-11-09T08:00:00Z",
  "description": "string",
  "disabled_reason": "string",
  "event_types": [
    "account.activated"
  ],
  "failing_since": "2026-11-09T08:00:00Z",
  "id": "whe_01jd…",
  "previous_secret_expires_at": "2026-11-09T08:00:00Z",
  "status": "enabled",
  "updated_at": "2026-11-09T08:00:00Z",
  "url": "https://example.com"
}
Try it in the sandbox

Change or re-enable a webhook endpoint

patch/v1/webhook-endpoints/{id}
Called by
Any client
Scope
webhooks:write

Path parameters

  • idstringrequired

    Webhook endpoint ID (whe_…).

Request body · application/json

  • descriptionstring | null
  • event_typesarray of string

    One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

  • statusstring

    Re-enable an endpoint that was disabled after failing.

    One of enabled, disabled

  • urlstring

Responses

200The endpoint.Show
  • created_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • descriptionstring | nullrequired
  • disabled_reasonstring | nullrequired
  • event_typesarray of stringrequired

    One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

  • failing_sincestring (date-time) | nullrequired

    e.g. 2026-11-09T08:00:00Z

  • idstringrequired

    e.g. whe_01jd…

  • previous_secret_expires_atstring (date-time) | nullrequired

    During a rotation, the old secret still verifies until this time.

    e.g. 2026-11-09T08:00:00Z

  • secretstring

    Standard Webhooks secret (whsec_…). Returned once, on create and rotate.

  • statusstringrequired

    One of enabled, disabled

  • updated_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • urlstring (uri)required
  • 400The request is not valid (invalid_request).
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 404Not found (not_found).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X PATCH 'https://suppliers.presslane.ai/v1/webhook-endpoints/{id}' \
  -H "Authorization: Bearer $TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{}'
Response · 200
{
  "created_at": "2026-11-09T08:00:00Z",
  "description": "string",
  "disabled_reason": "string",
  "event_types": [
    "account.activated"
  ],
  "failing_since": "2026-11-09T08:00:00Z",
  "id": "whe_01jd…",
  "previous_secret_expires_at": "2026-11-09T08:00:00Z",
  "status": "enabled",
  "updated_at": "2026-11-09T08:00:00Z",
  "url": "https://example.com"
}
Try it in the sandbox

Delete a webhook endpoint

DEL/v1/webhook-endpoints/{id}
Called by
Any client
Scope
webhooks:write

Path parameters

  • idstringrequired

    Webhook endpoint ID (whe_…).

Responses

204Deleted.
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 404Not found (not_found).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X DELETE 'https://suppliers.presslane.ai/v1/webhook-endpoints/{id}' \
  -H "Authorization: Bearer $TOKEN"
Try it in the sandbox

Rotate the signing secret

post/v1/webhook-endpoints/{id}/rotate-secret

The new secret is returned once. For 24 hours deliveries carry signatures from both secrets.

Called by
Any client
Scope
webhooks:write

Path parameters

  • idstringrequired

    Webhook endpoint ID (whe_…).

Responses

200The endpoint, with its new secret.Show
  • created_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • descriptionstring | nullrequired
  • disabled_reasonstring | nullrequired
  • event_typesarray of stringrequired

    One of account.activated, account.updated, account.suspended, account.cancelled, stock.changed, stock.low, stock.out, stock.back, supplier.updated, supplier.sync_failed, usage.threshold

  • failing_sincestring (date-time) | nullrequired

    e.g. 2026-11-09T08:00:00Z

  • idstringrequired

    e.g. whe_01jd…

  • previous_secret_expires_atstring (date-time) | nullrequired

    During a rotation, the old secret still verifies until this time.

    e.g. 2026-11-09T08:00:00Z

  • secretstring

    Standard Webhooks secret (whsec_…). Returned once, on create and rotate.

  • statusstringrequired

    One of enabled, disabled

  • updated_atstring (date-time)required

    e.g. 2026-11-09T08:00:00Z

  • urlstring (uri)required
  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 404Not found (not_found).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X POST 'https://suppliers.presslane.ai/v1/webhook-endpoints/{id}/rotate-secret' \
  -H "Authorization: Bearer $TOKEN"
Response · 200
{
  "created_at": "2026-11-09T08:00:00Z",
  "description": "string",
  "disabled_reason": "string",
  "event_types": [
    "account.activated"
  ],
  "failing_since": "2026-11-09T08:00:00Z",
  "id": "whe_01jd…",
  "previous_secret_expires_at": "2026-11-09T08:00:00Z",
  "status": "enabled",
  "updated_at": "2026-11-09T08:00:00Z",
  "url": "https://example.com"
}
Try it in the sandbox

Send a test event

post/v1/webhook-endpoints/{id}/test

A signed webhook.test event, sent now; the response says what the receiver answered.

Called by
Any client
Scope
webhooks:write

Path parameters

  • idstringrequired

    Webhook endpoint ID (whe_…).

Responses

200The attempt.Show
  • errorstring | nullrequired
  • event_idstringrequired
  • response_msinteger | nullrequired
  • response_statusinteger | nullrequired
  • statusstringrequired

    One of succeeded, failed, skipped

  • 401Missing, expired or revoked token (invalid_token).
  • 403The token lacks a scope (insufficient_scope), the account is suspended (account_suspended), or the client kind cannot call this.
  • 404Not found (not_found).
  • 429Too many requests (rate_limited); see Retry-After.
Request
curl -sS -X POST 'https://suppliers.presslane.ai/v1/webhook-endpoints/{id}/test' \
  -H "Authorization: Bearer $TOKEN"
Response · 200
{
  "error": "string",
  "event_id": "string",
  "response_ms": 1,
  "response_status": 1,
  "status": "succeeded"
}
Try it in the sandbox