Built the first x402 micropayment implementation on Stacks.
HTTP 402 → pay 0.01 STX via Clarity contract → access gated API. No sessions, no API keys — just on-chain proof in an HTTP header.
The contract enforces nonce replay protection and Stacks post-conditions guarantee exact transfer amounts at the protocol level. Server verifies payment with a read-only Clarity call.
Full flow: request → 402 → wallet signs contract call → tx confirms → retry with proof → 200
Live demo + source:
x402-stacks.fixr.nexus
github.com/the-fixr/x402-stacks