config-sample.md +110 −12
27# Core Model Selection27# Core Model Selection
28################################################################################28################################################################################
29 29
3030# Primary model used by Codex. Recommended example for most users: "gpt-5.4".# Primary model used by Codex. Recommended example for most users: "gpt-5.5".
3131model = "gpt-5.4"model = "gpt-5.5"
32 32
33# Communication style for supported models. Allowed values: none | friendly | pragmatic33# Communication style for supported models. Allowed values: none | friendly | pragmatic
34# personality = "pragmatic"34# personality = "pragmatic"
35 35
36# Optional model override for /review. Default: unset (uses current session model).36# Optional model override for /review. Default: unset (uses current session model).
3737# review_model = "gpt-5.4"# review_model = "gpt-5.5"
38 38
39# Provider id selected from [model_providers]. Default: "openai".39# Provider id selected from [model_providers]. Default: "openai".
40model_provider = "openai"40model_provider = "openai"
83# Inline override for the history compaction prompt. Default: unset.83# Inline override for the history compaction prompt. Default: unset.
84# compact_prompt = ""84# compact_prompt = ""
85 85
8686# Override the default commit co-author trailer. Set to "" to disable it.# Override the default commit co-author trailer. This only takes effect when
87# [features].codex_git_commit is enabled. When enabled and unset, Codex uses
88# "Codex <noreply@openai.com>". Set to "" to disable it.
87# commit_attribution = "Jane Doe <jane@example.com>"89# commit_attribution = "Jane Doe <jane@example.com>"
88 90
89# Override built-in base instructions with a file path. Default: unset.91# Override built-in base instructions with a file path. Default: unset.
109# - never: never prompt (risky)111# - never: never prompt (risky)
110# - { granular = { ... } }: allow or auto-reject selected prompt categories112# - { granular = { ... } }: allow or auto-reject selected prompt categories
111approval_policy = "on-request"113approval_policy = "on-request"
114# Who reviews eligible approval prompts: user (default) | auto_review
115# approvals_reviewer = "user"
116
112# Example granular policy:117# Example granular policy:
113# approval_policy = { granular = {118# approval_policy = { granular = {
114# sandbox_approval = true,119# sandbox_approval = true,
127# - workspace-write132# - workspace-write
128# - danger-full-access (no sandbox; extremely risky)133# - danger-full-access (no sandbox; extremely risky)
129sandbox_mode = "read-only"134sandbox_mode = "read-only"
135# Named permissions profile to apply by default. Built-ins:
136# :read-only | :workspace | :danger-no-sandbox
137# Use a custom name such as "workspace" only when you also define [permissions.workspace].
138# default_permissions = ":workspace"
139
140# Example filesystem profile. Use `"none"` to deny reads for exact paths or
141# glob patterns. On platforms that need pre-expanded glob matches, set
142# glob_scan_max_depth when using unbounded patterns such as `**`.
143# [permissions.workspace.filesystem]
144# glob_scan_max_depth = 3
145# ":project_roots" = { "." = "write", "**/*.env" = "none" }
146# "/absolute/path/to/secrets" = "none"
130 147
131################################################################################148################################################################################
132# Authentication & Login149# Authentication & Login
274# Managed network proxy settings291# Managed network proxy settings
275################################################################################292################################################################################
276 293
277294[permissions.network]# Set `default_permissions = "workspace"` before enabling this profile.
295# [permissions.workspace.network]
278# enabled = true296# enabled = true
279# proxy_url = "http://127.0.0.1:43128"297# proxy_url = "http://127.0.0.1:43128"
280# admin_url = "http://127.0.0.1:43129"298# admin_url = "http://127.0.0.1:43129"
286# dangerously_allow_non_loopback_admin = false304# dangerously_allow_non_loopback_admin = false
287# dangerously_allow_all_unix_sockets = false305# dangerously_allow_all_unix_sockets = false
288# mode = "limited" # limited | full306# mode = "limited" # limited | full
289# allowed_domains = ["api.openai.com"]
290# denied_domains = ["example.com"]
291# allow_unix_sockets = ["/var/run/docker.sock"]
292# allow_local_binding = false307# allow_local_binding = false
308#
309# [permissions.workspace.network.domains]
310# "api.openai.com" = "allow"
311# "example.com" = "deny"
312#
313# [permissions.workspace.network.unix_sockets]
314# "/var/run/docker.sock" = "allow"
293 315
294################################################################################316################################################################################
295# History (table)317# History (table)
313# Notification mechanism for terminal alerts: auto | osc9 | bel. Default: "auto"335# Notification mechanism for terminal alerts: auto | osc9 | bel. Default: "auto"
314# notification_method = "auto"336# notification_method = "auto"
315 337
338# When notifications fire: unfocused (default) | always
339# notification_condition = "unfocused"
340
316# Enables welcome/status/spinner animations. Default: true341# Enables welcome/status/spinner animations. Default: true
317animations = true342animations = true
318 343
327# Set to [] to hide the footer.352# Set to [] to hide the footer.
328# status_line = ["model", "context-remaining", "git-branch"]353# status_line = ["model", "context-remaining", "git-branch"]
329 354
355# Ordered list of terminal window/tab title item IDs. When unset, Codex uses:
356# ["spinner", "project"]. Set to [] to clear the title.
357# Available IDs include app-name, project, spinner, status, thread, git-branch, model,
358# and task-progress.
359# terminal_title = ["spinner", "project"]
360
330# Syntax-highlighting theme (kebab-case). Use /theme in the TUI to preview and save.361# Syntax-highlighting theme (kebab-case). Use /theme in the TUI to preview and save.
331# You can also add custom .tmTheme files under $CODEX_HOME/themes.362# You can also add custom .tmTheme files under $CODEX_HOME/themes.
332# theme = "catppuccin-mocha"363# theme = "catppuccin-mocha"
333 364
365# Custom key bindings. Context-specific bindings override [tui.keymap.global].
366# Use [] to unbind an action.
367# [tui.keymap.global]
368# open_transcript = "ctrl-t"
369# open_external_editor = []
370#
371# [tui.keymap.composer]
372# submit = ["enter", "ctrl-m"]
373
334# Internal tooltip state keyed by model slug. Usually managed by Codex.374# Internal tooltip state keyed by model slug. Usually managed by Codex.
335# [tui.model_availability_nux]375# [tui.model_availability_nux]
336# "gpt-5.4" = 1376# "gpt-5.4" = 1
360# Leave this table empty to accept defaults. Set explicit booleans to opt in/out.400# Leave this table empty to accept defaults. Set explicit booleans to opt in/out.
361# shell_tool = true401# shell_tool = true
362# apps = false402# apps = false
403# codex_git_commit = false
363# codex_hooks = false404# codex_hooks = false
364# unified_exec = true405# unified_exec = true
365# shell_snapshot = true406# shell_snapshot = true
366# multi_agent = true407# multi_agent = true
367# personality = true408# personality = true
368# fast_mode = true409# fast_mode = true
369# smart_approvals = false
370# enable_request_compression = true410# enable_request_compression = true
371# skill_mcp_dependency_install = true411# skill_mcp_dependency_install = true
372# prevent_idle_sleep = false412# prevent_idle_sleep = false
373 413
414################################################################################
415# Memories (table)
416################################################################################
417
418# Enable memories with [features].memories, then tune memory behavior here.
419# [memories]
420# generate_memories = true
421# use_memories = true
422# disable_on_external_context = false # legacy alias: no_memories_if_mcp_or_web_search
423
424################################################################################
425# Lifecycle hooks can be configured here inline or in a sibling hooks.json.
426################################################################################
427
428# [hooks]
429# [[hooks.PreToolUse]]
430# matcher = "^Bash$"
431#
432# [[hooks.PreToolUse.hooks]]
433# type = "command"
434# command = 'python3 "/absolute/path/to/pre_tool_use_policy.py"'
435# timeout = 30
436# statusMessage = "Checking Bash command"
437
374################################################################################438################################################################################
375# Define MCP servers under this table. Leave empty to disable.439# Define MCP servers under this table. Leave empty to disable.
376################################################################################440################################################################################
384# command = "docs-server" # required448# command = "docs-server" # required
385# args = ["--port", "4000"] # optional449# args = ["--port", "4000"] # optional
386# env = { "API_KEY" = "value" } # optional key/value pairs copied as-is450# env = { "API_KEY" = "value" } # optional key/value pairs copied as-is
387451# env_vars = ["ANOTHER_SECRET"] # optional: forward these from the parent env# env_vars = ["ANOTHER_SECRET"] # optional: forward local parent env vars
452# env_vars = ["LOCAL_TOKEN", { name = "REMOTE_TOKEN", source = "remote" }]
388# cwd = "/path/to/server" # optional working directory override453# cwd = "/path/to/server" # optional working directory override
454# experimental_environment = "remote" # experimental: run stdio via a remote executor
389# startup_timeout_sec = 10.0 # optional; default 10.0 seconds455# startup_timeout_sec = 10.0 # optional; default 10.0 seconds
390# # startup_timeout_ms = 10000 # optional alias for startup timeout (milliseconds)456# # startup_timeout_ms = 10000 # optional alias for startup timeout (milliseconds)
391# tool_timeout_sec = 60.0 # optional; default 60.0 seconds457# tool_timeout_sec = 60.0 # optional; default 60.0 seconds
416# - openai482# - openai
417# - ollama483# - ollama
418# - lmstudio484# - lmstudio
485# - amazon-bedrock
486# These IDs are reserved. Use a different ID for custom providers.
419 487
420[model_providers]488[model_providers]
421 489
490# --- Example: built-in Amazon Bedrock provider options ---
491# model_provider = "amazon-bedrock"
492# model = "<bedrock-model-id>"
493# [model_providers.amazon-bedrock.aws]
494# profile = "default"
495# region = "eu-central-1"
496
422# --- Example: OpenAI data residency with explicit base URL or headers ---497# --- Example: OpenAI data residency with explicit base URL or headers ---
423# [model_providers.openaidr]498# [model_providers.openaidr]
424# name = "OpenAI Data Residency"499# name = "OpenAI Data Residency"
425# base_url = "https://us.api.openai.com/v1" # example with 'us' domain prefix500# base_url = "https://us.api.openai.com/v1" # example with 'us' domain prefix
426# wire_api = "responses" # only supported value501# wire_api = "responses" # only supported value
427502# # requires_openai_auth = true # built-in OpenAI defaults to true# # requires_openai_auth = true # use only for providers backed by OpenAI auth
428# # request_max_retries = 4 # default 4; max 100503# # request_max_retries = 4 # default 4; max 100
429# # stream_max_retries = 5 # default 5; max 100504# # stream_max_retries = 5 # default 5; max 100
430# # stream_idle_timeout_ms = 300000 # default 300_000 (5m)505# # stream_idle_timeout_ms = 300000 # default 300_000 (5m)
443# env_key_instructions = "Set AZURE_OPENAI_API_KEY in your environment"518# env_key_instructions = "Set AZURE_OPENAI_API_KEY in your environment"
444# # supports_websockets = false519# # supports_websockets = false
445 520
521# --- Example: command-backed bearer token auth ---
522# [model_providers.proxy]
523# name = "OpenAI using LLM proxy"
524# base_url = "https://proxy.example.com/v1"
525# wire_api = "responses"
526#
527# [model_providers.proxy.auth]
528# command = "/usr/local/bin/fetch-codex-token"
529# args = ["--audience", "codex"]
530# timeout_ms = 5000
531# refresh_interval_ms = 300000
532
446# --- Example: Local OSS (e.g., Ollama-compatible) ---533# --- Example: Local OSS (e.g., Ollama-compatible) ---
447534# [model_providers.ollama]# [model_providers.local_ollama]
448# name = "Ollama"535# name = "Ollama"
449# base_url = "http://localhost:11434/v1"536# base_url = "http://localhost:11434/v1"
450# wire_api = "responses"537# wire_api = "responses"
471# enabled = false558# enabled = false
472# approval_mode = "approve"559# approval_mode = "approve"
473 560
561# Optional tool suggestion allowlist for connectors or plugins Codex can offer to install.
562# [tool_suggest]
563# discoverables = [
564# { type = "connector", id = "gmail" },
565# { type = "plugin", id = "figma@openai-curated" },
566# ]
567# disabled_tools = [
568# { type = "plugin", id = "slack@openai-curated" },
569# { type = "connector", id = "connector_googlecalendar" },
570# ]
571
474################################################################################572################################################################################
475# Profiles (named presets)573# Profiles (named presets)
476################################################################################574################################################################################