Supported Webhook Events
Creating a Webhook
1
Open the Webhooks settings
In the AntifraudAI dashboard, navigate to Settings → Webhooks and click Add Endpoint.
2
Enter your endpoint URL
Provide a publicly accessible HTTPS URL on your server. AntifraudAI will send HTTP
POST requests to this URL for each subscribed event.3
Select events to subscribe to
Check the events you want to receive. You can subscribe to individual events or use “Send all events” to receive everything.
4
Save and copy the signing secret
Click Save. AntifraudAI will display a signing secret (prefixed
whsec_). Copy it now — it will not be shown again. Store it securely in your environment variables and use it to verify incoming webhook signatures.Webhook Payload
AntifraudAI delivers events as JSONPOST requests. Below is an example payload for the transaction.screened event:
Verifying Webhook Signatures
AntifraudAI signs every webhook request using HMAC-SHA256 and includes the signature in theX-AntifraudAI-Signature HTTP header. You must verify this signature before processing the payload.
The signature is computed as:
Use a constant-time comparison (e.g.
hmac.compare_digest in Python, crypto.timingSafeEqual in Node.js) when comparing signatures. Standard string equality is vulnerable to timing attacks.Retries
If your server does not return a2xx HTTP status code within 30 seconds, AntifraudAI considers the delivery attempt failed and will retry using exponential backoff:
After 5 failed attempts, the delivery is marked failed and no further retries are made. You can inspect failed deliveries and manually replay them from Settings → Webhooks → [Your Endpoint] → Delivery Logs.

