{"uid":"cap_oJvYvpnvGLDGYsBH64Gcs","slug":"www-surplusintelligence-ai-c55a5ffe","name":"Surplus Intelligence OpenAI-Compatible Completions","description":"Buy the cheapest inference. Sell your credits. The open order book for AI models. Up to 90% off GPT-5.5, Claude Opus 4.8, and more.","url":"https://www.surplusintelligence.ai/x402/api/inference/v1/completions","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"model":{"type":"string","description":"Surplus Intelligence model id. Call /x402/api/inference/v1/models for available models."},"prompt":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"OpenAI-compatible legacy completion prompt."},"stream":{"type":"boolean"},"max_tokens":{"type":"integer","minimum":1,"description":"Maximum output tokens."},"temperature":{"type":"number","maximum":2,"minimum":0}}},"responseSchema":{"type":"json","example":{"id":"cmpl_surplus_example","usage":{"total_tokens":14,"prompt_tokens":8,"completion_tokens":6},"object":"text_completion","choices":[{"text":"Hello from Surplus Intelligence.","index":0,"finish_reason":"stop"}]}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.003302","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.003302/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003302","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003302","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_iraPkHGA3cmtA-tYwAIoT","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.003302","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Runs text completion inference against a variety of AI models via Surplus Intelligence's OpenAI-compatible legacy completions endpoint, billed per call in USDC.","exampleAgentPrompt":"Using Surplus Intelligence's completions endpoint, run a text completion with the model 'gpt-3.5-turbo-instruct', prompt 'Once upon a time in a futuristic city', max 200 tokens, and temperature 0.7.","exampleUseCases":[{"title":"Compare outputs across multiple models","prompt":"I want to test how different models handle the same creative writing prompt. Use Surplus Intelligence's completions endpoint to run 'The scientist opened the ancient vault and discovered' through three different models back to back, 150 tokens each, temperature 0.8, so I can compare the outputs."},{"title":"Budget-friendly bulk text generation","prompt":"I need to generate product description drafts for 50 items without paying for a subscription. Use Surplus Intelligence's completions endpoint with a cost-efficient model, max 100 tokens per call, temperature 0.5, starting with the prompt 'This premium handcrafted leather wallet features'."},{"title":"Low-cost code completion inference","prompt":"Can you use Surplus Intelligence's completions endpoint to finish this Python function stub — 'def calculate_compound_interest(principal, rate, years):' — using a capable model, up to 300 tokens, and a low temperature of 0.2 to keep the output deterministic?"}],"resultDescription":"Returns an OpenAI-compatible completions response containing the generated text continuation(s) for the given prompt, using the specified model and sampling parameters.","failureModes":["Invalid or unavailable model ID returns an error — call /x402/api/inference/v1/models to list valid models","Insufficient USDC payment results in 402 Payment Required","Prompt exceeds model context window returns a token limit error","Temperature out of range (0–2) causes a validation error","Missing required 'model' or 'prompt' fields returns a 400 Bad Request"],"whenToPreferThis":"Choose this endpoint when you need OpenAI-compatible legacy text completions (not chat completions), want per-call USDC micropayment billing without a subscription, or need to access a variety of models through a single compatible interface at market prices.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T06:33:45.419Z","isFirstParty":false}