OpenAI
GPT-5.4
OpenAI's 2026 flagship model with 400K context and cached-input pricing for reasoning, coding, and multimodal tasks
Context Length400K tokens
Model TypeLarge Language Model (LLM)
MultimodalSupports text and image input, text output
Pricing & Specs
💰 Pricing
Input$2.5 / M tokens
Output$15 / M tokens
Cache Hit$0.25 / M tokens
⚙️ Specs
Context Length400K tokens
Model TypeLarge Language Model (LLM)
MultimodalSupports text and image input, text output
Caching SupportSupports cached-input pricing
Snapshotgpt-5.4-2026-02-20
Knowledge CutoffJune 2024
API Examples
Python
from openai import OpenAI
client = OpenAI(
base_url="https://api.xairouter.com/v1",
api_key="your-api-key"
)
response = client.chat.completions.create(
model="gpt-5.4",
messages=[
{"role": "user", "content": "Hello!"}
]
)
print(response.choices[0].message.content)cURL
curl https://api.xairouter.com/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "gpt-5.4",
"messages": [
{"role": "user", "content": "Hello!"}
]
}'