OpenAI opens a managed Codex runtime in the Agents API
OpenAI’s public-beta Agents API exposes the managed runtime behind Codex. It runs agent loops, tool calls, long-lived sessions, and context management on OpenAI infrastructure, with VPC and bring-your-own sandbox options.

TL;DR
- OpenAI has put the Codex harness behind a public-beta API, and OpenAIDevs' public-beta announcement says it takes over orchestration, long-running sessions, and context management.
- The managed service coordinates model calls, tool use, and context, while callers choose agent capabilities and the environment for code and files, according to OpenAIDevs on the agent loop.
- Execution can run in an OpenAI-hosted sandbox, on self-hosted infrastructure, or through partners with VPC, compute, storage, and secrets options, as OpenAIDevs on sandbox choice details; OpenAIDevs' hosted-sandbox post adds packages, skills, and plugins to the managed option.
- The public beta carries no separate Agents API fee, TheRealAdamG's launch quote links to the announcement, while model, tool, and container usage remain billable.
Its launch example creates a session with an MCP server, a hosted environment, a skills directory, a vault, and three concurrent subagents in one request. testingcatalog's Agents dashboard screenshot already lists research, support, DevOps, meeting, and analytics templates, even as the page displayed a loading error.
The Codex control plane
OpenAI is taking responsibility for the session lifecycle, orchestration, compaction, and recovery, while the application supplies the tools and execution environment, according to the Agents API overview.
The same overview divides an implementation into four objects:
- Agent: model, instructions, tools, and MCP servers.
- Environment: an optional sandbox or computer for files, skills, and commands.
- Session: a durable agent instance that receives work.
- Events and items: session input and output.
A session starts with configuration and provisioning, then receives a task. Applications can stream events or use webhooks, and can send another task to continue a completed session or steer one still running.
Environments and sandboxes
The execution boundary is deliberately separate from the managed harness. OpenAI's launch post names three routes:
- OpenAI-hosted: OpenAI provisions a sandbox where agents run code, work with files, and produce artifacts.
- Self-hosted: the application supplies its own environment and workspace.
- Partner-hosted: Blaxel, Cloudflare, Daytona, DigitalOcean, E2B, Modal, Oracle, Runloop, and Vercel offer first-class integrations.
Partners cover fully managed environments and VPC deployments, plus different CPU, GPU, memory, storage, secrets, cold-start, and cost profiles.
Context compaction
OpenAI's launch post says the harness automatically compacts earlier context as a session nears its context limit, preserving information needed to continue across multiple windows. The API documentation adds session recovery and retained session state to that durability layer.
That removes application-level summarization from the basic long-horizon loop, alongside the state required to resume work after a pause.
Tool search and programmatic calls
Tool definitions are loaded on demand through tool search, which the launch post says reduces token use while preserving the model cache. Programmatic tool calling lets agents parallelize calls, chain operations, and filter or combine results in code before returning only the relevant output to context.
The documented tool surfaces are:
- MCP servers
- Custom functions
- Built-in tools, including web search
- Programmatic tool calling
Subagents
Multi-agent sessions break a task into independent subtasks, with each subagent carrying its own context before the primary agent combines the results, per the launch documentation. The launch request configures multi_agent.enabled and sets max_concurrent_subagents to three, while the API overview's example sets it to four.
The API surfaces this alongside session creation, so subagent orchestration is part of the runtime configuration rather than a separate service.
Templates
The template inventory names:
- Research Agent
- Customer Support Agent
- DevOps Assistant
- Meeting Assistant
- Analytics Agent
Pricing and data controls
OpenAI says in its public-beta announcement that the Agents API adds no separate fee. The API overview bills model usage at the selected model's API rate, OpenAI tools at their standard rates, and OpenAI-hosted sandboxes at standard container rates.
That overview currently limits data residency to the United States and excludes Zero Data Retention. Selecting a self-hosted sandbox does not make an Agents API session ZDR-eligible.
The ChatGPT Data agent
TheRealAdamG's Data agent post calls a new ChatGPT Data agent a separate product surface. Its description lists two layers of enterprise data access:
- Approved data sources: Amazon Redshift, Datadog, Google BigQuery, ClickHouse, Databricks, MongoDB, Snowflake, Google Drive, and SharePoint.
- Business context: semantic layers and trusted sources including Databricks Genie Ontology, dbt, GitHub, Snowflake Horizon, and BI dashboards.
The Agents API launch post does not name the Data agent or identify it as an API template.