Core concepts
Architecture
A high-level map of how SatoriEx is put together. We share the shape of the system so you can reason about what guarantees you get; specific vendor and product choices are deliberately left out.
How to read this page
Swipe left or right to see the full diagram.
The three layers
Each layer has a single job. Boundaries are explicit so any one piece can be replaced without touching the others.
Edge
Defends the perimeter
Terminates TLS, applies rate limits and geo rules, and forwards healthy requests to the Gateway. The Edge is the only public surface; everything behind it is private.
Core
Runs the application
The Web app serves the UI, the API authenticates requests and orchestrates business logic, the Matcher pairs buyers and sellers under price-time priority, and Workers handle settlement, notifications, and scheduled jobs. Each is a separate process so failures stay contained.
Data & Chain
Holds state and bridges to the chain
Balances and history live in the database as a double-entry ledger โ every change is a debit and a credit, never a one-sided write. A cache and queue sit in front for hot reads and the order pipeline. The blockchain is engaged only when funds enter or leave the system, or when a user wants self-custody.
How the API is layered inside
Inside the API server we follow a clean-architecture layout. Domain entities have zero dependencies on anything outside. Business logic depends only on domain. Transport (HTTP, events) and infrastructure (data stores, chain clients) depend on business logic, never the other way around.
Domain โโโถ App โโโถ Adapter โโโถ Infra entities business logic transport boundary data stores no imports orchestration request / response DB ยท Cache ยท Queue ยท Chain
Dependencies point inward. The domain doesn't know that an HTTP server or a database exists.
Custodial vs self-custody
Custodial trading is fast and free of per-trade gas: matching and the ledger live inside the Core. Linking an external wallet today gives you an on-chain deposit/withdrawal path โ your USDC moves between the wallet and the SatoriEx ledger across the chain, and a gas fee applies on each move. Trading itself still runs inside the Core in either case. A full self-custody trading mode โ where outcome shares are represented on-chain as ERC-1155 CTF tokens during the position โ is on the roadmap (see Contracts and Changelog); it is not active today.