All stories

OpenAI opens Codex harness via Agents API

OpenAI has released the Agents API in public beta, giving developers hosted access to the same agent harness that runs Codex, with no fee beyond the tokens and tools their agents consume.

OpenAI said the API exposes the same harness and infrastructure behind Codex and ChatGPT for Work, with OpenAI hosting and maintaining the harness while developers choose where the agent's compute runs: an OpenAI-managed sandbox, their own infrastructure, or a partner environment. A production agent can be created in a single API call specifying task, model, tools, and environment.

Sandbox partners named at launch are Blaxel, Cloudflare, Daytona, DigitalOcean, E2B, Modal, Oracle, Runloop, and Vercel, covering fully managed or VPC deployments, file and secret storage options, and varying CPU, GPU, and memory profiles. OpenAI is also offering its own hosted sandbox, configurable with files, packages, skills, and plugins.

Three harness features are highlighted for long-running work. Automatic context compaction shrinks earlier context as a session nears its limit, letting workflows span multiple context windows without custom compaction code. Tool search loads tool definitions on demand to cut token usage and preserve cache, and programmatic tool calling lets agents run calls in parallel and filter results in code. Multi-agent support delegates independent subtasks to subagents that keep their own context while a main agent coordinates.

The harness is the open-source Codex harness, so developers can inspect the public codebase. There are no additional fees beyond tokens and tools consumed. OpenAI says it will iterate during the beta toward general availability. No benchmarks, latency figures, rate limits, or GA timeline were disclosed.