Back to Models

GPT-5 Nano

openaiopenai/gpt-5-nano

API guide

Chat completion

GPT-5 Nano is called via the standard chat completions endpoint through TheRouter, exactly like any OpenAI-compatible model. All GPT-5 parameters are supported.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-5-nano",
    "messages": [
      {"role": "user", "content": "Classify this text as positive, negative, or neutral: \"The service was okay but nothing special.\""}
    ],
    "reasoning_effort": "minimal",
    "response_format": { "type": "json_object" }
  }'

Streaming

GPT-5 Nano supports streaming for real-time token-by-token output. Combined with minimal reasoning effort, this gives near-instant start-of-response for classification and summary tasks.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Accept: text/event-stream" \
  -d '{
    "model": "openai/gpt-5-nano",
    "messages": [
      {"role": "user", "content": "Summarize this article in three bullet points: <article text>"}
    ],
    "reasoning_effort": "low",
    "stream": true
  }'

Reasoning effort

GPT-5 Nano supports the full reasoning_effort spectrum: minimal for instant classification, low for balanced extraction tasks, medium as the default, and high for deeper analysis on longer inputs.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-5-nano",
    "messages": [
      {"role": "user", "content": "Extract all entities, dates, and monetary values from this invoice."}
    ],
    "reasoning_effort": "low",
    "response_format": { "type": "json_object" }
  }'

Tool calling

GPT-5 Nano supports parallel tool calls and custom_tools with grammar constraints at the lowest GPT-5 tier pricing.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-5-nano",
    "messages": [{"role": "user", "content": "What's the weather in Tokyo and what's the current time?"}],
    "tools": [{
      "type": "function",
      "function": {
        "name": "get_weather",
        "description": "Get current weather for a city",
        "parameters": {
          "type": "object",
          "properties": {
            "location": {"type": "string", "description": "City name"}
          },
          "required": ["location"]
        }
      }
    }],
    "parallel_tool_calls": true
  }'
Fact ledger β€” every claim on this page traces here
sourceURLretrieved
Release dateopenai.com β†—2026-05-29verified
Knowledge cutoffopenrouter.ai β†—2026-05-29to verify
OpenAI model idplatform.openai.com β†—2026-05-29to verify
Licenseβ€”β€”verified
SWE-bench Verifiedopenai.com β†—2026-05-29to verify
AIME 2025openai.com β†—2026-05-29to verify
MMMU (Multimodal)openai.com β†—2026-05-29to verify
GPT-5 family launch β€” GPT-5, Mini, and Nanoopenai.com β†—2026-05-29verified
How does GPT-5 Nano compare to GPT-5 Mini?openai.com β†—2026-05-29to verify
Does GPT-5 Nano support vision?platform.openai.com β†—2026-05-29to verify
Is GPT-5 Nano still available after GPT-5.4 Nano was released?platform.openai.com β†—2026-05-29to verify
What are the cache-read pricing benefits?platform.openai.com β†—2026-05-29to verify
Help & contact