gpt-5.2-codex

by OpenAI

GPT-5.2-Codex is an upgraded version of GPT-5.2, optimized for agentic coding tasks in Codex and similar execution environments. The model is specifically enhanced for code generation, modification, refactoring, and automated execution workflows, enabling more efficient participation in multi-step, tool-driven programming processes. GPT-5.2-Codex supports low, medium, high, and xhigh reasoning effort settings, allowing flexible trade-offs between latency, reasoning depth, and token usage depending on task complexity.

API Pricing

Input$1.75 / 1M tokens
Output$14 / 1M tokens
Cache read$0.18 / 1M tokens

Specifications

Context window400,000 tokens
Modalitiestext, image
Featuresthinking, function_calling, structured_outputs

More from OpenAI

Use gpt-5.2-codex via the AIHubMix unified API — one interface for every major LLM.