GPT-5.2-Codex
Approved Data Classifications
Description
GPT-5.2-Codex is OpenAI's most intelligent coding model, optimized for long-horizon, agentic coding tasks. It is an upgraded version of GPT-5.2 for agentic coding tasks in Codex or similar environments, supports reasoning.effort levels (low, medium, high, and xhigh), and accepts text and image input with text output. The model provides a 400,000-token context window with up to 128,000 output tokens and an Aug 31, 2025 knowledge cutoff. Pricing matches GPT-5.2: $1.75 per 1M input tokens, $14 per 1M output tokens, and $0.175 per 1M cached input tokens.
Capabilities
| Model | Training Data | Input | Output | Context Length | Cost (per 1 million tokens) |
|---|---|---|---|---|---|
| gpt-5.2-codex | Aug 31 2025 | Image, Text | Text | 400,000 (in) / 128,000 (out) | $1.75/1M input $14.00/1M output |
info
1Mrepresents 1 Million Tokens- All prices listed are based on 1 Million Tokens
- Cached input: $0.175 per 1M tokens
Availability
Cloud Provider
Usage
- curl
- python
- javascript
curl -X POST https://api.ai.it.ufl.edu/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API_TOKEN>" \
-d '{
"model": "gpt-5.2-codex",
"messages": [
{
"role": "system",
"content": "You are a helpful assistant."
},
{
"role": "user",
"content": "Write a haiku about an Alligator."
}
]
}'
from openai import OpenAI
client = OpenAI(
api_key="your_api_key",
base_url="https://api.ai.it.ufl.edu/v1"
)
response = client.chat.completions.create(
model="gpt-5.2-codex", # model to send to the proxy
messages = [
{ "role": "system", "content": "You are a helpful assistant." },
{
"role": "user",
"content": "Write a haiku about an Alligator."
}
]
)
print(response.choices[0].message)
import OpenAI from 'openai';
const openai = new OpenAI({
apiKey: 'your_api_key',
baseURL: 'https://api.ai.it.ufl.edu/v1'
});
const completion = await openai.chat.completions.create({
model: "gpt-5.2-codex",
messages: [
{ role: "system", content: "You are a helpful assistant." },
{
role: "user",
content: "Write a haiku about an Alligator.",
},
],
});
print(completion.choices[0].message)
References
- OpenAI GPT-5.2-Codex Model
https://platform.openai.com/docs/models/gpt-5.2-codex/