{"uid":"cap_AaHzmyybBQymJoDpLz8a9","slug":"farout-pay-per-call-llm-inference-via-x402-23f97d23","name":"FarOut Pay-Per-Call LLM Inference via x402","description":"Pay-per-call LLM inference over x402. Frontier models (GLM, GPT, Gemini, Kimi, DeepSeek, MiniMax) billed per request in USDC on Base or Solana mainnet. No API key, no account. The 402 quotes your exact request; failed calls are never charged.","url":"https://farouter.tech/v1/metered/messages","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"model":{"type":"string","description":"Model id from GET /v1/metered/models, e.g. glm-5.3. No provider prefix."},"stream":{"type":"boolean","description":"SSE streaming."},"messages":{"type":"array","items":{"type":"object","required":["role","content"],"properties":{"role":{"enum":["system","user","assistant","tool"],"type":"string"},"content":{"type":"string"}}},"description":"Chat messages, [OI]-compatible {role, content}."},"max_tokens":{"type":"integer","description":"Output token budget. Drives the quote directly."}}},"responseSchema":{"type":"json","example":{"usage":{"prompt_tokens":6,"completion_tokens":8},"choices":[{"message":{"role":"assistant","content":"Hello! How can I help?"},"finish_reason":"stop"}]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_3xG5Fnx1yh-FZkJZn2aVx","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Runs a chat completion request against frontier LLMs (GLM, GPT, Gemini, Kimi, DeepSeek, MiniMax) billed per-call in USDC via x402 micropayment — no API key or account required.","exampleAgentPrompt":"Using FarOut's pay-per-call router, send the message 'Summarize the history of the Roman Empire in 3 sentences' to the glm-5.3 model with a max_tokens budget of 200, and pay per call in USDC — no API key needed.","exampleUseCases":[{"title":"Crypto-native agent calling frontier LLMs","prompt":"I'm building an AI agent that needs to call GPT or Gemini on-demand without holding API keys — can you send 'What are the top 3 use cases for zero-knowledge proofs?' to glm-5.3 with max 300 tokens and pay per call using USDC on Base?"},{"title":"Comparing responses across frontier models","prompt":"Ask DeepSeek via FarOut's pay-per-call router: 'Explain transformer attention in one paragraph' — use max_tokens 150 and pay the per-request USDC fee so I can compare it against another model's answer."},{"title":"Serverless LLM inference for a no-account pipeline","prompt":"My pipeline has no standing LLM subscriptions — use FarOut to send the system prompt 'You are a concise summarizer' and user message 'Summarize: [article text]' to kimi with max_tokens 250, billing each call individually in USDC."}],"resultDescription":"Returns an OpenAI-compatible JSON object with a choices array containing the assistant's reply message and finish_reason, plus a usage object reporting prompt_tokens and completion_tokens consumed.","failureModes":["402 Payment Required if the x402 payment header is missing or insufficient — the server quotes the exact price and the call is not charged","Invalid model ID returns an error — must use an ID from GET /v1/metered/models","max_tokens too large may be rejected or result in truncation depending on model limits","Streaming (SSE) connection drops may result in partial completions","Network timeout on slow models; caller must implement retry logic"],"whenToPreferThis":"Prefer this endpoint when you need on-demand LLM inference without pre-registering an API key or account, when you want to pay strictly per successful call in USDC stablecoins via x402, or when your agent needs to switch between frontier models (GLM, GPT, Gemini, Kimi, DeepSeek, MiniMax) without holding separate provider credentials. It is especially suited for crypto-native or agentic workflows where failed calls must never incur charges.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T18:34:49.622Z","isFirstParty":false}