# Connect the MultitaskAI MCP server to Codex CLI

Codex CLI reads MCP servers from config.toml. Add MultitaskAI with its URL and your API key as an HTTP header.

## Endpoint

```text
https://mcp.multitaskai.com
```

## Steps

1. Create an API key in your MultitaskAI account.
2. Open ~/.codex/config.toml for every project, or .codex/config.toml in a trusted project.
3. Add the server below, with your key in place of YOUR_API_KEY, and save the file.
4. Start Codex and run /mcp to check that MultitaskAI is listed.

```toml
[mcp_servers.multitaskai]
url = "https://mcp.multitaskai.com"
http_headers = { "Authorization" = "Bearer YOUR_API_KEY" }
```

## Authentication

Codex CLI sends your MultitaskAI API key in the Authorization header. Create a key in your account and use it in place of YOUR_API_KEY. Keep the key out of files you share or commit.

```text
Authorization: Bearer YOUR_API_KEY
```

## Good to know

- The same config.toml is shared by the ChatGPT desktop app, Codex CLI and the IDE extension.
- To keep the key out of the file, set bearer_token_env_var = "MULTITASKAI_API_KEY" instead of http_headers and export that variable.
- Project config in .codex/config.toml is read only in trusted projects.
- Run codex mcp list from a shell to check the server.

## Official documentation

The [OpenAI MCP documentation](https://learn.chatgpt.com/docs/extend/mcp?surface=cli) covers Codex CLI's own settings in detail. See the [overview](/docs.md) for the endpoint and authentication, and [pricing](/pricing/) for the daily free requests.
