Skip to main content
In Development — The webhook system is currently being finalized. This documentation describes the target architecture and may be subject to change.

Overview

Webhooks allow you to receive real-time notifications when events occur in your Yield.xyz integration. The system is designed for reliability with at-least-once delivery, automatic retries, and per-subject ordering.

At-least-once delivery

Guaranteed delivery with automatic retries

Per-subject ordering

Sequence numbers for event ordering

HMAC signing

Cryptographic verification of payloads

Comprehensive diagnostics

Delivery status and error tracking

Concepts

A customer destination URL + secret. This is where webhook payloads are delivered via HTTP POST.
Rules determining which events an endpoint receives:
  • events (resources): e.g., transaction, balance, position
  • actions: e.g., status_changed, amount_changed
  • Optional filters: yield_id, address, network, balance_type
An immutable record of “something happened” — the payload we deliver.
A mutable work item representing one attempt to send one event to one endpoint.

How It Works

1

Configure endpoint

Set up an endpoint URL and secret in your dashboard
2

Create subscriptions

Define which events to receive with optional filters
3

Events are emitted

When something happens (transaction confirmed, balance changed), an event is created
4

Deliveries are created

The system matches subscriptions and creates delivery work items
5

Dispatcher sends webhooks

A background worker claims deliveries and sends HTTP POST requests with HMAC signatures
6

Retries on failure

Failed deliveries are retried with exponential backoff

Event Envelope

All webhook payloads use a consistent envelope format:

Supported Events


Signing & Headers

Every webhook request is an HTTP POST with JSON body and these headers:

Signature Format

Verification Example

Optionally reject old timestamps (e.g., older than 5 minutes) for replay protection.

Delivery Semantics

At-Least-Once Delivery

Receivers may see the same event more than once. Dedupe using:
  • event.id (recommended)
  • X-Yield-Delivery header

Ordering

Events may arrive out of order. Use the sequence field (monotonic per subject) to:
  • Reorder events
  • Detect gaps

Retry Policy

  • Success: Any 2xx response
  • Failure: Network errors, timeouts, non-2xx responses
  • Max attempts: 10
  • After max: Delivery marked as dead

Delivery Lifecycle


Configuration

Configure Webhooks

Set up webhook endpoints and subscriptions in your dashboard

Best Practices

Respond quickly

Return 2xx within 15 seconds to avoid timeouts

Deduplicate

Use event.id to handle duplicate deliveries

Verify signatures

Always verify HMAC signatures before processing

Handle ordering

Use sequence numbers to reorder events per subject

Next Steps

Quickstart

Complete integration guide

Staking Extensions

Advanced staking options