{"uid":"cap_pkDIyNRy75iI1AXpcIX12","slug":"bittensor-decentralized-ai-chat-completions-69a03333","name":"Bittensor Decentralized AI Chat Completions","description":"Chat completions via Bittensor decentralized AI. Fully OpenAI-compatible. 43+ models (DeepSeek, Qwen, Llama, Mistral). Streaming, function calling, TEE-verified. Drop-in: just change base_url.","url":"https://gateway.spraay.app/bittensor/v1/chat/completions?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"model":{"type":"string"},"tools":{"type":"array"},"stream":{"type":"boolean"},"messages":{"type":"array"},"max_tokens":{"type":"number"},"temperature":{"type":"number"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.03","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.03/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.03","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_qIV0H9Zig3MiCHg0F3xlP","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.03","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Send chat messages to 43+ AI models (DeepSeek, Qwen, Llama, Mistral) via Bittensor's decentralized network with full OpenAI-compatible API support including streaming and function calling","exampleAgentPrompt":"Using the Bittensor decentralized AI gateway, send this conversation to the DeepSeek-R1 model with temperature 0.7 and a max of 1024 tokens: the system message says 'You are a helpful assistant' and the user asks 'Explain quantum entanglement in simple terms.'","exampleUseCases":[{"title":"Privacy-first coding assistant","prompt":"Use the Bittensor gateway to send my coding question to the Llama-3 model — keep temperature at 0.2 and max tokens at 2048. My message is: 'Write a Python function that parses a JSON file and returns a list of unique email addresses.'"},{"title":"Autonomous agent tool-use pipeline","prompt":"I need you to call the Bittensor decentralized AI endpoint with the Qwen-72B model, enable function calling with my 'search_web' tool definition, and send this message: 'What is the current weather in Tokyo?' Stream the response back as it comes in."},{"title":"Multi-turn customer support drafting","prompt":"Route this support conversation through the Bittensor AI gateway using Mistral-Large, temperature 0.5, max 512 tokens. System prompt: 'You are a polite customer support agent.' User message: 'My order hasn't arrived after 2 weeks, what do I do?'"}],"resultDescription":"Returns an OpenAI-compatible chat completion object containing the assistant's response message, finish reason, token usage stats, and optionally streamed chunks or function call arguments depending on the request configuration.","failureModes":["Invalid or unsupported model name returns an error","Insufficient USDC payment (x402) causes 402 Payment Required response","Malformed messages array or missing required fields returns 400 Bad Request","Network or Bittensor node unavailability causes timeouts or 503 errors","Token limit exceeded causes truncated or error responses","Invalid tool/function schema causes function calling to fail"],"whenToPreferThis":"Choose this endpoint when you want OpenAI-compatible chat completions backed by Bittensor's decentralized compute network — ideal for agents that need TEE-verified inference, want to avoid centralized AI providers, need access to models like DeepSeek, Qwen, Llama, or Mistral via a drop-in OpenAI replacement, or are operating in a pay-per-call (x402) micropayment context without subscription overhead.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T04:57:10.285Z","isFirstParty":false,"canonicalSlug":"bittensor-decentralized-ai-chat-completions-69a03333"}