Skip to main content
When signing is on, hooksnode adds this header to each request to the destination:
The value is the HMAC-SHA256 of the raw request body, with the destination’s signing secret as the key. The body is the final body, after the transform.

Turn on signing

  1. Open the destination and turn on Signing. hooksnode makes a 64-character secret.
  2. Copy the secret into your endpoint’s settings, for example an environment variable.
  3. To change the secret, press Regenerate. The old secret stops at once.
Signing is off by default. Each destination has its own secret.

Verify the signature

Always compute the HMAC over the raw body bytes, before you parse the JSON. Compare in constant time.

Replay protection

The signature has no timestamp. To stop an attacker who copies a signed request and sends it again, make your handler idempotent. See Idempotency.

Signatures from the provider

hooksnode sends the incoming headers on unchanged. If the event came from Paystack, Stripe or GitHub, your endpoint still gets the provider’s signature header, such as x-paystack-signature, Stripe-Signature or X-Hub-Signature-256. The body is also unchanged, unless you added a transform. You can check the provider’s signature as well.
A transform changes the body. The provider’s signature then no longer matches. Check X-Hooksnode-Signature instead.