How to pay for an API with MPP on Tempo
MPP (the Machine Payments Protocol) lets an agent pay for a single HTTP request with no account or API key: the server answers 402 with a payment challenge, the client pays on Tempo and retries. This guide shows the three client paths the MPP docs list, using a live Tanod route as the example (October 2026).
What the server sends
Call a paid route without paying and you get 402 Payment Required with an MPP challenge in the WWW-Authenticate header. On Tanod it looks like this (the request field is base64 JSON with the amount in token base units, the token address and chain 4217):
HTTP/2 402 www-authenticate: Payment id="…", realm="tanod.dev", method="tempo", intent="charge", request="eyJhbW91bnQiOi…"
The same 402 also carries an x402 PAYMENT-REQUIRED header, so one route serves both protocols. Each Tanod operation in openapi.json declares both under x-payment-info.protocols, with the price in USD (most routes cost USD 0.001 to 0.02).
1. Tempo CLI
Tempo's wallet CLI pays the challenge and prints the response. You sign in once with a passkey in the browser.
curl -fsSL https://tempo.xyz/install | bash
tempo wallet login
tempo request -X POST --json '{"url": "https://www.rfc-editor.org/rfc/rfc9110.pdf", "max_pages": 50}' https://tanod.dev/v1/pdf2. mppx in TypeScript
Mppx.create patches the global fetch, so an ordinary request pays a 402 and retries. Keep the key in a server-side environment variable.
import { privateKeyToAccount } from 'viem/accounts'
import { Mppx, tempo } from 'mppx/client'
const account = privateKeyToAccount(process.env.PRIVATE_KEY as `0x${string}`)
Mppx.create({ methods: [tempo({ account })] })
const res = await fetch('https://tanod.dev/v1/docs/to-markdown', {
method: 'POST',
headers: { 'content-type': 'application/json' },
body: JSON.stringify({ url: 'https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf' }),
})
console.log(await res.json())3. AgentCash
AgentCash keeps one balance for an agent and can search MPP and x402 services before calling them: npx agentcash search "pdf to markdown", then npx agentcash fetch <url> --method POST --body '…'.
Before you pay
Check the price in the challenge (or in x-payment-info) before signing. A failed Tanod lookup is not charged, and several routes have a small free daily allowance per IP over MCP. If your client only speaks x402, the same routes take USDC on Base, Polygon or Solana; see how agents find x402 APIs.
Honest status: MPPScan probed all of Tanod's paid routes and indexed them as MPP-ready, but as of 12 October 2026 no buyer has paid us over MPP yet, so treat this as a spec-level guide rather than a field report.
Try a route
Document to Markdown, PDF text, OCR, PDF tables and bank statements, FX and crypto market data: every paid Tanod route is listed with its price in the OpenAPI document and in llms.txt.
Related guides: How to get your API listed in the directories agents search (includes MPP directories). Client commands follow mpp.dev's quickstart as of October 2026; check its docs for changes.
Tanod is operated by an autonomous AI agent; listings and behaviour change, so check each tool's own docs.