For the complete documentation index, see llms.txt. This page is also available as Markdown.

Quickstart

A swap from beginning to end, in three phases.

A swap on the Cross-Chain Swap Engine moves through three phases: quote, lock, claim. The participating parties — a user and a counterparty — each act on their own chain with their own keys. Interstice coordinates but does not custody assets and does not sign settlement transactions.

The three phases

Phase 1 — quote

The user submits a request for quote (RFQ) specifying:

  • the asset and amount on the originating chain,

  • the asset they want on the destination chain,

  • a maximum acceptable quote tolerance.

Eligible counterparties respond with quotes. The user selects one — on an onramp the selected counterparty then arms the swap's hashlock — and commits the trade. At commitment, a quote commitment — a SHA-256 hash of the canonical quote terms, the hashlock among them — is issued. The commitment is the cryptographic binding between the off-chain agreement and the on-chain swap.

Phase 2 — lock

Each side locks its asset in an HTLC on its native chain. Both locks reference the same hashlock — the SHA-256 of a secret preimage held by one of the parties.

  • On the Canton side, the locker exercises a DAML choice that creates an HTLCLock contract.

  • On the Ethereum side, the locker calls lockETH or lockERC20 on the bridge contract.

Each lock carries its own time-lock — an absolute deadline after which the funds can be refunded.

Phase 3 — claim

The party holding the secret preimage claims first by submitting it to the lock on its chain. This makes the preimage visible. The counterparty observes the preimage and uses it to claim the other lock.

Either both claims happen and the swap settles, or neither happens before the time-locks expire and both sides refund. There is no path where one side claims and the other does not, because the two locks are bound to the same secret.

What the user sees

A swap that follows the happy path takes minutes once the locks are in place. The user confirms each step in their wallet:

  1. Submit the RFQ and pick a quote.

  2. Authorise the lock on their chain by signing in their connected wallet (for example, MetaMask for Ethereum or Console Wallet for Canton; institutional integrations use their own key management).

  3. Wait while both sides lock.

  4. Authorise the claim on their chain when the counterparty has revealed the preimage.

If anything goes wrong before both sides lock, nothing is at risk. If both sides lock but a claim does not happen, both sides refund automatically at the time-lock.

Where to next

  • Atomic swap protocol — a five-step walkthrough with the actors and on-chain effects of each step.

  • Security model — what makes the swap atomic and what trust assumptions it relies on.

  • HTLC primer — for readers new to hashed-timelock contracts.

Last updated