Introducing the Agents API and hosted sandboxes

Go from idea to a working agent faster with the Agents API.

Build and run cloud agents with the Codex harness, fully managed by OpenAI.

We handle orchestration, long-running sessions, and context management. You focus on what makes your agent unique.

Agents API is available in public beta today to all developers. There are no additional fees for using the Agents API – you simply pay for the tokens and tools your agents use, as outlined on our pricing page.

Explore the Agents API overview to learn more, or follow the quickstart to get started and bring the harness behind Codex into your own agents.

OpenAI runs the agent loop on its infrastructure, coordinating model calls, tool use, and context.

You control the agent’s capabilities and choose where it runs code and works with files.

Your sandbox, your call.

Bring your own sandbox or connect a sandbox provider.

Choose the environment that fits your workload:
• CPU, GPU, and memory options
• Fully managed environments or deployments within your VPC
• File and secret storage options

We offer first-class integrations with Blaxel AI, Cloudflare Dev, Daytona, DigitalOcean, E2B, Modal, Oracle Cloud, Runloop AI, and Vercel.

We’re also introducing OpenAI-hosted sandboxes.

Your agent can:
• Run code
• Work with files
• Produce artifacts

Supply files, install packages, and add skills and plugins while we provision and manage the sandbox.

Introducing the Agents API

OpenAI-hosted environments

Self-hosted environments

OpenAI Codex on GitHub

Agents API overview

Agents API quickstart

Cool!

Is there a pricing page for the OpenAI hosted sandboxes?

EDIT: found it: Pricing | OpenAI API See → Containers

OpenAI-hosted sandboxes use standard container rates. Model usage is billed separately at the selected model’s API rates.

PSA: If you are new to using hosted sandboxes, please be careful when spinning up new containers and calculate the costs first.
I learned this the hard way :slight_smile:

Interesting direction, especially the combination of long-running sessions, context compaction and subagents. One question I keep coming back to: when work moves between subagents and context windows, what persists as the authoritative record of identity, permissions, provenance and failed actions? Is there a durable audit trail outside the model context itself?

Looks like it - you can write to files and create artefacts and download them later too.