subscribe is a thin polling helper, and webhook delivery is on the roadmap.
States
These come from the relayer’sIntentDetails.status field.
Non-terminal (intent is still in flight):
Terminal (intent is done, no further state changes):
None of the terminal-failure states (
failed, expired, cancelled) lose funds. The bridge’s escape path refunds the sender in all three cases, which is also why you can treat “no solver took it” as an expected failure mode rather than an emergency.
State transitions are forward-only. Once terminal, the intent is final.
Poll
Direct API:pending or solving).
Subscribe (polling helper)
GET /intent-details/:intentId. When webhooks ship, this method will switch to a long-lived connection automatically.
Webhooks (planned)
WIP. The planned shape is shown for forward compatibility, none of these calls work today.
secret:
TODO: confirm webhook event names, payload shape, signature header, and retry policy before publish.
Choosing a method (today)
Idempotency (when webhooks ship)
Webhook deliveries can repeat on retries. Use theeventId in each callback to deduplicate before applying side effects.
Failure semantics
- No solver bids before auction closes → intent transitions to
expired, sender is refunded via the bridge’s escape path. - Solver bid but failed to deliver in the protocol’s execution window → intent transitions to
failed, sender is refunded. - Sender cancels before a winner is picked → intent transitions to
cancelled, sender is refunded.
minAmountOut, different chain pair).
Recipient flow: claiming funds
How recipients sweep settled stealth-address balances.