Maxy architecture / System overview
System overview
The parts of Maxy, what each one does, and how an order moves between them. It is for architects and security reviewers who want the whole picture before the details.
The parts
| Part | Run by | What it does | What it cannot do |
|---|---|---|---|
| HTTP API | Maxy | Answers prices, quotes, orders and status, with what the wallet should sign and send | Hold funds, or send a transaction for the user |
| TypeScript SDK | You, in your app or server | Calls the API and checks every answer against what it computed or compiled in, then asks the wallet | Hold a key |
| Settler | A contract on each EVM chain | Holds every escrow. Releases it against a proof of the Bitcoin payment, or after a deadline back to whoever locked it | Send it anywhere else |
| Verifier | A contract on each EVM chain | An on-chain Bitcoin node: checks headers' proof of work and difficulty, and payment proofs against them | Take anyone's word for a payment |
| Header relayer | Maxy, and anyone who wants to | Submits new Bitcoin block headers to each verifier, every minute | Forge a payment: the verifier checks the proof of work itself |
| Solvers | Independent solver operators. Anyone can join by posting the bond | Quote, commit with a bond, pay the BTC, then prove it to be paid | Take an escrow without a proof |
| Solana program | A program on Solana | Holds SOL escrows, with its own Bitcoin node | Release an escrow without a proof |
Maxy runs on a decentralised network of independent solvers. Solving is open by design: any solver that posts the bond can commit to an order on the settler, and the first valid fill wins it. The API names no designated filler, so every order is open to the whole network.
Competition works in the user's favour. Solvers compete on price and speed for every order, and that competition is what keeps a solver's margin tight. Each solver puts its own capital at risk. It stakes a bond when it commits, pays the Bitcoin first, and is paid only after that payment is proven on chain. A solver that commits and fails to deliver forfeits its bond to the user.
No single solver is a point of failure. If one solver is offline, another can fill. If none does, the user's coins return from the settler, and no solver and no Maxy server can hold them back. Maxy operates one solver in the network, on the same terms as every other.
The SDK checks a solver named in a server answer against Maxy's published solver list.
Around the contracts, webhooks send your server one signed event per change of an order, and Status and GET /health show the API, the solver, Bitcoin and each verifier's lag.
Solvers
The solver list: the solver accounts compiled into the SDK. A server answer can choose among them, never add one.
| Account | Address | What it does |
|---|---|---|
| Maxy's solver Safe | 0x36E6B9FC60c90700359c7d4A44eb3fafb0837dA7, every EVM chain | Commits to orders, opens gasless escrows and fills sells |
| Its gas account | 0xEd500b2dB269d5e2d798651Ea07e1cf338ECb150, every EVM chain | An owner of the Safe, which sends the solver's transactions |
| Its Bitcoin wallet | bc1q5202srfex2lqkca73w4fe5ctq2hweyuw8yqtcx | Pays the BTC on buys |
| Its Bitcoin custody | bc1q0aalxvqhynw56kwul7979xfpzvm3f5vqgxke2we25wgzdfedlptqerlkgs | A 2-of-2 address the SDK accepts as a sell deposit |
Filled orders each calendar month (UTC), under the solver account that committed to each order, up to the latest indexed fill. Each commit names its solver in the filler field of the settler's IntentCommitted event, so anyone can repeat the count from chain data: Contracts.
| Calendar month (UTC) | Maxy's solver Safe | Maxy's gas account | 0x46c8…db6d | 0xcc43…15f9 | 0xd731…6663 | 0xe07c…483d | All |
|---|---|---|---|---|---|---|---|
| 4 months before | 0 | 81 | 1 | 0 | 0 | 2 | 84 |
| 3 months before | 1 | 67 | 4 | 0 | 6 | 1 | 79 |
| 2 months before | 64 | 1 | 0 | 0 | 0 | 0 | 65 |
| 1 month before | 35 | 0 | 0 | 0 | 0 | 0 | 35 |
| The latest month | 34 | 0 | 0 | 1 | 0 | 0 | 35 |
How an order moves
A buy step by step, from quote to release, and who holds the funds at each moment: How a swap works.
Where trust sits
- Funds. Until the BTC is proven paid, the user's coins sit in the settler on their own chain, never with Maxy. If no solver pays, the user takes them back, with the bond if one committed.
- Addresses. Contract addresses, chain ids and signing domains are compiled into the SDK. A server answer can choose among them, never add a new one: Contracts.
- Proofs. Only a Bitcoin proof the verifier accepts moves an escrow to a solver. No Maxy server can mark a payment as made: Bitcoin verification.
- Liveness. The contracts cannot force a solver to fill. If none does, the user's way out is a refund: When it fails.
More: Contract architecture and Speed and latency.