Create a webhook (returns the signingSecret only once)
Minimum role: ADMIN. Active workspace via the X-Workspace-Id header.
POST
/webhooksAuthorization
AuthorizationAPI key · headerrequiredAPI key prefixed with Bearer . Alternative: the x-api-key header with the raw key. Available scopes: read and write (see /.well-known/oauth-protected-resource).
or
x-api-keyAPI key · headerrequiredRaw API key (without Bearer ), alternative to Authorization.
Header parameters
X-Workspace-IdstringActive workspace to operate on. Optional: when omitted, the default workspace of the user who owns the key is used (pickActiveOrg).
Request body
requiredapplication/jsonurlstring<uri>requiredeventsstring[]requiredSubset of: sale.confirmed, sale.refunded
min items 1
secretstringmin length 1
Responses
201
OK
dataWebhookCreatedrequiredShow propertiesHide properties
idstringrequiredurlstringrequiredeventsstring[]requiredactivebooleanrequiredlastDeliveryAtstring | nullrequiredShow propertiesHide properties
Any of:
string
stringnull
nulllastDeliveryStatusinteger | nullrequiredShow propertiesHide properties
Any of:
integer
integernull
nullfailureCountintegerrequiredmin -9007199254740991 · max 9007199254740991
createdAtstringrequiredupdatedAtstringrequiredsigningSecretstringrequired401
Missing or invalid credential.
errorobjectrequiredShow propertiesHide properties
codestringrequiredmessagestringrequiredretryablebooleanrequireddetailsany403
Insufficient role or resource not accessible.
errorobjectrequiredShow propertiesHide properties
codestringrequiredmessagestringrequiredretryablebooleanrequireddetailsany404
Resource does not exist or is out of scope.
errorobjectrequiredShow propertiesHide properties
codestringrequiredmessagestringrequiredretryablebooleanrequireddetailsany422
Request body/parameter validation failed.
errorobjectrequiredShow propertiesHide properties
codestringrequiredmessagestringrequiredretryablebooleanrequireddetailsany
