Codex Auto-Answers Questions? Stop the 60-Second Timer

Codex Auto-Answers Questions? Stop the 60-Second Timer

Aident AI

A suspended hourglass above an open decision gate with one pathway waiting in soft blue light.

Codex Auto-Answers Questions? Stop the 60-Second Timer

If Codex answers its own Plan mode question after 60 seconds, the timeout is coming from the optional autoResolutionMs field on request_user_input. Start with a durable instruction that tells Codex to omit that field. If your client still shows a countdown, use a trusted PreToolUse hook to remove the field before the question reaches the host.

OpenAI documents the field as optional: when it is present, a host may resolve the prompt after the specified interval. As of July 31, 2026, OpenAI's issue tracker still has an open request for a first-class setting to disable the behavior. Silence should never become consent for a scope, permission, or destructive decision.

The Short Fix

Add this policy to your global ~/.codex/AGENTS.md, or to the repository's AGENTS.md if the rule belongs only to one project:

## User input

- When a decision changes scope, data, permissions, or output, ask me and wait.
- Do not pass `autoResolutionMs` to `request_user_input` unless I explicitly request a timed default.
- Treat silence as no approval. Stop instead of selecting a default

Restart Codex and test the rule with a harmless, read-only choice. If the prompt still counts down, keep the instruction and add the deterministic hook in Step 3.

Prerequisites

You need:

  • a Codex build that exposes request_user_input;

  • a trusted user or project config layer;

  • jq on your PATH for the hook below;

  • a clean working tree for the verification test.

Record the starting state:

codex --version
jq --version
git status --short

Expected result: Codex and jq print versions, and every local change is accounted for. Do not use a repository with uncommitted work you cannot explain for the timer test.

Step 1: Confirm the Exact Behavior

Open Plan mode and send this bounded prompt:

Before doing anything, ask whether you should inspect README.md or package.json.
Do not use any tool until I answer. Do not set a timed default

Wait at least 75 seconds without answering.

This guide applies if the question displays a countdown and Codex selects an answer when the timer ends. If you instead see an approval prompt for a command, file edit, network request, or integration Action, stop and diagnose that approval path separately.

If Codex starts reading or editing after the timer, interrupt it and check:

git status --short
git diff --stat

Expected result: this read-only probe leaves the working tree unchanged.

Step 2: Add the No-Timeout Instruction

Put the policy from the short fix in the narrowest durable instruction file that covers the affected work. A global rule is appropriate if you never want timed questions. A project rule is better when one repository requires fail-closed decisions but other unattended tasks intentionally use low-impact defaults.

Restart Codex and repeat the 75-second test. Some users report that the instruction prevents the model from setting autoResolutionMs; others report that the field can still appear. Treat a passing test as evidence for your current client and prompt, not as a permanent enforcement boundary.

Step 3: Strip the Timeout with a Trusted Hook

Open ~/.codex/config.toml and append this block. Preserve any existing configuration.

[[hooks.PreToolUse]]
matcher = "^request_user_input$"

[[hooks.PreToolUse.hooks]]
type = "command"
command = """jq -c 'if ((.tool_input | type) == "object" and (.tool_input | has("autoResolutionMs"))) then {hookSpecificOutput:{hookEventName:"PreToolUse",permissionDecision:"allow",updatedInput:(.tool_input | del(.autoResolutionMs))}} else empty end'"""
timeout = 5
statusMessage = "Removing question timeout"

Why this shape matters:

  • the matcher limits the hook to request_user_input;

  • the hook changes nothing when the timeout field is absent;

  • updatedInput preserves every other question argument and removes only autoResolutionMs;

  • it does not approve a shell command, file edit, network request, or provider Action.

Open /hooks in Codex, inspect the exact command, and trust it. OpenAI documents that non-managed command hooks are skipped until their current definition is reviewed and trusted. Restart the client after the config change.

If you already use ~/.codex/hooks.json, add the equivalent matcher there instead of defining the same hook twice. Codex merges hook sources, and duplicate definitions can make the behavior harder to audit.

Step 4: Verify the Hook End to End

Repeat the same read-only Plan mode prompt and wait 75 seconds.

Success requires all four observations:

  1. /hooks lists the request_user_input matcher as trusted and enabled.

  2. The question remains open after 60 seconds.

  3. Codex does not select either answer while you are silent.

  4. git status --short is unchanged after you answer or interrupt the test.

Then answer README.md. Expected result: Codex reads only that file and continues from your explicit choice.

Step 5: Make Unattended Work Fail Closed

Removing every question timeout can pause an unattended task forever. That is the intended tradeoff for ambiguous decisions. Define harmless defaults before a long run only when you genuinely want them:

For read-only research choices, choose the narrowest option if I am unavailable.
For writes, external messages, purchases, permission changes, deletion, or scope
expansion, stop and wait for explicit approval. Silence is never approval

This separates low-impact continuation from decisions that need a person. For another recoverable guardrail, see How to Stop Codex from Deleting Files.

Common Failure Modes

The Countdown Still Appears

Check /hooks first. The usual causes are an untrusted hook, a misspelled matcher, hooks disabled in the active config layer, or a client path that does not expose this local function tool to hooks. OpenAI notes that specialized tool paths can opt out of the default hook path.

Do not assume the hook ran because the config parses. The 75-second test is the proof.

jq Is Not Found

Run command -v jq in the same environment that starts Codex. If it returns nothing, install jq through your normal package manager or replace the handler with a reviewed script that emits the same JSON shape. Do not download and execute an unreviewed workaround.

The Instruction Works, Then Stops Working

Instructions guide the model; they do not rewrite the tool call after it is produced. Keep the hook for a deterministic local guardrail, and rerun the test after Codex updates.

Disabling the Question Tool Seems Easier

Disabling request_user_input removes the entire interactive question path. Codex may guess without asking, switch to plain text, or stop. That is different from keeping questions and removing only their automatic resolution.

The Hook Breaks After an Update

Disable the hook in /hooks, remove the added TOML block, restart Codex, and confirm the client works normally. Then compare the current Codex Hooks documentation and app-server schema before adapting the matcher or output.

Why the Hook Works

OpenAI's app-server documentation says autoResolutionMs is an optional integer or null; when present, a host client can resolve the question after that interval. The Hooks documentation says PreToolUse can inspect and rewrite other local function-tool arguments with permissionDecision: "allow" plus updatedInput.

The hook removes the timeout before the host sees the question while leaving the question, choices, and all other inputs intact. It is narrower than disabling the tool and more reliable than asking the model to remember the rule on every turn.

This is still a client-side guardrail, not a security boundary. Review the hook after upgrades and keep Git, backups, sandboxing, and provider approvals in place. For a broader treatment of credentials and external tools, read Give AI Agents API Access Without Exposing Keys.

Preflight One External Action Without Executing It

A timed clarification and an integration approval are different boundaries. Open Aident Loadout, connect one read-only integration, search for one relevant Action, inspect its current schema, and run preflight only.

The measurable check is simple: the preflight returns input validation and a credit estimate, no provider request is dispatched, and no external object changes. Execute only after you have reviewed the exact Action, input, and approval prompt. See How to Connect Claude Code and Codex to Real-World Tools for the setup path.

Sources

Refresh this guide when OpenAI adds a first-class setting, changes the request_user_input schema, or changes hook matching and input-rewrite behavior.

Home

Home

Home

Integrations

Integrations

Integrations

Vault

Vault

Vault

Audit

Audit

Audit

Arana Grande

Arana Grande

Arana Grande

Free

Free

Free

30-day audit summary

30-day audit summary

30-day audit summary

Daily action-call volume and the latest receipts from the Loadout audit trail.

Daily action-call volume and the latest receipts from the Loadout audit trail.

Daily action-call volume and the latest receipts from the Loadout audit trail.

View Audit

View Audit

View Audit

Loadout usage

Loadout usage

Loadout usage

617 action calls in the last 30 days

617 action calls in the last 30 days

617 action calls in the last 30 days

May 19 - Jun 17

May 19 - Jun 17

May 19 - Jun 17

10 active days

10 active days

10 active days

Less

Less

Less

More

More

More

Recent activity

Recent activity

Recent activity

Latest action-call receipts from connected agents

Latest action-call receipts from connected agents

Latest action-call receipts from connected agents

Apr 23, 09:23 AM

Apr 23, 09:23 AM

Apr 23, 09:23 AM

Shopify

Shopify

Shopify

Creates Or Updates An Asset For A Theme

Creates Or Updates An Asset For A Theme

Creates Or Updates An Asset For A Theme

Success

Success

Success

Apr 23, 09:21 AM

Apr 23, 09:21 AM

Apr 23, 09:21 AM

Shopify

Shopify

Shopify

Update Products Param Product Id

Update Products Param Product Id

Update Products Param Product Id

Success

Success

Success

Apr 23, 08:53 AM

Apr 23, 08:53 AM

Apr 23, 08:53 AM

Shopify

Shopify

Shopify

Update Products Param Product Id

Update Products Param Product Id

Update Products Param Product Id

Failed

Failed

Failed

Apr 22, 22:13 PM

Apr 22, 22:13 PM

Apr 22, 22:13 PM

Shopify

Shopify

Shopify

Create Product Image

Create Product Image

Create Product Image

Success

Success

Success

Apr 22, 22:12 PM

Apr 22, 22:12 PM

Apr 22, 22:12 PM

Shopify

Shopify

Shopify

Create Product Image

Create Product Image

Create Product Image

Success

Success

Success

Connected integration coverage

Connected integration coverage

Connected integration coverage

162

162

162

of 753 accessible connected

of 753 accessible connected

of 753 accessible connected

Callable actions

Callable actions

Callable actions

1,126

1,126

1,126

Vault credentials

Vault credentials

Vault credentials

8

8

8

Explore what's possible

Explore what's possible

Explore what's possible

See all Integrations

See all Integrations

See all Integrations

Google Ads

Google Ads

Google Ads

All available Goolge Ads tools via...

All available Goolge Ads tools via...

All available Goolge Ads tools via...

X (twitter)

X (twitter)

X (twitter)

All available X tools via...

All available X tools via...

All available X tools via...

Github

Github

Github

All available Github tools via...

All available Github tools via...

All available Github tools via...

Notion

Notion

Notion

All available Notion tools via...

All available Notion tools via...

All available Notion tools via...

Slack

Slack

Slack

All available Slack tools via...

All available Slack tools via...

All available Slack tools via...

Firecrawl

Firecrawl

Firecrawl

All available Firecrawl tools via...

All available Firecrawl tools via...

All available Firecrawl tools via...

753 integrations are available for loadouts.

753 integrations are available for loadouts.

753 integrations are available for loadouts.

Plug your entire stack into your AI agents.

Plug your entire stack into your AI agents.

Plug your entire stack into your AI agents.

Skip the integration headache. Plug 750+ tools into Claude Code, Codex, and OpenClaw in one go, and let your agents execute today.

Skip the integration headache. Plug 750+ tools into Claude Code, Codex, and OpenClaw in one go, and let your agents execute today.