# Codex

OpenAI Codex is not directly compatible with The Grid today. Codex speaks the OpenAI Responses API (`/v1/responses`), and The Grid currently exposes the OpenAI Chat Completions API and the Anthropic Messages API. There is no configuration that bridges the two protocols, so direct integration is not possible right now.

## Why this is a protocol mismatch, not a config problem

Codex dropped Chat Completions support in early 2026 ([discussion #7782](https://github.com/openai/codex/discussions/7782), [PR #10157](https://github.com/openai/codex/pull/10157)) and now only sends requests to `/v1/responses`. The Responses API uses different endpoint paths, request shapes, and streaming formats from Chat Completions. The Grid's Consumption API implements Chat Completions and Anthropic Messages. Pointing `OPENAI_BASE_URL` at The Grid does not work; Codex still uses Responses-API wire calls and gets 404s.

## What to do today

* **Use any other coding tool that speaks Chat Completions.** Cline, Continue, Kilo Code, OpenCode, OpenClaw, and Hermes Agent all integrate with The Grid through the OpenAI-compatible path. See the [Any OpenAI-compatible tool](/docs/integrations-and-best-practices/any-openai-compatible-tool.md) page for the general pattern.
* **Use The Grid in the rest of your stack.** Codex can stay on its native OpenAI backend for interactive coding while your application's inference (LangChain agents, custom tools, server-side calls) runs on The Grid.

## What we're tracking

Responses API support on The Grid is on the roadmap. When it ships, this page becomes a setup guide.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://thegrid.ai/docs/integrations-and-best-practices/integrations/codex.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
