{"uid":"cap_hqPNcsawFFSVgKdQ2d51k","slug":"telnyx-x402-gateway-llama-3-1-70b-chat-completions-a5d49c6b","name":"Telnyx x402 Gateway – Llama 3.1 70B Chat Completions","description":"Pay USDC per request for Telnyx Inference and Audio (text-to-speech, speech-to-text) through x402.","url":"https://x402.telnyx.com/v1/chat/completions/_t/llama-3.1-70b?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"n":{"type":"integer","const":1,"description":"Fixed to one completion per paid call."},"model":{"type":"string","const":"meta-llama/Meta-Llama-3.1-70B-Instruct","description":"Model identifier; fixed to meta-llama/Meta-Llama-3.1-70B-Instruct on this route."},"tools":{"type":"array","items":{"type":"object"},"maxItems":16},"messages":{"type":"array","items":{"type":"object","required":["role","content"],"properties":{"role":{"enum":["system","user","assistant","tool"],"type":"string"},"content":{"type":"string","maxLength":8000}}},"maxItems":32,"description":"OpenAI-style chat messages."},"max_tokens":{"type":"integer","maximum":1024,"minimum":1},"temperature":{"type":"number","maximum":2,"minimum":0}}},"responseSchema":{"type":"json","example":{"id":"chatcmpl-xxx","usage":{"total_tokens":16,"prompt_tokens":12,"completion_tokens":4},"object":"chat.completion","choices":[{"index":0,"message":{"role":"assistant","content":"Hello!"},"finish_reason":"stop"}]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.007016","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.007016/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.007016","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.007016","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_umgqnzlb3el7E2I7cLnnH","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.007016","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Send an OpenAI-compatible chat completion request to Meta Llama 3.1 70B Instruct, paid per-call in USDC via the x402 protocol on Telnyx infrastructure.","exampleAgentPrompt":"Ask Llama 3.1 70B via Telnyx to explain the difference between supervised and unsupervised learning in three sentences, keeping the response under 200 tokens and temperature at 0.7, and pay for it per-call with USDC.","exampleUseCases":[{"title":"Pay-per-call agent reasoning step","prompt":"Use the Telnyx Llama 3.1 70B endpoint to reason through this customer support ticket and draft a reply — I want to pay per call in USDC rather than maintain a subscription, keep max tokens at 512 and temperature at 0.3."},{"title":"Agentic tool-use with crypto billing","prompt":"Send a chat completion request to Telnyx's Llama 70B with the following tool definitions for a web search function, include the system prompt 'You are a helpful research assistant', and bill via USDC per request through x402."},{"title":"One-off LLM task without API subscription","prompt":"I just need a single Llama 3.1 70B completion for a one-off content summarization task — use the Telnyx x402 gateway so I pay in USDC only for this one call, with temperature 0 and max tokens 300."}],"resultDescription":"Returns an OpenAI-compatible chat.completion JSON object containing the assistant's generated message, finish reason (e.g. 'stop'), token usage breakdown (prompt, completion, total), a unique completion ID, and the object type field.","failureModes":["Insufficient USDC balance or failed x402 payment results in 402 Payment Required","Exceeding max_tokens limit (>1024) or message count (>32) triggers 422 validation error","Content exceeding 8000 characters per message causes request rejection","Invalid or missing required 'messages' array returns a 400 Bad Request","Model overload or Telnyx infrastructure issues may cause 503 or timeout responses"],"whenToPreferThis":"Choose this endpoint when you need OpenAI-compatible Llama 3.1 70B inference with pay-per-call USDC billing via x402, avoiding monthly subscriptions or API key management. It is ideal for agents or pipelines that require metered, on-chain-accountable LLM calls, especially when integrating with Coinbase-ecosystem or x402-aware infrastructure. Prefer it over standard Telnyx API auth flows when you want trustless per-request micropayments rather than pre-paid credits.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-10T06:40:57.578Z","isFirstParty":false,"canonicalSlug":"telnyx-x402-gateway-llama-3-1-70b-chat-completions-a5d49c6b"}