The vault was designed before the first deposit exists. The whole exchange planned once — the client rebuilt for every device, the cockpit staffed-ready, three chains feeding a custody core engineered to production standard.
GreenX Exchange runs today on a rented SaaS platform. Tomorrow it is a fully self-developed system GreenX owns down to the last key, table, and deploy pipeline — executed without interrupting the business already running on it. Three planning principles govern the program, fixed now and enforced architecturally forever.
Years of proven business logic — accounts, asset flows, eco interoperation — are retained as the functional spec. The implementation beneath them is replaced with one GreenX controls. Not a redesign; a repossession.
Phase 1 builds the asset-security and custody architecture to production standard first; the matching engine waits for Phase 2. An exchange survives a delayed feature. It does not survive a custody failure.
There is no fourth state. "Reserved" is a Phase-1 engineering obligation — interface cut, schema provisioned, tests pre-written. Never a slide-deck aspiration.
Renting an exchange was right when speed mattered most. It is the wrong steady state for a platform that intends to matter. Four arguments, and they compound — watch what ownership changes:
On SaaS, key generation and signing paths are a vendor's black box — GreenX carries liability for security it cannot inspect.
The asset bridge to 3–5 GreenX apps is the genuine differentiator — exactly what multi-tenant SaaS can only half-support.
SaaS fees purchase continuity, not equity: no codebase, no data asset, no compounding capability.
Multi-tenant platforms share incidents and upgrade windows across tenants. GreenX's uptime should be a function of GreenX's engineering.
The contract between phases. BUILT ships inside the 45-day window. RESERVED means the socket exists before the plug. PLANNED is roadmapped with explicit dependencies. Note the shape: on this program, the vault is BUILT and the engine is RESERVED — security before trading, made structural.
| # | Domain | Phase-1 state |
|---|---|---|
| D1 | Product Planning & UI/UX Design SystemThe whole exchange drawn once · IA · flows · component system · prototype · handoff | BUILT |
| D2 | Web App — User Center, KYC & Security (PWA)16 modules · OTP · eKYC state machine · WebAuthn · TOTP · web push · install-to-home-screen | BUILT |
| D3 | Web App — Asset Center & Eco Account16 modules · multi-chain deposit/withdraw · internal transfers · eco out/return · unified statements | BUILT |
| D4 | Web App — Spot & Futures Trading UI16 modules · production display grade on third-party data · execution gated to Phase 2 | BUILT R1 SOCKET |
| D5 | Web3 Wallet Module8 modules · authorize + UID bind · eco→DApp transfers · create/import gated per brief | BUILT |
| D6 | Admin Ops, Data & Reporting Cockpit20 modules · KYC desk · withdrawal desk · config · ETL · reconciliation · risk board | BUILT |
| D7 | Asset-Security & Custody Architecture14 modules · TRON/ETH/BSC · hot/cold gradient · multisig · approval workflows · the Phase-1 priority | BUILT · PROD STD |
| D8 | Matching Engine & Live Order ExecutionInterface pre-cut · quantitative core exists in Perp Solution v0.1 | RESERVED |
| D9 | Native Apps · More Chains · Fiat ChannelsSame API surface · R4/R7 shells · admitted by dependency chain | PLANNED |
The brief's own principle, taken seriously rather than apologetically: matching and live execution are Phase 2. What that discipline buys in 45 days:
Users see and touch the entire exchange — onboarding, security, assets, eco flows, markets, wallet — indistinguishable in polish from a live venue.
Deposits, balances, transfers and withdrawals are production systems holding real assets under the D7 architecture. The most dangerous subsystem ships first and hardest.
The cockpit plus runbooks mean the platform is operable — staffed reviews, reconciliations, alerts — before trading volume arrives to stress it.
The floor consumes a normalized internal schema and the ledger already carries trading journal classes — switching on the engine changes the producer of events, not the consumers.
The floor consumes one normalized market-data and order-state schema. Phase 1's producer is the feed relay; Phase 2's is the in-house engine. A producer swap — clients notice nothing.
Order, trade and position tables ship complete — populated by display states now, activated by the engine later. Live trading activates columns; it never migrates tables.
Trade-settlement, fee and margin journal classes pre-cut; trading and eco accounts share one ledger and one conservation invariant from birth.
Every chain integrates through one adapter contract — derivation, scanning, broadcasting, finality policy. Chain N+1 is an adapter plus configuration, not a project.
The 3–5 eco apps connect through a versioned adapter API — auth, intents, callbacks, idempotency, quotas. Onboarding app N+1 becomes registration, not development.
Limits, features and jurisdictions key off KYC tier at the auth and withdrawal choke points from day one. An RWA tier is configuration, not surgery.
PWA and future native apps are shells over one API surface; WebAuthn maps to biometrics, Web Push to FCM/APNs. Phase 3 inherits everything, re-implements nothing.
Every ledger and operational event doubles as an analytics fact through the cockpit's ETL. Phase-3 BI consumes the log Phase 1 writes.
Parallel-track doctrine: the SaaS platform keeps serving users for the whole window; logic parity is signed off before improvement; data migration is a rehearsed, replayable event; and cutover proceeds by cohort with the old system as fallback. Watch a cohort move:
The complete self-developed exchange — client, cockpit, custody, eco fabric — operable and holding real assets, with trading display-complete. Seven weeks, exit criteria per week, interfaces frozen in week one.
In-house matching and live execution — spot first, then futures — activated behind the existing floor with shadow validation against the reserved schemas, per the quantitative core already written.
Create/import and the full DApp runtime graduate from "coming soon" gates to production, extending the eco fabric on-chain.
Native apps on the R7 shell, additional chains through R4 adapters, fiat channels, deeper BI on R8, and RWA listings under the R6 policy machinery.
State_t = f( State_0, e_1, e_2, …, e_t ) // every posting strictly double-entry Σ balances (trading + eco) + fees + treasury float = Σ deposits − Σ withdrawals
Every monetary state change — credit, transfer, eco movement, fee, withdrawal — is one sequenced journal event, debiting one account class and crediting another. Conservation is asserted continuously, not audited quarterly. Watch the journal breathe:
The Phase-1 centerpiece, running live: TRON, Ethereum and BNB Chain feed reorg-safe scanners; the hot wallet fills toward the watermark W*, then sweeps to cold multisig. The only road back runs through machine risk checks and a 2-of-N approval gate.
// keys are governed, not kept KMS envelope keys · role separation · scheduled rotation · single-call revocation every control is cryptographic, double-entry, or dual-control // no security property rests on one honest human
Every movement between the exchange and a GreenX eco application posts as a paired journal — debit here, credit there — so conservation extends across the whole ecosystem. An eco app can never mint, strand, or double-spend platform assets without tripping the invariant. Try it yourself:
Σ exchange balances + Σ eco-app balances = Σ deposits − Σ withdrawals // per asset · continuously asserted adapter contract: per-app keys · transfer intents · idempotency · quotas · quarantine switch
P(reorg ≥ k) ≈ (q/p)^k k(V) = ⌈ log(ε/V) / log(q/p) ⌉ // per chain · per tier · never one magic number
S(w) = Σᵢ βᵢ·xᵢ(w)
xᵢ ∈ { amount/tier-limit · velocity(1h·24h·7d) · address novelty · device/geo drift · KYC tier }
route: S < θ₁ → auto-approve
θ₁ ≤ S < θ₂ → dual-approval review
S ≥ θ₂ → block + alert
// hot-wallet watermark — a newsvendor bound on compromise exposure // the same construction sizes each chain's gas float W* = μ_out·T + z_ε·σ_out·√T minimize c_risk·E[hot] + c_fee·N_sweeps s.t. P(stockout) ≤ ε
And onboarding is a funnel whose product is conversion — every stage instrumented, vendor SLOs monitored, appeal a first-class state:
// the matching core is already specified — GreenX DEX Perp Solution v0.1 // spot matching is a strict subset · it activates first M/M/1 envelope: ρ = λ/μ = 0.1 at μ = 5×10⁵ ev/s, λ = 5×10⁴/s ⇒ E[W] = 1/(μ−λ) ≈ 2.2 µs
Note what is different from a trading-first program: all six invariants are live on day one — because Phase 1's product is the money machine. The trading invariants arrive with their engine, tests already written.
Adapter probes pause that chain's lane only; deposits show "delayed", withdrawals queue.
Heartbeat lapse pauses crediting — the platform never credits blind.
Submissions queue, manual-review lane widens, status banner shows.
Reconciliation alarms; freezes the affected lane above threshold.
Watermark and outflow monitors freeze withdrawals, isolate keys.
Quota or I3 trips quarantine that adapter — that app's lane only.
The module map fixes what exists; the reservation doctrine fixes how it grows; the custody mathematics fixes what any incident can cost; the invariants fix what the system will never permit. Phase 2 requires only the turning of keys that Phase 1 installs.