GPT-5 Mini
API guide
Chat completion
GPT-5 Mini is called via the standard chat completions endpoint through TheRouter, exactly like any OpenAI-compatible model. All GPT-5 parameters are supported: reasoning_effort, verbosity, response_format, tools, and stop sequences.
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-5-mini",
"messages": [
{"role": "user", "content": "Classify the sentiment of this customer review as positive, negative, or neutral: \"The product arrived on time but the packaging was damaged.\""}
],
"reasoning_effort": "low",
"response_format": { "type": "json_object" }
}'Streaming
GPT-5 Mini supports streaming for real-time token-by-token output. Combined with low reasoning effort, this gives near-instant start-of-response for classification and summary tasks.
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-mini",
"messages": [
{"role": "user", "content": "Summarize this article in three bullet points: <article text>"}
],
"reasoning_effort": "low",
"stream": true
}'Reasoning effort
GPT-5 Mini supports the full reasoning_effort spectrum: minimal for fast answers on simple tasks, low for balanced quality/speed on structured work, medium as the default, and high for deeper reasoning. The minimal setting eliminates chain-of-thought entirely for near-instant classification.
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-5-mini",
"messages": [
{"role": "user", "content": "Extract all email addresses, phone numbers, and dates from this text block."}
],
"reasoning_effort": "minimal",
"response_format": { "type": "json_object" }
}'Tool calling
GPT-5 Mini supports parallel tool calls and the new custom_tools type with grammar-constrained plaintext. Ideal for tool orchestration agents that need low latency but can trade some reasoning depth.
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-5-mini",
"messages": [
{"role": "user", "content": "Look up weather for Shanghai and Tokyo, then compare"}
],
"tools": [{
"type": "function",
"function": {
"name": "get_weather",
"description": "Get current weather for a city",
"parameters": {
"type": "object",
"properties": { "city": { "type": "string" }, "country": { "type": "string" } }
}
}
}],
"tool_choice": "auto",
"parallel_tool_calls": true
}'Vision
GPT-5 Mini accepts image inputs (JPEG, PNG, GIF, WebP) alongside text prompts. The model can read charts, diagrams, screenshots, and photographs β outputting structured text or JSON. Ideal for document processing pipelines where cost per page matters.
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-5-mini",
"messages": [
{
"role": "user",
"content": [
{"type": "text", "text": "Extract the table from this screenshot as JSON"},
{"type": "image_url", "image_url": {"url": "https://therouter.ai/assets/vision-sample.png"}}
]
}
],
"response_format": { "type": "json_object" }
}'Fact ledger β every claim on this page traces here
| source | URL | retrieved | |
|---|---|---|---|
| Release date | openai.com β | 2026-05-28 | verified |
| Knowledge cutoff | artificialanalysis.ai β | 2026-05-28 | to verify |
| OpenAI model id | platform.openai.com β | 2026-05-28 | verified |
| License | β | β | verified |
| SWE-bench Verified | reddit.com / SWE-bench team AMA β | 2026-05-28 | to verify |
| AIME 2025 | openai.com β | 2026-05-28 | to verify |
| MMMU (Multimodal) | openai.com β | 2026-05-28 | to verify |
| OpenAI launches GPT-5 family: GPT-5, GPT-5 Mini, GPT-5 Nano | openai.com β | 2026-05-28 | verified |
| How does GPT-5 Mini differ from GPT-5? | artificialanalysis.ai β | 2026-05-28 | to verify |