WEBHOOKS
Verifying the signature
Each delivery carries an HMAC-SHA256 of ${timestamp}.${body} in hex, keyed with the device's webhook secret — the same construction Stripe and GitHub use. Check it before you trust a single field.
Headers
The check
Three things that trip people upSign the raw body, not a re-serialized object. Compare in constant time, never with ===. And do not reject an old timestamp: it is the event time, not the send time, so a delivery retried an hour later still carries the original.