> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ambichain.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Filling orders

> Hold inventory on other chains, pay makers there, and collect their escrow on Ethereum.

![What a filler pays, collects and waits for](https://mintcdn.com/ambi/zxJ8qP3zW6Y_3Fqs/images/art/economics-light.webp?fit=max\&auto=format\&n=zxJ8qP3zW6Y_3Fqs\&q=85\&s=9bd9c4c7284f088f354a684fb2ded2e5)

## The business

You earn the spread between the maker's rate and what the asset costs you, minus the 0.30% fee and any integrator fee shown on the order. In exchange you front the destination asset and wait for settlement.

| Fill: 2.5 WETH for 8,762.5 USDC on Base | |
| - | - |
| You pay on Base | 8,762.5 USDC |
| You collect on Ethereum | 2.4925 WETH (2.5 − 0.0075 fee) |
| Break-even WETH price | 3,512 USDC |
| Bond posted, returned | 0.01 ETH |
| Capital out | About 30 minutes |

You need the destination asset and ETH for gas on both chains, all on **one address**: the router only accepts payment from the matched filler.

## Request

Open the order and press **Request fill**. This posts the maker's bond. You can withdraw the request any time before a match, and if someone else is matched your bond comes back automatically.

## Before you pay

Run these every time. The order page runs them for you and only enables **Pay** when all six pass.

![All six checks passing before payment](https://mintcdn.com/ambi/YFcg3UdfEoAyYkl8/images/app/panel-checklist-light.webp?fit=max\&auto=format\&n=YFcg3UdfEoAyYkl8\&q=85\&s=dd1ec74a2300eaf29fdc44b8bb5ccda6)

1. **The match is final on Ethereum.** Wait for finality (about 13 minutes) so it can't be reorganized away.
2. **The verifier is approved and unchanged.** Its code hash equals the one pinned in the registry and in the order.
3. **The router is the route's real one.** It's the router the inbox trusts, at the address in the request.
4. **The statement matches.** The router's `statement(order)` equals the market's `statement(id)`.
5. **There's time left.** Your payment has to land before `payBy` on the destination chain.
6. **The payment simulates.** Your balance, approval and the recipient all check out.

## Pay

Call `pay(order)` on the destination router with the `RemoteOrder` for this match. For native ETH send the exact amount as `msg.value`; for an ERC-20, approve the router for exactly the amount first. For a token that takes a fee on transfer, call `payToken(order, transferAmount, maxDebit)`: the maker must receive at least the requested amount, and your wallet is never debited more than `maxDebit`.

![The matched filler’s view](https://mintcdn.com/ambi/YFcg3UdfEoAyYkl8/images/app/order-matched-light.webp?fit=max\&auto=format\&n=YFcg3UdfEoAyYkl8\&q=85\&s=bf1075a33a0b6765a4ab08cbbeaa3af5)

The router reverts unless you're the matched filler, it's before `payBy`, and the recipient receives exactly the amount. If it succeeds, Paid is recorded and sent in that transaction. A payment that would land after `payBy` can't happen: the router refuses it.

## Relay and collect

A relayer claims your payment on the Ethereum inbox right away. Thirty minutes later, with no dispute, call `fulfill(id, "")` or let any relayer do it. You're credited the escrow minus 0.30% and any integrator fee, plus your bond. If you set a receive address when requesting, the escrow is credited there instead. Withdraw from **Claim**.

<video autoPlay muted loop playsInline src="https://mintcdn.com/ambi/YFcg3UdfEoAyYkl8/videos/order-flow-light.mp4?fit=max&auto=format&n=YFcg3UdfEoAyYkl8&q=85&s=0e86593ab2ec8ad781d72892fea014ee" />

Request, match, pay, release

## Risks

* **A stalled route.** You paid, the bridge halts, you wait. Spread inventory across routes.
* **A cancel proposal.** Never accept a cancel after you've paid. The market blocks it once Paid is recorded on Ethereum, but not while your payment is still in flight.
* **Your bond.** You lose it only if you're matched and don't pay in time.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.