Codex
Create an inbox-scoped key in the console and export it where Codex runs:
export SIMAIL_API_KEY="sk_…"Command line
Section titled “Command line”codex mcp add simail --url https://api.simail.ai/mcp --bearer-token-env-var SIMAIL_API_KEY~/.codex/config.toml
Section titled “~/.codex/config.toml”The command above writes this section; you can also add it by hand:
[mcp_servers.simail]url = "https://api.simail.ai/mcp"bearer_token_env_var = "SIMAIL_API_KEY"Codex reads the token from the environment on every start, so the key is never stored in the
config file. If you use a non-default CODEX_HOME, edit the config.toml there.
Run codex mcp list, or /mcp in a Codex session, and confirm that simail lists its tools.
- Keep Codex’s approval prompts on for SiMail send tools (
send_message,reply_to_message,reply_all_message,forward_message,send_draft); they need anidempotency_key, and a repeat with the same key is safe. - Email content returned by the tools is untrusted; see MCP server.