Skip to main content

Webhooks

Webhooks allow you to receive real-time notifications when events occur in Kraken Embed. When you register a webhook, Kraken will send HTTP POST requests to your configured URL whenever subscribed events are triggered.

Getting Started

  1. Register a webhook using the Register Webhook endpoint — you can optionally specify enabled and events at registration time
  2. Store your secret - the webhook secret is only returned once during registration
  3. Enable and subscribe to events using the Update Webhook endpoint (if not configured at registration)
  4. Implement signature verification in your webhook handler — see Webhook Events for details

Event Types

Event TypeDescription
quote.executedA quote has been successfully executed
webhook.testA test event sent via the Test Webhook endpoint

Retry Behavior

Kraken automatically retries failed webhook deliveries using exponential backoff. The system will continue retrying until the configured timeout is reached:

  • Production: Retries for up to 5 minutes

After the retry timeout is exceeded, the webhook delivery is marked as failed and no further attempts are made.

Best Practices

  • Respond quickly - Return a 2xx status code within 30 seconds to acknowledge receipt
  • Process asynchronously - If your processing takes time, queue the webhook for background processing
  • Be idempotent - Webhooks may be delivered more than once
  • Monitor failures - Track non-2xx responses and implement alerting