Universal MCP-native service discovery and autonomous payment infrastructure. AI agents discover, evaluate, and pay for any Stellar x402 service — without a single hardcoded integration.
Built for the Agents on Stellar Hackathon · April 2026
AI agents can reason, plan, and act — but stop cold when they need to pay for an API call. Today's MCP servers hardcode one service URL per server. Agents are economically blind.
Authora fixes this. One MCP server. Infinite discoverable paid services. Zero hardcoded URLs.
- Service operators register any x402 endpoint in the Authora Soroban contract (permissionless, on-chain)
- Authora generates a live MCP tool manifest from all registry entries — dynamically, no code changes
- AI agents using Claude, GPT, or Gemini discover and call any registered service, paying USDC via hardened x402 settlement logic
- SpendingGuard Safety: Autonomous protection layer that blocks prompt injections and prevents overspending via real-time session budgets.
- Worker Economy: specialized "Worker Agents" that earn USDC from Orchestrator agents for complex missions.
- Judge-Ready Dashboard: Provides a live, premium visual feed of every 64-character on-chain transaction hash.
Authora is a production-stabilized infrastructure for agentic payments:
- SpendingGuard Protection: Autonomous detection of prompt injections (e.g., "ignore rules") and session-based financial safety rails.
- Agent-to-Agent (A2A) Missions: Support for worker agents that accept x402 and MPP payments for intelligence tasks.
- Canonical SAC Enforcement: Automated override to the live Circle USDC SAC (
CBIELTK6...) to bypass legacy server errors. - Transactional Fee Clamping: Implemented the official Stellar x402 fee-clamp (1 stroop) to prevent testnet facilitator rejection.
graph TB
subgraph AI["AI Agent Layer"]
C[Claude / GPT / Gemini]
end
subgraph MCP["Authora MCP Server"]
direction TB
M[MCP Tool Dispatcher]
E[estimate_service_cost]
W[check_wallet_balance]
L[list_x402_services]
CALL[call_registered_service]
PH[get_payment_history]
GUARD[SpendingGuard Security]
MPP[test_worker_mpp]
end
subgraph STELLAR["Stellar Network"]
direction TB
REG[("Soroban Registry Contract\nCAH62...GQ7X")]
USDC["USDC\nCBIELTK6..."]
OZ["OpenZeppelin Facilitator\nchannels.openzeppelin.com"]
end
subgraph SERVICES["x402 Services"]
S1["Stellar Space Weather\n0.001 USDC/call"]
S2["Stellar Price Feed\n0.001 USDC/call"]
S3["Ecosystem Search\n0.001 USDC/call"]
end
C -->|"Tool call"| GUARD
GUARD -->|"Verified"| M
M --> E & W & L & CALL & PH & MPP
L -->|"list_services()"| REG
CALL -->|"fetchWithPayment()"| OZ
OZ -->|"verify + settle"| USDC
USDC -->|"transfer()"| SERVICES
CALL -->|"HTTP response"| C
PH -->|"txHash + Explorer link"| C
MPP -->|"MPP Charge intent"| STELLAR
style AI fill:#0a0a0a,color:#00e5a0
style MCP fill:#111,color:#f0ebe0
style STELLAR fill:#0d1117,color:#7c6bff
style SERVICES fill:#0a0a0a,color:#f5c058
| Category | Tool | Description |
|---|---|---|
| Discovery | list_x402_services |
Query Soroban registry for all live services |
get_mcp_manifest |
Generate dynamic JSON tool manifest from on-chain data | |
| Intelligence | check_wallet_balance |
Real-time USDC/XLM via Horizon API |
estimate_service_cost |
Total cost estimation before execution | |
| Execution | call_registered_service |
Auto-pay any registered service via x402 |
fetch_paid_resource |
Direct x402 fetch for any URL | |
| Verification | get_payment_history |
Session log with Stellar Explorer links |
get_service_schema |
Detailed JSON metadata for agentic services | |
| MPP | test_worker_mpp |
Real-time MPP Pull payment testing |
| Registry | register_x402_service |
Register any x402 endpoint on-chain |
| Safety | check_spending_policy |
View real-time budget and security status |
reset_spending_session |
Reset safety counters for a new session | |
| Security | verify_stellar_proof |
On-chain validation of x402 receipts |
| Diagnostics | x402_wallet_info |
Wallet config and contract addresses |
x402_facilitator_supported |
OZ facilitator health check |
- User: "Search the Stellar ecosystem for DeFi protocols"
list_x402_services()→ discovers "Stellar Ecosystem Search · 0.001 USDC"estimate_service_cost()→ confirms "$0.001 USDC total"call_registered_service()→fetchWithPayment(url)- GET https://xlm402.com/search?q=DeFi
- 402 Payment Required
ExactStellarScheme.createPaymentPayload()- Soroban auth entry signed with Ed25519 keypair
- OZ Facilitator verifies + settles USDC on Stellar
- 200 OK +
PAYMENT-RESPONSEheader withtxHash
get_payment_history()shows: ✓ Stellar Ecosystem Search | 0.0010000 USDC |a3f9c2...
Every step produces a real Stellar transaction. No mocks.
The AuthoraRegistry contract is deployed on Stellar testnet.
Contract ID: CAH62PSPXNCIGD5F5IWOZEG2QY2ABPMTFFAZXURDGYRXT3AHL725GQ7X
Functions:
register_service(caller, entry)— permissionless service registrationlist_services(offset, limit)— paginated service discoveryget_service(url)— individual service lookuprecord_payment(url, payer)— on-chain payment counter incrementremove_service(caller, url)— owner-only removalservice_count()— total registry size
x402 is the core payment protocol. Every call_registered_service invocation:
- Makes an HTTP request to the x402-protected endpoint
- Receives
402 Payment RequiredwithPAYMENT-REQUIREDheader ExactStellarScheme.createPaymentPayload()signs a Soroban auth entry authorizing a USDC transfer- OpenZeppelin facilitator verifies the auth entry signature and submits the transaction
- USDC (
CBIELTK6YBZJU5UP2WWQEUCYKLPU6AUNZ2BQ4WWFEIE3USCIHMXQDAMA) moves on-chain - Facilitator returns
PAYMENT-RESPONSEheader withtxHash - Authora records the
txHashfor verification
Facilitator: https://channels.openzeppelin.com/x402/testnet
Authora natively supports Stripe's Machine Payments Protocol (MPP). Key features:
- Pull-based payments: Agents authorize credentials once; the service pulls exact amounts per request.
- Native Settlement: Every MPP charge settles natively on Stellar as a USDC transfer.
- Real-time Receipts: Using our integrated MPP client, Authora decodes payment receipts to extract valid on-chain transaction hashes instantly.
To handle the inherent latency of x402 facilitators and testnet indexing:
- Dedicated Polling: Authora employs a hyper-active polling logic (5 attempts with backoff) to capture transaction hashes.
- Protocol Agnostic: Whether it's an x402 auth-entry (push) or an MPP charge (pull), you get a real 64-character hash that resolves on Stellar Expert.
- Zero Placeholders: Placeholders like
pending ingestionautomatically resolve into clickable links once confirmed by the network.
Authora doesn't just pay; it manages its own economic lifecycle autonomously.
- Atomic Multi-Disbursement: Batch up to 100 payments (XLM or USDC) in a single atomic transaction for efficient payroll or distribution.
- DEX Liquidity Management: Autonomously swap native XLM for USDC via Stellar's path payments to replenish service-call reserves.
- Trustline Onboarding: Enable assets (like USDC) on fresh wallets without manual intervention using the
add_usdc_trustlinetool. - Asset Support: Native support for XLM and credit-based assets (USDC) out of the box.
Authora exposes the following high-level tools to the AI Agent:
list_x402_services: Fetch the entire Soroban registry of paid tools.x402_wallet_info: View current wallet balances (XLM/USDC) and public address.get_payment_history: Audit all previous x402/MPP transactions with real-time clickable links.add_usdc_trustline: Establish the official USDC trustline on the configured wallet.swap_xlm_to_usdc: Convert XLM to USDC on the Stellar DEX for liquidity.autonomous_disbursement: Execute atomic batch payments to multiple recipients.
call_registered_service: Executes a paid API call from the registry. Automatically handles the x402 Push or MPP Pull protocol handshake and submits payment on-chain.
Authora is designed for the hybrid web3 agent economy:
- x402 (Push): The agent receives a 402 challenge, signs an authorization, and pushes funds to the facilitator. Ideal for stateless, per-request billing.
- MPP (Pull): Direct micro-payment protocol where the resource server "pulls" an authorization reference. Ideal for high-frequency resource streaming.
- Node.js 20+
- Funded Stellar testnet wallet
- OpenZeppelin facilitator API key (free, instant)
# Create keypair at: https://laboratory.stellar.org
# Fund with Friendbot, then get USDC from Circle faucet
# Or run the wallet prep script:
npm run prepare-wallethttps://channels.openzeppelin.com/testnet/gen
cp .env.example .env
# Fill in: STELLAR_SECRET_KEY, X402_FACILITATOR_API_KEY, SELLER_ADDRESSnpm install
npm run dev # MCP stdio server + HTTP API on :3001
npm run demo-service # x402 price feed on :3000
npm run seed # Register services in Soroban registry{
"mcpServers": {
"authora": {
"command": "node",
"args": ["/absolute/path/to/authora/dist/index.js"],
"env": {
"STELLAR_SECRET_KEY": "S...",
"REGISTRY_CONTRACT_ID": "CAH62PSPXNCIGD5F5IWOZEG2QY2ABPMTFFAZXURDGYRXT3AHL725GQ7X",
"X402_FACILITATOR_URL": "https://channels.openzeppelin.com/x402/testnet",
"X402_FACILITATOR_API_KEY": "your-key-here"
}
}
}
}- "Check my wallet balance"
- "List all available x402 services"
- "Estimate the cost to call the Stellar price feed once"
- "Call the Stellar price feed service"
- "Show my payment history"
- "Swap 50 XLM for USDC to refill my budget"
- "Send 5 XLM to [Address] and 0.1 USDC to [New Address] in one transaction"
- "Set up a USDC trustline on my current wallet"
Every payment Authora makes is publicly verifiable:
- Ask Claude: "Show my payment history"
- Copy the transaction hash from the output
- Visit:
https://stellar.expert/explorer/testnet/tx/<txHash> - See the real USDC transfer on Stellar testnet
Or use our verification endpoint:
GET http://localhost:3001/demo/verify-payment/<txHash>
| Endpoint | Description |
|---|---|
GET /manifest |
Dynamic MCP tool manifest (30s cache) |
GET /services |
Paginated service registry |
GET /payments |
Live payment feed + stats |
GET /payments/stats |
Aggregate payment statistics |
GET /demo/verify-payment/:txHash |
On-chain transaction verification |
POST /services/register |
Register service (operator auth required) |
record_paymentin the Soroban contract has no caller auth — any address can increment the counter. Production version would restrict this to a trusted operator.- MPP integration is a demonstration of the
Chargeintent pattern; full MPP Session (payment channels) requires theone-way-channelSoroban contract. - Dashboard payment feed is in-memory (session-scoped); data resets on server restart.
- x402 on Stellar — core protocol
- x402-mcp-stellar — base MCP server
- stellar/x402-stellar — monorepo + examples
- Built on Stellar Facilitator — OZ relayer
- MPP on Stellar — MPP integration
- Stellar sponsored accounts — wallet onboarding
- Stellar CLI — contract deployment
- Soroban authorization — auth entries
MIT