Concepts
Cross-Chain Trades

Cross-Chain Trades

How Brtr enables trading across different blockchains.

Overview

Cross-chain trades let you buy tokens on one blockchain while paying from another. For example:

  • Buy USDC on Base Sepo, pay with ETH on OP Sepo
  • Sell tokens on Monad Testnet, receive payment on MegaETH

This works through LayerZero, a messaging protocol that securely coordinates between chains.

The 3-Message Flow

Every cross-chain trade involves 3 messages between blockchains:

Step-by-Step

Buyer Initiates (Message 1)

When you click "Buy" on a cross-chain listing:

  1. Your payment tokens are escrowed on your chain
  2. A FILL_INITIATE message is sent to the seller's chain
  3. The message includes your payment details and what you're buying

Your tokens are now safely locked. The trade is in progress.

Seller's Tokens Locked (Message 2)

When the message arrives on the seller's chain:

  1. The contract verifies everything is valid
  2. Seller's tokens are locked (but not sent yet)
  3. A FILL_CONFIRMATION is sent back to your chain

Both sides are now locked in. The trade will complete.

Payment Released (Message 3)

When confirmation arrives on your chain:

  1. Your escrowed payment is released to the seller
  2. A FILL_FINALIZATION is sent to the seller's chain
  3. The seller's tokens are released to you

Trade complete! Both parties have their tokens.

Why 3 Messages?

This might seem complex, but it ensures safety:

MessagePurposeWhat Could Go Wrong Without It
INITIATELock buyer's paymentBuyer could double-spend
CONFIRMATIONLock seller's tokensSeller could sell twice
FINALIZATIONRelease all tokensIncomplete trades could get stuck

Each step must succeed before the next begins. If anything fails, tokens stay safe and recovery is possible.

Timing

StepTypical Time
Your transaction confirms~15 seconds
Message 1 delivered1-2 minutes
Message 2 delivered1-2 minutes
Message 3 delivered1-2 minutes
Total3-6 minutes

Times vary by network conditions. LayerZero typically delivers messages within 2 minutes per hop.

Gas Costs

Cross-chain trades require gas on both chains:

  • You pay: Gas on your chain + LayerZero fees
  • Seller pays: Nothing extra (gas is pre-funded via "gas drop")

The UI calculates the total cost before you confirm. The extra ETH you send covers:

  1. LayerZero messaging fees
  2. Gas drop for seller's chain execution
  3. Buffer for gas price fluctuations

What If Something Goes Wrong?

Trade Stuck?

Very rare, but if a message doesn't arrive:

  1. Wait 10 minutes — Network delays happen
  2. Check LayerZero Scan — See message status at layerzeroscan.com (opens in a new tab)
  3. After 30 minutes — Recovery functions become available

Recovery Functions

Built-in safety nets:

FunctionWhen to UseWhat Happens
Refund Pending FillConfirmation never arrivedBuyer gets payment back
Emergency FinalizeFinalization lost (admin)Trade completes manually
Emergency RefundTrade failed completelyEveryone gets tokens back
⚠️

Recovery functions have a 30-minute timeout. This prevents race conditions with in-flight messages.

Monitoring Your Trade

Track cross-chain message status:

  1. In-app: Watch the progress timeline
  2. LayerZero Scan: Enter your transaction hash at layerzeroscan.com (opens in a new tab)
  3. Block explorers: Check events on each chain

Same-Chain is Simpler

If you don't need cross-chain:

  • Trade on the same chain as the listing
  • Single transaction, instant completion
  • Lower gas costs, no messaging fees
💡

Pro tip: When creating listings, add at least one same-chain payment option for buyers who prefer speed.