v1

latestOpenAPI 3.1.0MIT2026-07-262861121.0 KB

Create a response with the OpenAI-compatible Responses API. The NanoGPT Advisor extension is available for non-streaming, foreground, platform-billed pay-as-you-go API-key requests that do not use client tools, structured output, inline moderation, BYOK, accountless payment, memory, or server-side content enhancements.

post/v1/responses

Headers

X-Providerstring

Optional explicit provider override for supported open-source models (case-insensitive). Explicit provider selection is billed pay-as-you-go at the selected provider's price, including provider-selection markup; for subscription users it bypasses subscription coverage for that request.

X-Billing-Modestring

Optional billing override to force pay-as-you-go without an explicit provider, or to apply saved provider preferences to subscription-included traffic (e.g., paygo). Header name is case-insensitive.

X-Team-Idstring

Optional team context override for API-key requests. If provided, it must reference a team the caller belongs to.

x-x402'true'

Set to true on unauthenticated accountless x402 quote requests. Without this header, unauthenticated requests return 401 missing_api_key.

Request body

modelstring required

Model ID to use for the response. Provider-selection-capable models may include routing preference suffixes such as ':fast', ':speed', ':cheap', ':price', ':latency', ':throughput', ':floor', ':tools', ':caching', ':cache', or ':cached'.

billing_modestring

Billing override to force pay-as-you-go without an explicit provider, or to apply saved provider preferences to subscription-included traffic. Accepted values (case-insensitive): paygo, pay-as-you-go, pay_as_you_go, paid, payg.

billingModestring

Alias for billing_mode.

instructionsstring

System instructions for the model

max_output_tokensinteger

Maximum tokens in the response

temperaturenumber

Sampling temperature (not supported by reasoning models)

top_pnumber

Nucleus sampling parameter

toolsobject[]

Function tools available to the model

parallel_tool_callsboolean

Allow multiple tool calls in parallel

streamboolean

Enable streaming responses

storeboolean

Store the response locally for later retrieval/threading/background processing. Set false to disable stored Responses API data for the request.

retention_daysinteger nullable

Per-request retention override in days (0..365). Use 0 to disable retention for the request; use null to fall back to configured defaults.

retentionDaysinteger nullable

Alias for retention_days (0..365). If both are provided, values must match.

previous_response_idstring

Link to previous response for conversation threading

reasoningobject

Reasoning configuration. Setting reasoning.effort to any non-none value explicitly requests reasoning mode.

textobject

Text/format configuration

metadataobject

Custom metadata

truncation'auto' | 'disabled'

Truncation strategy

userstring

Unique user identifier

seedinteger

Optional integer forwarded on model/provider routes that support seeded sampling. This may improve reproducibility but does not guarantee identical output. Results can change if NanoGPT selects a different automatic or fallback route, or if the provider changes its backend.

backgroundboolean

Enable background/async processing

service_tier'auto' | 'default' | 'flex' | 'priority'

Optional service tier: "auto", "default", "flex", or "priority". Use "flex" for lower-cost variable-capacity processing or "priority" for higher-cost priority processing where supported by the routed model/provider.

Response

Response created

idstring
objectstring
created_atinteger
modelstring
status'queued' | 'in_progress' | 'completed' | 'incomplete' | 'failed' | 'cancelled'
outputobject[]
output_textstring
usageobject
errorobject
incomplete_detailsobject
metadataobject
service_tierstring