Skip to main content
Replicas runs Codex inside isolated workspace VMs, with access to your repository, environment configuration, and integrations.

Setup

Choose one authentication method:
  • Ollama: Add an API key and base URL under Ollama in Coding Agents. See Ollama setup.
  • OpenAI OAuth: Click Sign in with ChatGPT under Codex in Coding Agents and enter the one-time code on OpenAI’s verification page, or run replicas codex-auth. The code needs device code authorization turned on in ChatGPT Settings → Security; in a ChatGPT workspace, the workspace owner may need to allow it.
  • OpenAI API key: Add an OpenAI API key under Organization → Coding Agents.
  • OpenAI compatible: Under Inference providers → OpenAI Compatible, add a Responses API-compatible endpoint with an API key or exact Authorization header. Replicas reads models from <endpoint>/models unless you provide a separate models endpoint.
  • Microsoft Foundry: Add an Azure OpenAI API key, base URL, and model deployment under Organization → Coding Agents.
replicas codex-auth saves to your personal account, which works in every organization you belong to and takes priority over organization defaults. Admins can pass --org to share one ChatGPT subscription with every member of the active organization. See Credentials for details, and replicas org to check which organization is active.

Models

Replicas supports the current GPT coding model family exposed in the workspace model picker. Set the organization default under Organization → Settings → Preferences, or choose a model for an individual chat. The available models depend on the connected credential. For an OpenAI-compatible endpoint, use Check models while connecting it to verify the catalog and preview the models that will appear in Codex pickers. The endpoint must return an OpenAI-compatible { "data": [...] } response whose entries contain id (or model); cursor pagination may use has_more and next_cursor. Every model available through the active Codex credential appears in the workspace, automation, and default-setting pickers, including models added later. Organization admins can hide individual built-in models, as long as one stays visible, under Codex → Models in Coding Agents settings; an OpenAI-compatible endpoint’s catalog is shown as returned. Older workspaces can hide models that require a newer Codex runtime. Start a new workspace to use a model that does not appear.

Using Codex in Workspaces

In a workspace, use the composer’s harness/model picker to choose Codex and start or continue a session. Codex can:

Goal Mode

Use /goal <objective> to give the thread a persistent objective. Pause, resume, or remove it with /goal pause, /goal resume, or /goal clear. The active goal appears above the composer and on the chat’s tab.

Thinking levels

Use Ultra in the thinking picker for Codex models that support the ultra reasoning effort.

Ultrafast

When your ChatGPT plan offers Codex’s Ultrafast tier for the selected model (for example Pro 500 or Enterprise), Ultrafast appears next to Fast in the composer’s mode menu. It replaces Fast for that chat’s turns.

Chat history

Codex sessions persist across turns and workspace sleep. Codex compacts its context automatically when needed, and new chats compact sooner if you set an Auto-compact limit in your preferences. Send /compact to compact the active conversation manually. Use replicas read from the CLI to inspect transcript history.

Model at capacity

When OpenAI reports that the selected model is at capacity, Replicas waits and continues the turn where it stopped, up to five times over about two minutes. Each retry shows in the chat, and Stop cancels a pending one.

Programmatic Use

Select Codex anywhere Replicas accepts a coding agent:

When to Use Codex

Codex is a strong fit when you want OpenAI-native coding models, steerable active turns, or a persistent goal for longer work. Use Claude Code when you need Claude background tasks; use Cursor or Opencode when you prefer their model and authentication ecosystems.