A minimal open-source starter kit showing how to integrate the x402 Protocol into your app to enable AI-native micropayments and autonomous payment flows.
- Simple Express.js demo with
/api/x402route - Returns valid
402 Payment Requiredschema - Demonstrates how to register your project on x402scan.com
- Perfect for learning x402 + AI Payment Protocol
x402 is a modern internet standard that adds native payment support to the web, reviving the original HTTP 402 Payment Required status code.
It allows websites, APIs, and AI agents to charge or pay automatically — no wallets, pop-ups, and or manual confirmations.
- Clone this repo
git clone https://github.com/x402lite/x402Lite-Learning-Kit.git cd x402Lite-Learning-Kit - Install dependencies
npm install
- Run the server
npm start
- Test in browser Visit http://localhost:8080/api/x402 You’ll see a valid 402 Payment Required JSON response.