901180
OpenRouter
@openrouterai #901180
Discover and use the latest LLMs, privately, and pay with crypto. 300+ models. openrouter.ai
9 Follower 9 Following
Introducing our Crypto Payments API: the first way to script on-chain payments for any LLM 💸
Make an agent that can fund its own intelligence!
Works with ETH, @base, and more, powered by @coinbase and @uniswap . Details and tutorial:
Docs: http://openrouter.ai/docs/crypto-api
-----
STEP 1: Get an OpenRouter API key if you don’t have one already.
You can make as many keys as you want, with custom limits. openrouter.ai/keys
-----
STEP 2: Make a request for purchase calldata.
POST /api/v1/credits/coinbase with:
•amount in USD
•sender address
•chain_id (1, 137, or 8453)
Response gives charge details & call_data.
-----
STEP 3: Execute on-chain.
Use viem or a similar EVM client. Call swapAndTransferUniswapV3Native() with returned call_data
Here’s the first ever programmatic on-chain OpenRouter payment: https://basescan.org/tx/0x55402382b9997d4a21672d9e6de530ba4331da86dfa66db1b885f6e85d311349
Now agents can pay for their own intelligence! start building now:
Make an agent that can fund its own intelligence!
Works with ETH, @base, and more, powered by @coinbase and @uniswap . Details and tutorial:
Docs: http://openrouter.ai/docs/crypto-api
-----
STEP 1: Get an OpenRouter API key if you don’t have one already.
You can make as many keys as you want, with custom limits. openrouter.ai/keys
-----
STEP 2: Make a request for purchase calldata.
POST /api/v1/credits/coinbase with:
•amount in USD
•sender address
•chain_id (1, 137, or 8453)
Response gives charge details & call_data.
-----
STEP 3: Execute on-chain.
Use viem or a similar EVM client. Call swapAndTransferUniswapV3Native() with returned call_data
Here’s the first ever programmatic on-chain OpenRouter payment: https://basescan.org/tx/0x55402382b9997d4a21672d9e6de530ba4331da86dfa66db1b885f6e85d311349
Now agents can pay for their own intelligence! start building now: