{"uid":"cap_LnlVLgi18e0ScJOqnZKIy","slug":"model-access-gateway-gemini-2-0-flash-via-x402-81771b96","name":"Model Access Gateway – Gemini 2.0 Flash via x402","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://agent402-arb.rosariovitale0096.workers.dev/llm/gemini-3.8-flash?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"model":{"type":"string","description":"Optional: fixed by the route (google/gemini-3.8-flash)"},"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":"google/gemini-3.8-flash","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_39PA6sENiXPT3ugjqCEzM","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":"Provides OpenAI-compatible chat completions using Google's Gemini 2.0 Flash model, billed per request in USDC on Base via x402 with no account or API key required.","exampleAgentPrompt":"Send this conversation to Gemini 2.0 Flash and get back a reply: system prompt is 'You are a helpful assistant', user message is 'Summarize the key benefits of renewable energy in three bullet points.' Pay the per-request USDC fee automatically via x402.","exampleUseCases":[{"title":"Keyless AI inference for autonomous agent","prompt":"My agent needs to call Gemini Flash to draft a short product description for a new coffee grinder without me setting up any API keys — just pay the fraction-of-a-cent fee in USDC each time and return the response."},{"title":"Crypto-native chatbot backend","prompt":"Route this user message through Gemini 2.0 Flash using the OpenAI chat format and charge the session wallet in USDC on Base — the user said: 'What are the top 5 programming languages to learn in 2025?'"},{"title":"Cost-controlled LLM for research summarization","prompt":"Use Gemini Flash to summarize the following abstract into two sentences, paying per request so I only spend what I use: 'Large language models have demonstrated remarkable capabilities across a variety of natural language tasks...'"}],"resultDescription":"A JSON object in OpenAI chat.completion format containing the assistant's reply message, finish reason (e.g. 'stop'), token usage breakdown (prompt, completion, total tokens), model identifier ('google/gemini-3.8-flash'), and a unique completion ID.","failureModes":["Payment not included or insufficient USDC balance — HTTP 402 Payment Required returned","Malformed request body (missing 'messages' field or wrong content type) — HTTP 400 Bad Request","Model temporarily unavailable upstream — HTTP 503 or gateway timeout","Rate limiting on the Cloudflare Worker — HTTP 429 Too Many Requests","Invalid x402 payment header — payment rejected, request not processed"],"whenToPreferThis":"Choose this endpoint when you need OpenAI-compatible chat completions from Gemini 2.0 Flash without creating an account or managing API keys, and when your agent can pay per request in USDC on Base via the x402 protocol. Ideal for autonomous agents with crypto wallets that need low-cost, pay-as-you-go LLM access at $0.0014 per call.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-15T12:34:34.518Z","isFirstParty":false,"canonicalSlug":"model-access-gateway-gemini-2-0-flash-via-x402-81771b96"}