Назад к моделям
GPT-5-Codex
openaiopenai/gpt-5-codex
Гид по API
Chat completion
Через TheRouter gpt-5-codex вызывается через стандартный endpoint chat completions. TheRouter абстрагирует нативный Responses API в привычный интерфейс.
cURL
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-5-codex",
"messages": [
{"role": "user", "content": "Write a Python script to parse logs and extract error counts for each module."}
],
"reasoning_effort": "medium"
}'Вызов инструментов
Поддерживает полный набор инструментов GPT-5, включая параллельные вызовы и custom_tools.
cURL
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-5-codex",
"messages": [
{"role": "user", "content": "Look at the src/ directory and list all test files"}
],
"tools": [{
"type": "function",
"function": {
"name": "list_files",
"description": "List files in a directory",
"parameters": { "type": "object", "properties": { "path": {"type": "string"} } }
}
}],
"tool_choice": "auto"
}'Стриминг
cURL
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-H "Accept: text/event-stream" \
-d '{
"model": "openai/gpt-5-codex",
"messages": [
{"role": "user", "content": "Refactor this function to use async/await"}
],
"stream": true
}'Реестр фактов — каждая утверждаемая величина имеет источник
| источник | URL | получено | |
|---|---|---|---|
| Дата релиза | openai.com ↗ | 2026-05-28 | проверено |
| Дата отсечения данных | — | — | неизвестно |
| Идентификатор модели OpenAI | platform.openai.com ↗ | 2026-05-28 | проверено |
| Доступность API | openai.com ↗ | 2026-05-28 | проверено |
| Динамическое рассуждение | openai.com ↗ | 2026-05-28 | проверено |
| Автономное выполнение | openai.com ↗ | 2026-05-28 | проверено |
| Лицензия | — | — | проверено |
| SWE-bench Verified | openai.com ↗ | 2026-05-28 | проверено |
| Code Refactoring | openai.com ↗ | 2026-05-28 | проверено |
| Code Review Accuracy | openai.com ↗ | 2026-05-28 | проверено |
| OpenAI выпустила GPT-5.5 с улучшенной производительностью Codex | openai.com ↗ | 2026-05-28 | проверено |
| OpenAI выпускает системную карту GPT-5.3-Codex | openai.com ↗ | 2026-05-28 | проверено |
| OpenAI запускает GPT-5.2-Codex с SOTA | openai.com ↗ | 2026-05-28 | проверено |
| OpenAI выпускает GPT-5-Codex | openai.com ↗ | 2026-05-28 | проверено |
| В чём разница между GPT-5 и GPT-5-Codex? | openai.com ↗ | 2026-05-28 | к проверке |
| Могу ли я использовать GPT-5-Codex через API TheRouter? | openai.com ↗ | 2026-05-28 | к проверке |
| Как цена GPT-5-Codex соотносится с GPT-5? | openai.com ↗ | 2026-05-28 | к проверке |
| GPT-5-Codex хорош для некодинговых задач? | openai.com ↗ | 2026-05-28 | к проверке |