x402 temperature demo · architecture
Two C4 views of the whole solution: the container diagram (what the pieces are and how they talk) and the deployment diagram (where each piece physically runs, from the cloud down to the physical sensor at home). Amber edges carry value; blue edges carry data; dashed grey is state & telemetry.
A human learner — follows the 3-step flow and approves each payment in the wallet.
Holds the Sui keypair. Signs the gasless payment tx via the Wallet Standard — and never submits it.
Renders the annotated protocol steps and raw HTTP frames; builds the canonical payment transaction (withdrawal → redeem_funds → send_funds, ValidDuring bound to the challenge); polls the seller log.
/api/temperature — issues single-use 402 terms, verifies X-PAYMENT structurally,
fetches the reading, settles on Sui, serves.
/api/events — the seller’s side of the story.
challenges (10 min TTL) · digest replay store (3 d) · event log
USDC settlement, ~400 ms finality. The seller verifies directly over gRPC — no facilitator.
Secret-path API over Home Assistant — the same service t2000 sells for real money on mainnet.
api/temperature · api/events