DEVELOPER GUIDE
Stable
Webhooks
Overview
Webhooks deliver real-time notifications from the PointServices platform to an endpoint you host. Instead of polling the Orders API for changes, you register an HTTPS endpoint once and receive an HTTP POST each time a subscribed event occurs.
Every webhook request carries the event metadata and payload in its JSON body, and a JWT in the Authorization header. The JWT proves the request came from PointServices, and its body_sha256 claim binds the token to the exact body delivered, so a verified message cannot have been altered in transit.
Receiving webhooks does not require you to authenticate to us — your endpoint verifies the tokens we send. You will still need an access token to call the Orders API, including when confirming an event against the order it refers to.
How It Works
- Register your endpoint, the topics you want, and the tenant that generates the events. See Registering.
- Implement an endpoint that accepts a
POST, reads the event from the JSON body, and responds200 OK. See Implementation. - Verify the JWT and the body digest on every request before trusting the body. See Verification.
Delivery Behavior
- Delivery is at least once. The same event may arrive more than once, so use the
webhookIdfield to detect and discard duplicates. - Your endpoint must be a publicly reachable
httpsURL. - Responses with a status code >=
500are retried using exponential backoff.
Always verify the JWT before acting on a webhook body. An endpoint that processes unverified requests will accept event data from anyone who discovers its URL.