Create a callback HTTP endpoint to receive webhooks requests.
https://website.com/webhook_payment
POST
Click to show.
payment_intent.created
event.Call HUB2 API to register this endpoint and subscribe to a webhook event.
Click to show.
Click to show.
"secret": "5257a869e7ecebeda32affa62cd..."
.Webhook signature verification.
"secret": "5257a869e7ecebeda32affa62cd..."
in our example.secret
.Here are some examples of procedures depending on the programming language used :JSON.stringify()
on the body of the request.Hub2-Signature
: Header names1
: Signature computed using current secret
.s0
: Signature computed using old secret oldSecret
if present.secret
, the previous active secret
becomes oldSecret
for a period of 24 hours and is used to generate the s0
signature.