Back to Models

GPT OSS 120B

openaiopenai/gpt-oss-120b

API guide

Chat completion

Use standard OpenAI-compatible chat completion via TheRouter. The model uses the harmony chat format; TheRouter handles the conversion automatically.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-oss-120b",
    "messages": [
      {"role": "user", "content": "Explain the benefits of Mixture-of-Experts architecture in large language models."}
    ]
  }'

Reasoning mode

Set reasoning effort via system message. Use 'Reasoning: low', 'Reasoning: medium', or 'Reasoning: high' to control CoT length and accuracy.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-oss-120b",
    "messages": [
      {"role": "system", "content": "Reasoning: high"},
      {"role": "user", "content": "Prove that sqrt(2) is irrational."}
    ]
  }'

Tool/function calling

Full support for OpenAI-compatible tool and function calling. Define functions in the standard OpenAI schema.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-oss-120b",
    "messages": [{"role": "user", "content": "What is the weather in Tokyo?"}],
    "tools": [{
      "type": "function",
      "function": {
        "name": "get_weather",
        "description": "Get current weather",
        "parameters": {
          "type": "object",
          "properties": {"location": {"type": "string"}},
          "required": ["location"]
        }
      }
    }],
    "tool_choice": "auto"
  }'

Structured Outputs

GPT OSS 120B supports OpenAI Structured Outputs for guaranteed JSON responses matching a schema.

cURL
curl https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "openai/gpt-oss-120b",
    "messages": [{"role": "user", "content": "List 3 machine learning frameworks."}],
    "response_format": {
      "type": "json_schema",
      "json_schema": {
        "name": "framework_list",
        "schema": {
          "type": "object",
          "properties": {
            "frameworks": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "name": {"type": "string"},
                  "creator": {"type": "string"}
                },
                "required": ["name", "creator"]
              }
            }
          },
          "required": ["frameworks"]
        }
      }
    }
  }'
Fact ledger β€” every claim on this page traces here
sourceURLretrieved
Release dateopenai.com β†—2026-05-29verified
Architecturearxiv.org β†—2026-05-29verified
Licenseopenai.com β†—2026-05-29verified
Knowledge cutoffarxiv.org β†—2026-05-29verified
Tokenizerarxiv.org β†—2026-05-29verified
Quantizationarxiv.org β†—2026-05-29verified
Checkpoint sizearxiv.org β†—2026-05-29verified
Training computearxiv.org β†—2026-05-29verified
Reasoning modesopenai.com β†—2026-05-29verified
MMLUarxiv.org β†—2026-05-29verified
AIME 2024arxiv.org β†—2026-05-29verified
AIME 2025arxiv.org β†—2026-05-29verified
Codeforces Eloopenai.com β†—2026-05-29to verify
SWE-Bench Verifiedarxiv.org β†—2026-05-29verified
GPQA Diamondarxiv.org β†—2026-05-29verified
HLEarxiv.org β†—2026-05-29verified
HealthBencharxiv.org β†—2026-05-29verified
HealthBench Hardarxiv.org β†—2026-05-29verified
Tau-Bench Retailarxiv.org β†—2026-05-29verified
MMMLU (Average)arxiv.org β†—2026-05-29verified
Can I use GPT OSS 120B through TheRouter's API without self-hosting?openai.com β†—2026-05-29to verify
What license does GPT OSS 120B use?openai.com β†—2026-05-29to verify
How does GPT OSS 120B compare to GPT-4o?arxiv.org β†—2026-05-29to verify
What hardware do I need to self-host GPT OSS 120B?github.com β†—2026-05-29to verify
Help & contact