Support PostToolUse.suppressOutput

Open 💬 0 comments Opened Aug 17, 2026 by kabel-voidship

What variant of Codex are you using?

CLI

What feature would you like to see?

Support suppressing successful tool output in transcripts via PostToolUse

Summary

Codex currently displays successful MCP/tool call arguments and results in the
user-visible transcript. There is no supported configuration or hook mechanism
for suppressing routine successful output while preserving errors.

PostToolUse already parses suppressOutput and updatedMCPToolOutput, but the
documentation says they are not supported. Attempting to use them causes the
hook to fail and normal output processing continues.

Please implement a supported way for hooks to suppress or replace successful
tool output.

Use case

Some tools must return substantial structured data to the agent for
correctness, but that data is not useful operator communication.

For example, an issue-management MCP workflow may need to:

  1. Read the authoritative issue and its latest revision.
  2. Perform a mutation using optimistic concurrency.
  3. Retain the resulting revision for the next mutation.
  4. Tell the operator only: “Updated issue abcd1234 to revision 7.”

Today, the transcript may display:

  • the complete tool arguments;
  • the issue body;
  • every comment;
  • the complete history;
  • the mutation response;
  • followed by the agent’s concise summary.

This creates noisy transcripts, buries actual decisions, and unnecessarily
exposes data already consumed by the agent.

Prompt or AGENTS.md instructions cannot solve this because the Codex UI
renders the tool audit card independently of whether the agent repeats the
result.

Current behavior

A PostToolUse hook cannot suppress successful output.

The documented suppressOutput and updatedMCPToolOutput fields are parsed but
unsupported. Returning them reports a hook failure and Codex continues
processing/displaying the original tool result.

Relevant documentation:

https://developers.openai.com/codex/config-advanced#hooks

Other settings do not address the problem:

  • history.persistence = "none" controls transcript persistence, not live

display.

  • tool_output_token_limit controls stored output size, not visibility.
  • TUI configuration has no tool-output visibility setting.

Desired behavior

Allow a PostToolUse hook to suppress or replace the user-visible result of a
successful tool invocation without:

  • changing the result already supplied to the model;
  • marking the tool call as failed;
  • hiding errors or approval requests;
  • disabling audit logging outside the interactive transcript.

For example:

{
  "hookSpecificOutput": {
    "hookEventName": "PostToolUse",
    "suppressOutput": true
  }
}

Or:

{
  "hookSpecificOutput": {
    "hookEventName": "PostToolUse",
    "updatedMCPToolOutput": {
      "summary": "Updated Ishana issue abcd1234 to revision 7."
    }
  }
}

Important distinction

This request is about presentation in the interactive transcript, not
destruction of audit evidence.

Codex may continue retaining the original call and result according to
configured history, telemetry, and administrative audit policies. The UI could
show a collapsed placeholder such as:

Successful tool result suppressed by PostToolUse hook

That placeholder could offer an explicit expansion control when policy allows.

Suggested controls

It would be useful to support:

  • suppressing only successful results;
  • replacing results with a short hook-provided summary;
  • independent control of tool arguments and tool results;
  • matching by canonical tool name or namespace;
  • always displaying failures, approval requests, and hook errors;
  • an expandable “show original” affordance;
  • separate transcript-display and persisted-audit policies.

Example project configuration:

[[hooks.PostToolUse]]
matcher = "mcp__ishana__*"
command = [".codex/hooks/quiet-ishana-result"]

The hook could then decide dynamically whether to suppress output based on
success, result shape, or operation type.

A simpler declarative alternative might be:

[tool_display]
default = "expanded"

[tool_display."mcp__ishana__*"]
success = "summary"
failure = "expanded"
arguments = "collapsed"

Security considerations

Suppression should not:

  • bypass tool approvals;
  • hide destructive-action prompts;
  • hide failed calls;
  • alter the model-facing result unless replacement is explicitly requested;
  • override managed organization audit requirements;
  • remove persisted evidence when policy requires it.

The transcript should clearly indicate that a call occurred and that its output
was suppressed or summarized.

Reproduction

  1. Configure an MCP server whose successful tool returns a substantial JSON

object.

  1. Add a PostToolUse hook for that MCP tool.
  2. Return suppressOutput: true.
  3. Invoke the tool successfully.

Actual result:

  • Codex reports the unsupported hook behavior.
  • The original tool arguments/result remain visible.

Expected result:

  • The tool succeeds normally.
  • The agent receives the original result.
  • The transcript displays only a suppression marker or hook-provided summary.

Environment

  • Codex surface: [CLI / desktop app / IDE extension]
  • Codex version: [paste version]
  • OS: [paste OS]
  • Configuration: PostToolUse hook matching an MCP tool

Additional information

_No response_

View original on GitHub ↗