{"uid":"cap_dIiFUNL1sJH67fYr2JYNV","slug":"model-access-gateway-pay-per-call-llm-chat-completions-x402-usdc-b1c6696a","name":"Model Access Gateway – Pay-Per-Call LLM Chat Completions (x402/USDC)","description":"LLM inference API: OpenAI-compatible chat completions for 136 AI models (Claude, GPT, Gemini, Grok, DeepSeek, Qwen, Kimi, GLM), paid per call in USDC on Base with x402. No account, no API key, automatic refund if the model fails.","url":"https://modelaccessgateway.com/v1/chat/completions?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"model":{"type":"string","examples":["anthropic/claude-fable-5","anthropic/claude-fable-5.1","anthropic/claude-haiku-4.5","anthropic/claude-haiku-5.5","anthropic/claude-opus-4.5","anthropic/claude-opus-4.6","anthropic/claude-opus-4.7","anthropic/claude-opus-4.8","anthropic/claude-opus-4.8-fast","anthropic/claude-opus-5","anthropic/claude-opus-5-fast","anthropic/claude-opus-5.5","anthropic/claude-opus-5.5-fast","anthropic/claude-sonnet-4.5","anthropic/claude-sonnet-4.6","anthropic/claude-sonnet-5","anthropic/claude-sonnet-5.5","deepseek/deepseek-chat","deepseek/deepseek-reasoner","deepseek/deepseek-v3.2","deepseek/deepseek-v4-flash-0731","deepseek/deepseek-v4-flash-0731-fast","deepseek/deepseek-v4-flash-vision-exp","deepseek/deepseek-v4-pro","deepseek/deepseek-v4-pro-0813","deepseek/deepseek-v4.1-flash","google/gemini-2.5-flash","google/gemini-2.5-flash-lite","google/gemini-2.5-pro","google/gemini-3-flash-preview","google/gemini-3.1-flash-lite","openai/gpt-4.1","openai/gpt-4.1-mini","openai/gpt-4.1-nano","openai/gpt-4o","openai/gpt-4o-mini","openai/gpt-5-mini","openai/gpt-5.1","openai/gpt-5.2","openai/gpt-5.2-pro","openai/gpt-5.3-codex","openai/gpt-5.4","openai/gpt-5.4-mini","openai/gpt-5.4-nano","openai/gpt-5.4-pro","openai/gpt-5.5","openai/gpt-5.5-pro","openai/gpt-5.6-luna","openai/gpt-5.6-luna-pro","openai/gpt-5.6-sol","openai/gpt-5.6-sol-pro","openai/gpt-5.6-terra","openai/gpt-5.6-terra-pro","openai/gpt-6-astra","openai/gpt-6-astra-pro","openai/gpt-6-luna","openai/gpt-6-sol","openai/gpt-6.1-sol","openai/gpt-6.1-sol-ultrafast","openai/gpt-oss-120b"],"description":"Choose any current model; GET /v1/models for the live catalog."},"tools":{"type":"array"},"stream":{"type":"boolean","description":"true: server-sent events after payment"},"messages":{"type":"array","items":{"type":"object","required":["role"],"properties":{"role":{"enum":["system","user","assistant","tool","developer"],"type":"string"},"content":{"type":["string","array","null"]}}},"minItems":1},"max_tokens":{"type":"integer","maximum":16384,"minimum":1,"description":"Optional, default 4096"},"temperature":{"type":"number","maximum":2,"minimum":0},"response_format":{"type":"object"}}},"responseSchema":{"type":"json","example":{"id":"chatcmpl-7f3c2a91","model":"deepseek/deepseek-chat","usage":{"total_tokens":10,"prompt_tokens":9,"completion_tokens":1},"object":"chat.completion","choices":[{"index":0,"message":{"role":"assistant","content":"OK"},"finish_reason":"stop"}],"created":1791979200}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0014","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.0014/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0014","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0014","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_DCOXyQwV9K11xiTdl0xo7","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0014","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"OpenAI-compatible chat completions API supporting 136 AI models (Claude, GPT, Gemini, DeepSeek, Grok, etc.), paid per call in USDC on Base via x402 with no account or API key required.","exampleAgentPrompt":"Using the Model Access Gateway, send a chat completion request to DeepSeek deepseek-chat asking it to summarize the following text in three bullet points, and pay per call in USDC with no API key needed: 'Blockchain technology enables decentralized trust...'","exampleUseCases":[{"title":"Autonomous agent self-funding LLM calls","prompt":"I'm building an AI agent that needs to call Claude Sonnet to answer customer questions — it should pay for each inference itself in USDC without me setting up any API keys or subscription. Use the Model Access Gateway with anthropic/claude-sonnet-5 and the message: 'What is the refund policy for digital goods?'"},{"title":"Multi-model comparison without accounts","prompt":"Can you run the same prompt through both google/gemini-2.5-flash and openai/gpt-4o using the Model Access Gateway and show me both responses? The prompt is: 'Explain quantum entanglement in one paragraph for a 12-year-old.' Just pay per call — I don't want to manage separate API keys."},{"title":"Streaming reasoning with DeepSeek","prompt":"Use Model Access Gateway to send a streaming chat completion to deepseek/deepseek-reasoner with the system prompt 'You are a math tutor' and user message 'Solve this step by step: integrate x^2 * sin(x) dx' — I want the response streamed back as it arrives, paying in USDC."}],"resultDescription":"Returns an OpenAI-format chat completion JSON object containing the assistant's message content, model name, usage statistics (prompt tokens, completion tokens, total tokens), finish reason, and a unique completion ID. Supports streaming via server-sent events when stream=true. An automatic USDC refund is issued if the model fails to respond.","failureModes":["Payment insufficient or x402 transaction fails — request rejected before inference","Model identifier not found — returns error; use GET /v1/models for live catalog","Model provider upstream outage — automatic refund issued to caller","Streaming connection dropped mid-response — partial content delivered","Malformed messages array — validation error returned","Rate limiting by upstream provider — transient failure, may retry"],"whenToPreferThis":"Choose this endpoint when you need anonymous, accountless LLM inference across a wide range of frontier models and want to pay per call in USDC rather than managing API keys or subscriptions. Ideal for autonomous AI agents that self-fund their own inference costs, for prototyping across multiple model families without multi-provider onboarding, or for use cases where crypto-native micropayments (x402/Base) are preferred over traditional billing. Prefer over direct provider APIs when you want a single OpenAI-compatible interface covering Claude, GPT, Gemini, DeepSeek, and others simultaneously.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-18T06:35:13.974Z","isFirstParty":false,"canonicalSlug":"model-access-gateway-pay-per-call-llm-chat-completions-x402-usdc-b1c6696a"}