Skip to main content
Outgoing webhooks send HTTP POST requests to your server when specific events occur in your Partnero program.

How It Works

Setting Up Outgoing Webhooks

1

Create your endpoint

Create an HTTPS endpoint on your server to receive webhook events:
To verify signatures (next step) you need the raw, unparsed request body. Make sure your framework gives you access to it — see the verified handler below.
2

Register in Partnero

  1. Go to Program Settings → Webhooks
  2. Click Add Webhook
  3. Enter your endpoint URL
  4. Select which events to receive
  5. Save and copy the signing secret
3

Verify signatures

Every webhook request includes a signature in the Signature header. It is an HMAC-SHA256 hash of the raw request body, keyed with your webhook’s signing secret (the signature value shown when you created the webhook, also returned by the Webhooks API).
You must hash the raw request body bytes exactly as received — not a re-serialized version. Partnero signs the JSON produced by PHP’s json_encode, which escapes forward slashes (https:\/\/...) and non-ASCII characters. Re-stringifying the parsed body (e.g. JSON.stringify(req.body)) produces different bytes and the signature will never match.

Available Events

Partner Events

Customer Events

Transaction Events

Reward Events

Webhook Payload

All webhooks share the same envelope. The event-specific fields are nested under data:

Event-Specific Payloads

Handling Webhooks

Best Practices

Respond Quickly

Return a 2xx status within 5 seconds. Process data asynchronously.

Implement Idempotency

Handle duplicate deliveries by tracking processed event IDs.

Use HTTPS

Always use HTTPS endpoints in production.

Log Everything

Log all received webhooks for debugging and audit trails.

Handling Retries

Partnero retries failed webhooks with exponential backoff:
After 5 failed attempts, the webhook is marked as failed. Check your webhook logs in the Partnero dashboard.

Example: Processing Partner Signup

Testing Webhooks

Using the Dashboard

  1. Go to Program Settings → Webhooks
  2. Find your webhook and click Test
  3. Select an event type
  4. Click Send Test Webhook

Using ngrok for Local Development

Troubleshooting

  • Verify your endpoint URL is correct and accessible
  • Check your server logs for incoming requests
  • Ensure your firewall allows requests from Partnero IPs
  • Check the webhook logs in your Partnero dashboard
  • Ensure you’re using the correct signing secret
  • Verify you’re hashing the raw request body
  • Check for any middleware modifying the request body
  • Implement idempotency using event IDs
  • Track processed webhooks in your database
  • Return 200 status quickly to prevent retries

API Reference

For programmatic webhook management, see the Webhooks API.