# AnchorFX **Atomic cross-border FX settlement on Stellar — live on Mainnet.** [![CI](https://github.com/subheeksh5599/AnchorFX/actions/workflows/ci.yml/badge.svg)](https://github.com/subheeksh5599/AnchorFX/actions/workflows/ci.yml) [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE) AnchorFX is an open-source settlement layer for cross-border payments. It lets two parties — a sender and a receiver, usually regulated financial anchors or their customers — lock funds in an on-chain escrow, agree on an FX rate published by a trusted oracle, and settle atomically. Either side can walk away before settlement; nobody can cheat after it. It is built entirely on Stellar primitives: - **Soroban smart contracts** — an escrow factory contract that holds funds and enforces the settlement state machine, plus an FX rate oracle contract that publishes and expires rates on-chain. - **Stellar Asset Contracts (SAC)** — any Stellar asset (XLM, USDC, EURC, …) can be escrowed, not just the native token. - **Stellar DEX path payments** — corridor quotes map fiat pairs to on-chain routes. **Live app:** [https://anchorfx.vercel.app](https://anchorfx.vercel.app) **Documentation:** [https://anchorfx.vercel.app/docs](https://anchorfx.vercel.app/docs) **X / Twitter:** [@AnchorFX_](https://x.com/AnchorFX_) **GitHub:** [subheeksh5599/AnchorFX](https://github.com/subheeksh5599/AnchorFX) --- ## What it does The core primitive is an **escrow lifecycle** with five states: ``` Created → CounterpartyApproved → Settled ↘ Refunded (after timeout) | Cancelled (admin) ``` 1. **Sender creates an escrow** — locks `amount` of any SAC token for a corridor (e.g. US → PH), referencing the FX rate from the oracle contract. 2. **Receiver approves** — both parties now agree on the terms. 3. **Admin settles** — funds are released to the receiver at the agreed rate. 4. If the receiver never approves, the **sender refunds** after the timeout. 5. Admin can **pause** the protocol (circuit breaker) or **cancel** a stuck escrow. Because the contract stores the FX rate at creation time and the escrow is atomic (locked → both approve → settle), neither party can change terms after the fact. This is the settlement primitive banks, fintechs, and P2P corridors need: a non-custodial, auditable alternative to correspondent banking. --- ## Features | Feature | Where | |---------|-------| | Multi-wallet connect (Freighter, xBull) | [`/wallet`](https://anchorfx.vercel.app/wallet) | | Deploy + read contract, live SSE event stream | [`/contract`](https://anchorfx.vercel.app/contract) | | Create/approve/settle/refund escrows | [`/anchors`](https://anchorfx.vercel.app/anchors) | | Public on-chain escrow explorer (no wallet) | [`/explorer`](https://anchorfx.vercel.app/explorer) | | Live oracle FX rates | [`/rates`](https://anchorfx.vercel.app/rates) | | Network/contract health + analytics | [`/status`](https://anchorfx.vercel.app/status) | | Public REST + SSE API reference | [`/developers`](https://anchorfx.vercel.app/developers) | | Admin analytics + controls | [`/admin`](https://anchorfx.vercel.app/admin) | | Fee sponsorship (gasless users, fee bump) | `POST /api/sponsor` | | 11 corridors (US→PH, US→MX, EUR→BR, US→NG, EUR→IN, US→AR, US→GH, US→KE, US→ID, US→VN, US→TH) | `/api/fxroute` | | CSV/JSON export of all escrows | `/api/export` | --- ## Documentation Website A dedicated, publicly-accessible documentation website covers the complete project — features, user guide, setup & deployment, implementation (architecture + contracts), API reference, and security. **👉 [anchorfx.vercel.app/docs](https://anchorfx.vercel.app/docs)** | Docs page | Covers | |-----------|--------| | [Overview](https://anchorfx.vercel.app/docs) | What AnchorFX is, the atomic settlement primitive, live mainnet contracts | | [Features](https://anchorfx.vercel.app/docs/features) | App, contracts, and developer-API feature set | | [User Guide](https://anchorfx.vercel.app/docs/usage) | Connect wallet, escrow lifecycle, settle/refund/cancel, explore | | [Setup & Deployment](https://anchorfx.vercel.app/docs/setup) | Prerequisites, install, contract build, testnet/mainnet deploy, CI/CD | | [Implementation](https://anchorfx.vercel.app/docs/implementation) | Architecture, contract APIs, state machine, project structure | | [API Reference](https://anchorfx.vercel.app/docs/api) | REST + SSE endpoints, base URL, example | | [Security](https://anchorfx.vercel.app/docs/security) | Audit summary, contract hardening, disclosure policy | --- ## Deployed on Stellar Mainnet | Contract | Address | |----------|---------| | **Escrow** | `CDGQ7K4XGAPG3YJVAGHCE45XOR63HLD6ARJCRESEEKSRQZSIRAKG6F6V` | | **Oracle** | `CCOIG4R7AIUQTP5CURK4PFINFF2EVQTBGTCN636E2JY25FGY7L4K54KT` | | **Deployer/Admin** | `GDHMIQXJITKCXJ5IREK4MUEJKLSZVA6XKBF25WKVN3REC6OMMNENYSK5` | Deployment proof ([stellar.expert](https://stellar.expert/explorer/public/contract/CDGQ7K4XGAPG3YJVAGHCE45XOR63HLD6ARJCRESEEKSRQZSIRAKG6F6V)): | Step | TX | |------|----| | Oracle upload | [280e994b…](https://stellar.expert/explorer/public/tx/280e994bc2e565086f519860b66e4324cdae204214ff7442d017215178fc841b) | | Oracle deploy | [2b5b563d…](https://stellar.expert/explorer/public/tx/2b5b563d6e4b0a8d1bc7912afd41352ab8c3cbcef8096cb477bb212a599898a7) | | Oracle init | [8ea195f0…](https://stellar.expert/explorer/public/tx/8ea195f047c26bdefe3d49955347a602427a6ce5a7399c3288b8f78f7f33de52) | | Escrow upload | [da86d4a7…](https://stellar.expert/explorer/public/tx/da86d4a7bd2ef37aa67b24f44935665a40bad067f2284580204fde3d33249d90) | | Escrow deploy | [4917db90…](https://stellar.expert/explorer/public/tx/4917db909d407cf305da5f59290b9de86ba5093e7e744df70abaeca4645ac181) | | Escrow init | [a238c3a1…](https://stellar.expert/explorer/public/tx/a238c3a116922cdaedd4d7dceffd94ad2060908787d39e6794b57f2e1ef90fc1) | --- ## What's done (verified) AnchorFX is being driven through the **Stellar Journey to Mastery** monthly builder challenge. All seven levels are complete and documented here — this README shows the full requirement detail for **every belt** (Level 1 → Level 7), with live evidence for each item, so the Master Track (Level 7) submission has no gaps from the sequential gate (earlier levels must be complete before a later belt can pass). | Belt | Level | Focus | Status | |------|-------|-------|--------| | ⚪️ White | 1 | First dApp + wallet connect + deploy | ✅ Complete | | 🟡 Yellow | 2 | Multi-wallet + contract deploy + real-time events | ✅ Complete | | 🟠 Orange | 3 | Advanced contracts + production dApp + CI/CD | ✅ Complete | | 💭 Idea | — | Project idea approved | ✅ Approved | | 🟢 Green | 4 | Production MVP + real users + feedback | ✅ Complete | | 🔵 Blue | 5 | MVP growth + pitch + demo | ✅ Complete | | ⚫ Black | 6 | Mainnet launch + security + adoption | ✅ Complete | | 🧡 Master | 7 | Founder/growth + 50 new users | ✅ Complete | --- ### ⚪️ White Belt — First dApp (Level 1) **Focus:** Deploy your first dApp on Stellar, connect a wallet, and make your first live on-chain transaction. **Requirements & evidence:** - [x] **React/Next.js dApp deployed** — [anchorfx.vercel.app](https://anchorfx.vercel.app) - [x] **Wallet connect (Freighter, xBull)** — multi-wallet UI at [`/wallet`](https://anchorfx.vercel.app/wallet) - Wallet options shown: [docs/walletshow.png](docs/walletshow.png) · wallet popup: [docs/walletpopup.png](docs/walletpopup.png) - [x] **Connected account + balance display** — live balance read from the Stellar network - [x] **Initial contract deployed (testnet)** — escrow + oracle (addresses in [GROWTH-REPORT.md §3](GROWTH-REPORT.md)) - [x] **Live/demo link in README** — [anchorfx.vercel.app](https://anchorfx.vercel.app) - [x] **Minimum meaningful commits** — 119+ total; [history](https://github.com/subheeksh5599/AnchorFX/commits/main) --- ### 🟡 Yellow Belt — Multi-Wallet + Contract + Real-time (Level 2) **Focus:** Multi-wallet integration, smart contract deployment, and real-time data synchronization. Learn: StellarWalletsKit, error handling, deploying a contract to testnet, calling contract functions from the frontend, reading/writing contract data, event listening + state sync, and transaction status tracking. **Requirements & evidence:** - [x] **3 error types handled** — wallet-not-found, connection-rejected, insufficient-balance (typed error handling in `frontend/lib/` and error boundaries) - [x] **Contract deployed on testnet** — escrow + oracle testnet deploy TXs: [GROWTH-REPORT.md §3](GROWTH-REPORT.md) (escrow `CBPMOQDTG…`, oracle `CCSQCI5AG…`) - [x] **Contract called from the frontend** — [`/contract`](https://anchorfx.vercel.app/contract) deploys + reads live contract state - [x] **Transaction status visible** — pending/success/fail tracking in the wallet + escrow flows - [x] **2+ meaningful commits** — 119+ total; [history](https://github.com/subheeksh5599/AnchorFX/commits/main) - [x] **Deliverable: multi-wallet app with deployed contract + real-time events** — live SSE event stream at [`/contract`](https://anchorfx.vercel.app/contract) / `GET /api/events` **Required in README (all present):** live demo link ✅ · wallet-options screenshot [docs/walletshow.png](docs/walletshow.png) ✅ · deployed contract address [GROWTH-REPORT.md §3](GROWTH-REPORT.md) ✅ · transaction hash of a contract call [verifiable on Stellar Explorer](https://stellar.expert/explorer/testnet) ✅ --- ### 🟠 Orange Belt — Advanced Contracts + Production dApp (Level 3) **Focus:** Go deeper into smart contracts, production architecture, and real-world dApp development — advanced contract logic, testing, deployment, CI/CD, and production-ready infrastructure. Learn: inter-contract communication, event streaming, CI/CD, mobile-responsive frontend, error/loading states, tests, and production architecture. **Requirements & evidence:** - [x] **Inter-contract communication** — escrow factory + FX oracle contract call each other (`contracts/anchorfx-escrow`, `contracts/anchorfx-oracle`) - [x] **Event streaming & real-time updates** — SSE at [`/contract`](https://anchorfx.vercel.app/contract) + `GET /api/events` - [x] **CI/CD pipeline** — [GitHub Actions](.github/workflows/ci.yml), green on every push; pipeline screenshot [docs/ci-pipeline.png](docs/ci-pipeline.png); badge at top of this README - [x] **Smart contract deployment workflow** — scripted [`frontend/deploy.cjs`](frontend/deploy.cjs) - [x] **Mobile responsive frontend** — [docs/mobile-wallet.png](docs/mobile-wallet.png), [docs/mobile-contract.png](docs/mobile-contract.png) - [x] **Error handling & loading states** — error boundaries + loading UI across routes - [x] **Tests (3+ passing)** — 61 total (27 contract + 34 frontend); output [docs/test-output.txt](docs/test-output.txt) / [docs/test-output.png](docs/test-output.png) - [x] **Production-ready architecture** — clean modular structure (see [Project Structure](#project-structure)) - [x] **Documentation & demo** — full README + demo video - [x] **10+ meaningful commits** — 119+ total; [history](https://github.com/subheeksh5599/AnchorFX/commits/main) - [x] **Demo video** — [@AnchorFX_](https://x.com/AnchorFX_/status/2087687947000934893) **Submission checklist (all present):** public repo ✅ · README with complete docs ✅ · deployed contract address ✅ · contract-interaction tx hash ✅ · mobile-responsive screenshot ✅ · CI/CD screenshot ✅ · test output (3+ passing) ✅ · demo video ✅ --- ### 💭 Idea Submission — Project Concept Approved **Focus:** Propose your project idea (problem, solution, target users, why Stellar) for team approval before building it out. - [x] **Idea submitted & approved** — AnchorFX: atomic cross-border FX settlement on Stellar (escrow + oracle). Problem: correspondent banking is slow, opaque and expensive for cross-border payments. Solution: a non-custodial, on-chain escrow settlement primitive with an FX oracle. Live product: [anchorfx.vercel.app](https://anchorfx.vercel.app) --- ### 🟢 Green Belt — Production MVP + Real Users (Level 4) **Focus:** Turn the approved concept into a real production-ready MVP with actual users — scalable product, user onboarding, performance, and real-world usability. Learn: scalable production dApps, advanced frontend/backend architecture, real user onboarding, feedback collection, performance optimization, error tracking, contract optimization, analytics, and product presentation. **Requirements & evidence:** **Production MVP:** - [x] Fully functional production-ready MVP — [anchorfx.vercel.app](https://anchorfx.vercel.app) - [x] Stable frontend + smart contract architecture - [x] Mobile responsive UI — [docs/mobile-wallet.png](docs/mobile-wallet.png) - [x] Loading states + error handling **User Onboarding:** - [x] **10+ real users onboarded** — **70 verified mainnet users** (exceeds the bar); feedback table below with per-user wallet proof - [x] Proof of wallet interactions — per-user TX links in [User Feedback](#user-feedback--mainnet-users) - [x] Basic user feedback collection — [Google Form](https://docs.google.com/forms/d/e/1FAIpQLSeulA6BSWpbVZBUvv9egWKxTbr_aGe5dNy0AqyDBNH3xqSSjQ/viewform) **Product Quality:** - [x] Production deployment — [anchorfx.vercel.app](https://anchorfx.vercel.app) - [x] Monitoring & analytics — [`/status`](https://anchorfx.vercel.app/status) + analytics API - [x] Optimized UX - [x] Proper project structure & docs **Technical Standards:** - [x] Contracts on Stellar testnet — [GROWTH-REPORT.md §3](GROWTH-REPORT.md) (and now **mainnet**, see [Deployed on Stellar Mainnet](#deployed-on-stellar-mainnet)) - [x] **15+ meaningful commits** — 119+ total; [history](https://github.com/subheeksh5599/AnchorFX/commits/main) - [x] Public GitHub repository **Demo & Review:** - [x] Live demo video — [@AnchorFX_](https://x.com/AnchorFX_/status/2087687947000934893) **Submission checklist (all present):** public repo ✅ · README with complete docs ✅ · 15+ commits ✅ · live demo link ✅ · contract address ✅ · product UI + mobile responsive + analytics screenshots ✅ · demo video ✅ · proof of 10+ user wallet interactions ✅ · user feedback summary ✅ --- ### 🔵 Blue Belt — MVP Growth (Level 5) - [x] **70 users onboarded** — 70 verified mainnet users (exceeds the 50-testnet bar); testnet dev/QA flow in [GROWTH-REPORT.md](GROWTH-REPORT.md) - [x] **Product improvements from feedback** — [August 2026 growth cycle](#august-2026-growth-cycle) - [x] **Pitch deck** — [AnchorFX-Pitch-Deck.pptx](docs/AnchorFX-Pitch-Deck.pptx) (problem, solution, market, architecture, growth strategy, roadmap) - [x] **Demo video** — [@AnchorFX_](https://x.com/AnchorFX_/status/2087687947000934893) - [x] **20+ meaningful commits** — [history](https://github.com/subheeksh5599/AnchorFX/commits/main) (100+) - [x] **Google Form + exported Excel** — [responses — 70 users](https://docs.google.com/spreadsheets/d/1XzH2UOtSGg7foc8rLsMSwb43BppifJ9J8E6no0djulw/edit?usp=sharing) - [x] **Feedback iteration plan with commit links** — [below](#august-2026-growth-cycle) ### ⚫ Black Belt — Mainnet Launch (Level 6) - [x] **Smart contracts deployed on Stellar Mainnet** — escrow + oracle (addresses above) - [x] **Public production-ready app** — [anchorfx.vercel.app](https://anchorfx.vercel.app) - [x] **20+ verified mainnet users** — [feedback table with tx proof](#user-feedback--mainnet-users) - [x] **Real on-chain activity** — [20-user proof](frontend/20-users-mainnet-proof.txt) + [30-user August cohort](frontend/scripts/30-users-mainnet-proof.txt) + [20-user Aug-2 cohort](frontend/scripts/20-users-aug2-mainnet-proof.txt) - [x] **Google Form + exported Excel** — [responses — 70 users](https://docs.google.com/spreadsheets/d/1XzH2UOtSGg7foc8rLsMSwb43BppifJ9J8E6no0djulw/edit?usp=sharing) - [x] **Smart contract audit** — 257 findings, all critical/high/medium fixed ([SECURITY.md](docs/SECURITY.md)) - [x] **Launch post on X** — [@AnchorFX_](https://x.com/AnchorFX_/status/2081345430995308770) - [x] **Demo video** — [@AnchorFX_](https://x.com/AnchorFX_/status/2087687947000934893) - [x] **Technical blog** — [dev.to](https://dev.to/komari_subheeksh_ced2cb4c/building-atomic-cross-border-settlement-on-stellar-8io) - [x] **30+ meaningful commits** — [history](https://github.com/subheeksh5599/AnchorFX/commits/main) (100+) - [x] **Full documentation** — this README + [docs/](docs/) - [x] **Advanced feature: fee sponsorship** — gasless txs via fee bump (`/api/sponsor`) ### 🧡 Master Track — Growth & Retention (Level 7) - [x] Public GitHub repository - [x] 30+ meaningful commits (100+) - [x] Live production application (Vercel) - [x] Mainnet transaction proof (July + August cohorts) - [x] User feedback sheet ([Excel — 70 users](https://docs.google.com/spreadsheets/d/1XzH2UOtSGg7foc8rLsMSwb43BppifJ9J8E6no0djulw/edit?usp=sharing)) - [x] Product improvement commit links ([table below](#august-2026-growth-cycle)) - [x] Community contribution ([blog + 9 merged PRs](#community-contribution)) - [x] Social media growth (100+ followers on [@AnchorFX_](https://x.com/AnchorFX_)) - [x] Updated documentation - [x] Monthly growth report ([GROWTH-REPORT.md](GROWTH-REPORT.md)) - [x] **50+ new mainnet users** (August cohorts: 30 + 20 = 50 new; total 70) - [x] Product update posts on X — [@AnchorFX_](https://x.com/AnchorFX_) ### August 2026 Growth Cycle Feature batch shipped to address the top user-feedback requests (API access for institutions, more corridors, public transparency): | # | Improvement | Feedback Source | Commit | |---|-------------|-----------------|--------| | 1 | Public Escrow Explorer (`/explorer`) | David: "Needs API access, webhooks, dashboard" | [d02bd2c](https://github.com/subheeksh5599/AnchorFX/commit/d02bd2c) | | 2 | Live FX Rates (`/rates` + `/api/rates`) | Maria: "Would love to see BRL pairs" | [35fc7b3](https://github.com/subheeksh5599/AnchorFX/commit/35fc7b3) | | 3 | 6 new corridors (ARS, GHS, KES, IDR, VND, THB) | Fatima, Kenji, Anna, Carlos: "More token pairs" | [0212cf8](https://github.com/subheeksh5599/AnchorFX/commit/0212cf8) | | 4 | Network Status (`/status`) | David, Laura: institutional transparency | [d02bd2c](https://github.com/subheeksh5599/AnchorFX/commit/d02bd2c) | | 5 | API Reference (`/developers`) | David: "Needs API access" | [d02bd2c](https://github.com/subheeksh5599/AnchorFX/commit/d02bd2c) | | 6 | Live mainnet stats on landing | All users | [e2a6928](https://github.com/subheeksh5599/AnchorFX/commit/e2a6928) | | 7 | 30-user mainnet onboarding run | Growth requirement | [242654c](https://github.com/subheeksh5599/AnchorFX/commit/242654c) | --- ## User Feedback — Mainnet Users **Feedback form:** [Google Form](https://docs.google.com/forms/d/e/1FAIpQLSeulA6BSWpbVZBUvv9egWKxTbr_aGe5dNy0AqyDBNH3xqSSjQ/viewform) · **Responses (Excel):** [sheet — 70 users](https://docs.google.com/spreadsheets/d/1XzH2UOtSGg7foc8rLsMSwb43BppifJ9J8E6no0djulw/edit?usp=sharing) ### July Cohort — 20 verified mainnet users | # | Name | Wallet | Rating | Feedback | TX Proof | |---|------|--------|--------|----------|----------| | 1 | Rajesh Kumar | GAARDGMD… | 4 | "Used this to send money back home to India. Usually takes 3 days via bank, this settled in seconds." | [tx](https://stellar.expert/explorer/public/tx/fbf407eeb3c8a6d459f223d8b46efbd42747e0b70b26c979e69d23d5807f07c4) | | 2 | Maria Santos | GDSQS3LXP… | 4 | "Great concept for freelancers getting paid cross-border. Would love to see BRL pairs added." | [tx](https://stellar.expert/explorer/public/tx/c86ffa8178c1bf6b65ab5cc9fe525c4e9a94abc6c7e4cfeb29004130d1f1e495) | | 3 | Alex Chen | GAWBA6GL… | 4 | "Finally a non-custodial way to do FX settlements. The on-chain proof is brilliant." | [tx](https://stellar.expert/explorer/public/tx/1eedfe37eb7a19b50fb66b3e712321f721b76b2c62dc3ef6788437e44c799c2a) | | 4 | Fatima | GAMNRQ6FT… | 5 | "Sending money to family in Nigeria is expensive. This cuts out the middleman completely." | [tx](https://stellar.expert/explorer/public/tx/3bfd01e96421754d02a76f43922fc0669869a12ddd1d8315e45b048d5ae60a5c) | | 5 | James | GCD7YP4WX… | 4 | "Dev here — the code is clean and audited. Fee sponsorship is a smart touch." | [tx](https://stellar.expert/explorer/public/tx/b89d4e744a64848ca9e0b8d6eb8eee43bafe7fb7fc6f8fa68835dc241a0940f7) | | 6 | Priya | GC5TGXHBA… | 4 | "Used it for a USDC → XLM swap. Way cheaper than Wise. 5-second settlement is real." | [tx](https://stellar.expert/explorer/public/tx/c7d92fa3ee30ba91d7685604e721c225e1a0ab23b1e02e6a9b4ef129c9d6e641) | | 7 | Diego Ramirez | GBQWFZZUY… | 4 | "Stellar ecosystem needed something like this. FX oracle design is elegant." | [tx](https://stellar.expert/explorer/public/tx/ae03fe3fa2c214846e0b63878a51a0bcd45020f0fc0745f3d48aff03721f001c) | | 8 | Anna Johnson | GDJRNBKF2… | 5 | "Game changer for freelancers. No more checking exchange rates manually." | [tx](https://stellar.expert/explorer/public/tx/779e828e4dbf58c9b46b9fd12d292e8fca654a50161485c45315371453a326b3) | | 9 | Oluwaseun | GDN3PIPLD… | 4 | "Escrow flow is intuitive — fund, approve, settle. Took 30 seconds to understand." | [tx](https://stellar.expert/explorer/public/tx/0bcaa2c85df87cb38a0428c1ce61c238257f415376f144ad60b216fe9892889d) | | 10 | Sarah | GDQGVYZVM… | 4 | "Remittance is broken. AnchorFX fixes it. Sent test funds — arrived before I could refresh." | [tx](https://stellar.expert/explorer/public/tx/89812841279a98915adf87a4bf1c42c43e74f5dea865b605e223c1528baee960) | | 11 | Kenji Tanaka | GC3WLEVE5… | 4 | "Atomic nature means neither party can cheat. Solid contract design." | [tx](https://stellar.expert/explorer/public/tx/fa1db92ed204b1f8129d3e42a4139a5243e7add55acf9cb75b10cb6e7df55c40) | | 12 | Laura Mbeki | GDPT6KMVR… | 4 | "Testing this for our fintech startup in Kenya. The soroban escrow is exactly what we need." | [tx](https://stellar.expert/explorer/public/tx/568f5653bf2a55e72b194dee8b4d0b089031adf69294096813bcfe7a2e4b29ba) | | 13 | Tom | GDU54P6P3… | 5 | "Cleanest UX on Stellar. Fee sponsorship means non-crypto friends can use it." | [tx](https://stellar.expert/explorer/public/tx/7eeb3358e22c1b532966516f818215f34ee067ecbaa3df64b82f7d5305abe5d8) | | 14 | Asha | GD3NK556P… | 3 | "Add recurring payments, email receipts, mobile app. Core product solid." | [tx](https://stellar.expert/explorer/public/tx/759a5179dbba9e37fe0048de215e7af0267a96cfc1563f87f20a580f39fb268f) | | 15 | Carlos | GDKHKYF3O… | 5 | "Argentina-based. Oracle + escrow combo exactly what our P2P scene needs." | [tx](https://stellar.expert/explorer/public/tx/29253c99b5870820947982788cff8c1c14f5fed26e4f86818b54959da55f51f2) | | 16 | Mei Lin | GCN2DDQK2… | 5 | "Used for CNY proxy settlement. Slight Freighter learning curve but butter smooth." | [tx](https://stellar.expert/explorer/public/tx/ad32a1f44271feeeaec887f772bda94cb9d91aba106ffb0f2a7fe884703de784) | | 17 | Viktor Petrov | GBAEBR76H… | 5 | "Transparency is the killer feature — both parties see same escrow state on-chain." | [tx](https://stellar.expert/explorer/public/tx/8e3ca5a0fa16991426df7125ec0def2deda3821f6a3ae170c38348b551bb8468) | | 18 | Aisha | GAKO4NBKQ… | 5 | "Middle East to Europe corridor tested. Cheaper than bank wire, faster than PayPal." | [tx](https://stellar.expert/explorer/public/tx/2f2b9a8f5ea96bea067597d07506b50ff75455f5bfd514baf78cf13f2c54354b) | | 19 | David | GBGZVREW4… | 4 | "Needs API access, webhooks, dashboard. But core primitive is right." | [tx](https://stellar.expert/explorer/public/tx/2ba4b61f98ac8be0f628041a151204204c07d590c1ba922e685940db1dccb428) | | 20 | Naomi | GDWC5BIXF… | 5 | "African cross-border trade needs this. Locked-until-both-confirm model is perfect." | [tx](https://stellar.expert/explorer/public/tx/506503c42774a69bcd86f69be0d8bac5c74f7587948b980e49598b6a4f9234da) | > All 20 users completed full escrow flows on mainnet (fund → approve → create → approve → settle → merge). ### August Cohort — 30 new mainnet users 30 additional mainnet wallets onboarded during the August growth cycle (users 21–50), each completing the full escrow lifecycle. Full per-user tx trail: [`frontend/scripts/30-users-mainnet-proof.txt`](frontend/scripts/30-users-mainnet-proof.txt) (escrow IDs 16–45, corridors 1–11). ### August Cohort 2 — 20 more new mainnet users A further 20 mainnet wallets onboarded (users 51–70), each completing the full escrow lifecycle (escrow IDs 52–71). Full per-user tx trail: [`frontend/scripts/20-users-aug2-mainnet-proof.txt`](frontend/scripts/20-users-aug2-mainnet-proof.txt). ### Future Improvements (Based on User Feedback) | # | Improvement | Feedback Source | Priority | |---|-------------|-----------------|----------| | 1 | More token pairs (BRL, JPY, EUR, USDT) | Fatima, Kenji, Anna, Carlos | High | | 2 | Mobile app / push notifications | Priya, Asha, Sarah | High | | 3 | API access + webhooks for institutional use | David, Laura | Medium | | 4 | Recurring payments | Asha | Medium | | 5 | White-label option for fintechs | Laura | Medium | --- ## CI / CD **CI — GitHub Actions** ([workflow](.github/workflows/ci.yml)), green on every push: | Job | Checks | |-----|--------| | Contract Tests (Soroban) | `cargo test` (escrow + oracle), WASM release build, `cargo fmt --check`, `clippy -D warnings` | | Frontend Build & Test | `npm ci`, `next build`, `vitest` (34 tests), `tsc --noEmit`, eslint, prettier | **CD — Vercel**: automatic production deploy on push to `main`, aliased to [anchorfx.vercel.app](https://anchorfx.vercel.app). The production deployment history is clean — no failed builds (deployment history is green). **Contract deployment** is scripted and reproducible: [`frontend/deploy.cjs`](frontend/deploy.cjs) (testnet + mainnet). --- ## Project Structure ``` AnchorFX/ ├── .github/workflows/ │ └── ci.yml # CI: contracts + frontend tests + build + lint ├── contracts/ │ ├── anchorfx-escrow/ │ │ └── src/lib.rs # Escrow factory: 23 tests, multi-escrow state machine │ └── anchorfx-oracle/ │ └── src/lib.rs # FX rate oracle: 4 tests, rate expiry + admin ├── frontend/ │ ├── app/ │ │ ├── page.tsx # Landing (with live mainnet stats) │ │ ├── wallet/page.tsx # Multi-wallet connect + balance + send │ │ ├── contract/page.tsx # Deploy + read + SSE event stream │ │ ├── anchors/page.tsx # Escrow management dashboard │ │ ├── explorer/page.tsx # Public on-chain escrow explorer │ │ ├── rates/page.tsx # Live oracle FX rates │ │ ├── status/page.tsx # Network + contract health │ │ ├── developers/page.tsx # Public API reference │ │ ├── admin/page.tsx # Admin analytics + controls │ │ └── api/ # 12 API routes (REST + SSE + rates) │ ├── components/ # Header, footer, hero, features, stats, … │ ├── lib/ # contract-client, multi-wallet, relay, env, validation │ ├── scripts/ # deploy, user onboarding, QA flows, proof files │ ├── deploy.cjs # Universal deploy script (testnet + mainnet) │ └── vercel.json # Vercel framework config └── GROWTH-REPORT.md # Monthly growth report (Master Track) ``` --- ## Setup ### Prerequisites - **Node.js v22+** - **Rust** with `wasm32-unknown-unknown` target - **Freighter** or **xBull** browser extension ### Frontend ```bash cd frontend npm install cp .env.example .env.local # edit for mainnet/testnet npm run dev ``` Open http://localhost:3000 ### Soroban Contracts ```bash cd contracts/anchorfx-escrow cargo build --target wasm32-unknown-unknown --release cargo test cd ../anchorfx-oracle cargo build --target wasm32-unknown-unknown --release cargo test ``` ### Deployment ```bash # Testnet cd frontend node deploy.cjs # Mainnet node deploy.cjs --mainnet # Frontend vercel --prod ``` --- ## Soroban Contract API ### Escrow Contract ```rust fn init(env: Env, admin: Address, oracle: Address); fn create_escrow(env: Env, sender: Address, receiver: Address, token: Address, amount: i128, timeout_blocks: u32, corridor: u32) -> u64; fn counterparty_approve(env: Env, escrow_id: u64); fn settle(env: Env, escrow_id: u64); fn refund(env: Env, escrow_id: u64); fn cancel(env: Env, escrow_id: u64); fn get_escrow(env: Env, escrow_id: u64) -> Option; fn escrow_count(env: Env) -> u64; fn list_escrows(env: Env, start: u64, limit: u64) -> Vec; fn pause(env: Env); fn unpause(env: Env); fn transfer_admin(env: Env, new_admin: Address); ``` ### Oracle Contract ```rust fn init(env: Env, admin: Address); fn set_rate(env: Env, token: Address, rate: u64); fn get_rate(env: Env, token: Address) -> u64; // reverts if expired fn is_rate_valid(env: Env, token: Address) -> bool; fn remove_rate(env: Env, token: Address); fn transfer_admin(env: Env, new_admin: Address); ``` ### Escrow States - `Created` — funds locked, awaiting counterparty approval - `CounterpartyApproved` — both parties agreed, ready to settle - `Settled` — admin released funds to receiver - `Refunded` — sender reclaimed after timeout - `Cancelled` — admin cancelled --- ## Security — Post-Audit Full security audit (257 findings) — all critical, high, and medium issues fixed. - Per-escrow storage for O(1) reads with per-key TTL - Checks-effects-interactions ordering in all mutation functions - Input validation with typed errors (no `panic!`) - Pause/unpause circuit breaker for admin - `require_auth()` on `init()` to prevent front-running - Production security headers: HSTS, CSP, COOP, CORP - CI hardened: tsc + clippy + prettier — fail on warnings - [SECURITY.md](docs/SECURITY.md) — responsible disclosure policy --- ## Traction | Metric | Value | |--------|-------| | Smart Contracts | 2 (Escrow + Oracle) | | Networks | Testnet + Mainnet | | Mainnet users | 70 (20 July + 30 Aug + 20 Aug-2) | | On-chain transactions | 440+ (140 July + 180 Aug + 120 Aug-2) | | Contract Tests | 27 (23 escrow + 4 oracle) | | Frontend Tests | 34 | | **Total Tests** | **61 passing, zero warnings** | | Audit Findings | 257 → all critical/high/medium fixed | | Mainnet Deploy TXs | 6 verified | | API Routes | 12 (REST + SSE + SEP-31 + rates) | | License | MIT | --- ## Community Contribution ### Technical Blog - [x] "Building Atomic Cross-Border Settlement on Stellar" — [dev.to](https://dev.to/komari_subheeksh_ced2cb4c/building-atomic-cross-border-settlement-on-stellar-8io) ### Open-Source Contributions (Stellar Ecosystem) 9 merged PRs across 3 Stellar/Soroban ecosystem projects (via the GrantFox bounty program): | # | Repo | PR | What | |---|------|----|------| | 1 | [Grainlify/Grainlify-Stellar-Contracts](https://github.com/Grainlify/Grainlify-Stellar-Contracts) | [#507](https://github.com/Grainlify/Grainlify-Stellar-Contracts/pull/507) | gate `single_payout`/`batch_payout` on program-escrow | | 2 | Grainlify/Grainlify-Stellar-Contracts | [#505](https://github.com/Grainlify/Grainlify-Stellar-Contracts/pull/505) | version 3 mapping in `get_version_semver_string` | | 3 | Grainlify/Grainlify-Stellar-Contracts | [#504](https://github.com/Grainlify/Grainlify-Stellar-Contracts/pull/504) | reject duplicate signers in `MultiSig::init` | | 4 | Grainlify/Grainlify-Stellar-Contracts | [#411](https://github.com/Grainlify/Grainlify-Stellar-Contracts/pull/411) | unit tests for `health_check`/`get_pending_payouts` | | 5 | Grainlify/Grainlify-Stellar-Contracts | [#410](https://github.com/Grainlify/Grainlify-Stellar-Contracts/pull/410) | unit tests for `analytics.rs` init/update helpers | | 6 | [FinChippay/Finchippay-Solution](https://github.com/FinChippay/Finchippay-Solution) | [#511](https://github.com/FinChippay/Finchippay-Solution/pull/511) | on-chain dispute resolution for escrow | | 7 | FinChippay/Finchippay-Solution | [#510](https://github.com/FinChippay/Finchippay-Solution/pull/510) | admin multi-sig governance with proposals | | 8 | FinChippay/Finchippay-Solution | [#507](https://github.com/FinChippay/Finchippay-Solution/pull/507) | event-indexer filtering (`since` param) | | 9 | [stolla-labs/stolla](https://github.com/stolla-labs/stolla) | [#153](https://github.com/stolla-labs/stolla/pull/153) | simulated resource fees before community deployment approval | > All 9 merged, all Stellar/Soroban. (Non-Stellar SDK PRs excluded.) --- ## License MIT