AI Blog To Podcast Agent
This is a Streamlit-based application that allows users to convert any blog post into a podcast. The app uses OpenAI's GPT-4 model for summarization, …
- OpenAI
Starter Agents ·Easy
An AI agent with its own crypto wallet that pays for the data it needs - no API keys, no subscriptions, no signup.
ANTHROPIC_API_KEYX402_PRIVATE_KEYLicense Apache-2.0 · content curated and maintained by Doutor AI.
An AI agent with its own crypto wallet that pays for the data it needs - no API keys, no subscriptions, no signup.
Ask a question in plain English. Claude decides which paid API answers it and calls a fetch tool. The API responds 402 Payment Required with a price quote; the agent automatically pays it in USDC via the open x402 standard (now under the Linux Foundation) and answers from the data it just bought.
Everything in this tutorial is free and self-contained. You run the paid API yourself (seller.py, ~60 lines), payments settle in testnet USDC on Base Sepolia through the public x402.org facilitator, and the buyer wallet is funded from a free faucet. You are both the buyer and the seller, so you watch the full payment loop with zero real money involved. The exact same agent code works on mainnet against any live x402 API.
x402 SDK signs a USDC payment when an API challenges; the demo endpoints cost $0.001–0.002 in testnet USDCMAX_PRICE_USDC, default $0.05) so a misconfigured agent can never overspend--direct <URL> pays and fetches any x402 URL with just a wallet, so you can see the payment flow in isolationseller.py is a complete pay-per-call API in ~60 lines of FastAPI; reprice it, add endpoints, or point the agent at any other x402 sellergit clone https://github.com/Shubhamsaboo/awesome-llm-apps.git
cd awesome-llm-apps/starter_ai_agents/ai_x402_paying_agent
pip install -r requirements.txt
Any EVM wallet works (MetaMask, or python -c "from eth_account import Account; a=Account.create(); print(a.address, a.key.hex())"). You need:
export X402_PRIVATE_KEY='0x...' # buyer wallet private key
export SELLER_ADDRESS='0x...' # seller receive address
⚠️ Use dedicated throwaway wallets for this - never your main wallet.
Go to faucet.circle.com, pick Base Sepolia, paste the buyer address. You get test USDC instantly; no gas token is needed anywhere (x402 payments are gasless for both sides).
uvicorn seller:app --port 4021
Try it unpaid and watch the 402 challenge: curl -i http://localhost:4021/api/fortune
--direct mode)export ANTHROPIC_API_KEY='your-api-key-here'
# Full agent: natural-language question → paid data → answer
python x402_paying_agent.py "Roll me a d20 and read me my fortune"
# Payment flow only, no LLM needed:
python x402_paying_agent.py --direct "http://localhost:4021/api/fortune"
you ──question──▶ Claude ──tool call──▶ GET your local paid API
│ 402 Payment Required ($0.001)
▼
x402 SDK signs USDC payment
│ retry with payment header
▼
facilitator verifies + settles on Base Sepolia
│
200 OK + data ──▶ Claude answers
The whole payment negotiation is 3 HTTP requests and settles on-chain in seconds - and because you run the seller, you can watch both sides of it.
MAX_PRICE_USDC guard in this tutorial is a minimal version of the same idea - cap what an autonomous spender can spend before it spends it.This is a Streamlit-based application that allows users to convert any blog post into a podcast. The app uses OpenAI's GPT-4 model for summarization, …
This is an AI-powered application designed to help users emotionally recover from breakups by providing support, guidance, and emotional outlet messag…
An AI data analysis Agent built using the Agno Agent framework and Openai's gpt-4o model. This agent helps users analyze their data - csv, excel files…
Need a tailor-made solution?
Not sure where to start with AI in your business? Get a free assessment and a tailored plan - no commitment.
Doutor AI gives you 1,859 ready-to-copy AI prompts, by industry and in plain English - plus a complete technical library for those who want to go further.