Examples
Tested source and focused examples for Lucid's machine-commerce runtime.
Start with the paid service quickstart. Its seller
and buyer files are compiled and exercised together in CI: the first request
returns 402, the buyer signs and retries, and the service returns a settled
response.
The pages here explain larger repository examples. Treat them as Next examples: clone the repository and use its workspace versions rather than copying them into a Stable application.
git clone https://github.com/daydreamsai/lucid-agents.git
cd lucid-agents
bun install
bun run build:packagesPaid seller and buyer
The Stable, clean-room-tested x402 transaction.
Core composition
HTTP, payments, wallets, identity, invoke, and streaming in one runtime.
Lucid multi-service tasks
Agent Card-shaped discovery and Lucid-owned task routes (not A2A v1 conformance).
Every x402 seller method
Exact EVM/Solana, upto, batch settlement, SIWX, reconciliation, and Stripe destination mode.
Every MPP method
Tempo charge/session, Stripe, EVM, custom, Lightning descriptors, and operation support.
Scheduled calls
Leased, idempotent recurring A2A invocations.
Stripe destination mode
Provider-specific dynamic destination resolution.
Small MPP charge service
A compact Tempo charge server after the complete MPP tutorial.
Shared environment contract
Use the prefixed payment variables in new applications:
PAYMENTS_FACILITATOR_URL=https://YOUR_FACILITATOR_URL
PAYMENTS_RECEIVABLE_ADDRESS=0xYOUR_ADDRESS
PAYMENTS_NETWORK=eip155:84532
AGENT_WALLET_PRIVATE_KEY=0xYOUR_PRIVATE_KEYThe facilitator, network, asset, and signer must support the same x402 scheme. See the exact x402 support matrix before choosing a production provider.