GPT 5.2 Codex

Model details

GPT 5.2 Codex

Model
openai/gpt-5.2-codex
Provider
vercel-ai-gateway
API
anthropic-messages
Base URL
https://ai-gateway.vercel.sh
Input
text, image
Reasoning
Yes
Context window
400,000
Max tokens
128,000
Cost / million input
$1.75
Cost / million output
$14
Cost / million cache read
$0.175
Cost / million cache write
$0
Model config JSON
{
  "providers": {
    "vercel-ai-gateway": {
      "apiKey": "YOUR_API_KEY",
      "models": [
        {
          "id": "openai/gpt-5.2-codex",
          "name": "GPT 5.2 Codex",
          "reasoning": true,
          "input": [
            "text",
            "image"
          ],
          "contextWindow": 400000,
          "maxTokens": 128000,
          "cost": {
            "input": 1.75,
            "output": 14,
            "cacheRead": 0.175,
            "cacheWrite": 0
          }
        }
      ],
      "api": "anthropic-messages",
      "baseUrl": "https://ai-gateway.vercel.sh"
    }
  }
}