OpenAI Codex
Config file: ~/.codex/config.toml
Configuration
Add to your ~/.codex/config.toml:
Option 1: Bearer token from environment variable (Recommended)
[mcp_servers.audaxic-memory]
url = "https://memory-mcp.audaxic.com/mcp"
bearer_token_env_var = "AUDAXIC_API_KEY"
Set the environment variable:
export AUDAXIC_API_KEY="ak_your_api_key_here"
Option 2: Static header
[mcp_servers.audaxic-memory]
url = "https://memory-mcp.audaxic.com/mcp"
http_headers = { "Authorization" = "Bearer ak_your_api_key_here" }
Setup via CLI
# Add the server
codex mcp add audaxic-memory --url https://memory-mcp.audaxic.com/mcp --bearer-token-env-var AUDAXIC_API_KEY
# List configured servers
codex mcp list
Setup via ChatGPT Desktop App
- Open Settings → MCP servers
- Click Add server
- Enter:
- Name:
audaxic-memory - URL:
https://memory-mcp.audaxic.com/mcp - Bearer token env var:
AUDAXIC_API_KEY
- Name:
Setup via IDE Extension
- Click Gear menu → MCP servers
- Click Add server
- Enter the same details as above
Verify
In the Codex TUI, type /mcp to see active MCP servers.
Notes
- Codex uses TOML configuration (not JSON)
- CLI and Desktop share the same
~/.codex/config.tomlfile - Supports Streamable HTTP transport
- Environment variable approach is recommended for security
Behavioral Triggers
The Codex agent will automatically:
AUTO-SEARCH before:
- Making architectural decisions
- Adding new dependencies
- Fixing bugs (check for prior solutions)
- Starting new sessions (load preferences)
AUTO-SAVE after:
- User states a preference
- Decision with rationale made
- Complex bug fixed
- Project conventions learned
DO NOT save:
- Temporary state, debug info, secrets
MCP Tools
add_memory— text (required), user_id?, metadata?search_memories— query (required), user_id?, limit?get_memories— user_id?, limit?delete_memory— memory_ids[] (required)delete_all_memories— user_id?
Content Rules
- One fact per memory
- Natural language, not keywords
- Include reasoning, not just outcomes
- Be specific for better semantic matching
Lifecycle
Add → Search → Update (delete + re-add) → Delete (when obsolete)