Webhooks
Two directions: inbound vendor events that Arilator verifies, and outbound events we sign and retry.
Inbound vendor webhooks
Acquirers and tax providers post to a per-vendor path. These are the only mutating routes that do not take an idempotency key — the provider signature is the proof.
POST /v1/vendor-webhooks/:vendorCodeSignatures are verified with the vendor’s stored secret using a timing-safe comparison. An unverifiable payload is rejected before any ledger effect.
Outbound events
Subscribe an HTTPS endpoint to the events you care about. Each endpoint has its own signing secret, returned once at creation.
POST /api/v1/partner-manager/commerce/stores/:storeId/webhook-endpoints
{
"url": "https://example.com/hooks/arilator",
"events": ["order.paid", "subscription.created"]
}Signature
X-Arilator-Signature: t=1796280343,v1=<hex>v1 is HMAC-SHA256 over the string timestamp + "." + rawBody, using the endpoint secret. Verification must use the raw body — a parsed and re-serialised JSON body will not match. Reject a timestamp more than five minutes old, and compare in constant time.
const expected = crypto
.createHmac('sha256', secret)
.update(`${t}.${rawBody}`)
.digest('hex');
crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(v1));Delivery
| Property | Value |
|---|---|
| Attempts | 8, then the delivery is marked dead |
| Backoff | Exponential, 1s → 1h |
| Timeout | 10s per attempt, redirects refused |
| Replay | POST /api/v1/webhooks/deliveries/:id/replay from failed, dead or delivered |
| Payload logging | Redacted; the body is not stored in delivery logs |
Endpoint requirements
- HTTPS only, no embedded credentials.
- No private, loopback or IP-literal targets — checked at creation and again at delivery.
- Respond
2xxquickly; do the work asynchronously.