v1

latestOpenAPI 3.1.02026-07-2689175245.8 KB
Programmatic Webhooks

Create Webhook

Create a new webhook subscription.

post/webhooks

Request body

topic'return' | 'label' | 'restock' | 'label.request' | 'giftcard' | 'happy.returns.shipment' required

The webhook's topic.

trigger'return.created' | 'return.updated' | 'return.closed' | 'label.created' | 'label.updated' | 'restock.requested' | 'label.request.issued' | 'label.request.cancelled' | 'giftcard.requested' | 'shipment.processed' required

The condition which triggers the webhook.

urlstring required

The webhook's URL.

status'active' | 'inactive'

The webhook's status.

Example request

{
  "topic": "return",
  "trigger": "return.created",
  "url": "https://example.com/webhook"
}

Response

Created

idinteger

The webhook's unique identifier.

shop_idinteger

The unique identifier of the shop that created the webhook.

topic'return' | 'label' | 'restock' | 'label.request' | 'giftcard' | 'happy.returns.shipment'

The webhook's topic.

trigger'return.created' | 'return.updated' | 'return.closed' | 'label.created' | 'label.updated' | 'restock.requested' | 'label.request.issued' | 'label.request.cancelled' | 'giftcard.requested' | 'shipment.processed'

The condition which triggers the webhook.

urlstring

The webhook's URL.

status'active' | 'inactive'

The webhook's status.

Example response

{
  "id": 12345,
  "shop_id": 65432,
  "topic": "return",
  "trigger": "return.created",
  "url": "https://example.com/webhook"
}