Deployed Programs
All programs are built with Anchor 0.30.1 on Solana 1.18.22 and use the Token-2022 token standard.x0-guard
Policy enforcement via Token-2022 transfer hook. Rolling window spend limits, whitelist verification (Merkle, Bloom, Domain), and privacy levels.
x0-token
Token-2022 mint with TransferFee (0.8%), TransferHook (x0-guard), and optional ConfidentialTransfer extensions.
x0-escrow
Conditional escrow with 7-state machine: create → fund → deliver → release. Supports dispute resolution with arbiter and auto-release timeout.
x0-registry
Agent discovery service. Agents register with endpoint URLs and capability metadata. Supports activation/deactivation lifecycle.
x0-reputation
On-chain reputation oracle. Tracks success rate, dispute rate, failure rate, and response time. Weighted scoring with monthly decay.
x0-wrapper
1:1 USDC-backed stablecoin wrapper. Deposit USDC → mint x0-USD, burn x0-USD → redeem USDC. Timelocked governance with emergency pause.
x0-zk-verifier
On-chain Groth16 zero-knowledge proof verification for confidential transfers. Validates PubkeyValidity, ZeroBalance, Withdraw, and Transfer proofs.
x0-zk-proofs
Off-chain WASM library for client-side proof generation. Compiled to WebAssembly for browser and Node.js environments.
Shared Library: x0-common
Thex0-common crate provides shared infrastructure used by all programs:
| Module | Contents |
|---|---|
constants.rs | ~100 protocol constants: fees, time windows, limits, PDA seeds, account sizes, CU estimates |
error.rs | 7 error enums with ~122 structured error codes (0x1100–0x1721) |
events.rs | 27 event structs emitted by all programs |
state.rs | Shared types: EscrowState, Capability, AdminActionType |
utils.rs | Fee calculation, hashing, timestamp validation |
whitelist.rs | WhitelistMode enum, Merkle/Bloom/Domain verification functions |
Technology Stack
| Layer | Technology |
|---|---|
| Runtime | Solana 1.18.22 |
| Framework | Anchor 0.30.1 |
| Token Standard | Token-2022 (SPL Token Extensions) |
| Extensions Used | TransferHook, TransferFee, ConfidentialTransfer |
| Cryptography | Twisted ElGamal, Groth16, Ristretto255 |
| ZK SDK | solana-zk-token-sdk |
| Client SDK | TypeScript (@x0-protocol/sdk) |
| WASM | wasm-bindgen + wasm-pack |