order
Handles order lifecycle events.
For order.succeeded:
- Find the merchant account using
data.object.customerEmail. - Create a missing account and return
account.created, or returnaccount.reloadedafter confirming the successful-payment notification for an existing account. - Map
data.object.amountTotaltodata.amountanddata.object.paymentCurrencytodata.currency.
Handle retries idempotently using the event id or orderId, and return the original result for duplicate events. Other order events may return an empty HTTP 200 response.
Headers
Timestamp sent by Clink for webhook signature verification.
Hex-encoded HMAC-SHA256 signature generated with the webhook signing secret over the string ${X-Clink-Timestamp}.${rawRequestBody}. Use the raw request body bytes/string exactly as received; do not parse and re-serialize the JSON before verifying.
Signature algorithm used to generate X-Clink-Signature. The current value is SHA256.
SHA256 Body
Order event payload in json
Unique identifier for the event
Type of event that occurred
order.created, order.next_action, order.succeeded, order.failed Type of this json payload, 'event' if this is an event
"event"
Unix timestamp in milliseconds when the event occurred
Response
HTTP 200 after successful handling; order.succeeded includes merchant account JSON response; other order event types may return empty HTTP 200
event "event"
Merchant account response type. account.created indicates that a new merchant account was created successfully. account.reloaded indicates that an existing merchant account matched and the merchant confirms that it received the successful-payment notification.
account.created, account.reloaded