Full flow at a glance
This guide walks through every step.Prerequisites
- A sender wallet on the source chain (chain A) with
tokenInand a little native gas - The recipient registered once via
POST /recipient/registerso the relayer can derive their stealth keys - An ECIES encrypt function (see the
eciesEncrypthelper in endpoints-and-helpers)
1. Register the recipient (first time only)
2. Approve the bridge contract on chain A
amountIn + reward is what the bridge pulls when createIntent is called.
3. Call createIntent on chain A
Publishes the public solver-facing offer. The contract emits the public fields plus an encrypted blob that’s only recoverable by the relayer’s key, the on-chain recovery anchor.
4. Submit the encrypted recipient bundle
Use thestoreRecipients helper from endpoints and helpers:
{ recipients, amounts }, and POSTs to the relayer. Only the relayer (and later the winning solver, under re-encryption) can read this.
5. Track to completion
waitForCompletion is in endpoints and helpers. See tracking intents for the full state machine.
6. Recipient side (chain B)
Funds land at a Safe at a fresh stealth address on chain B. The recipient:- Lists their stealth balances via
GET /recipient/addresseswith a signed request. - Derives the stealth key for a specific delivery via
POST /recipient/derive-stealth-key. - Signs a Safe transaction and calls
POST /recipient/relay-proxy. The relayer broadcasts it and pays gas, so the recipient doesn’t need native gas on chain B.
Intent states and what happens at each
failed, expired, and cancelled never lose funds. The bridge contract’s escape path refunds the sender.
What happens under the hood
After step 4 submits the encrypted bundle, Tachyon:- Batches your intent with other live intents that share the same token pair and chain pair.
- Broadcasts to solvers in plaintext: rate, token pair, total batch amount, available fees. No sender or recipient info.
- When a solver bids to fill some portion of the batch, re-encrypts your recipient bundle to that solver’s key.
- Solver delivers on chain B to the stealth Safe.
- Attestation from the secure enclave is verified on-chain before the sender’s funds are released to the solver.
Error handling
Common failure modes:
See error reference for the full list.
Try it on testnet
Five-minute version of this guide.