show_hooks
-
List the hooks tmux runs when something happens on the server, such as a pane exiting. This tool does not set hooks. Hooks set through another path remain in their server or session until unset; configuration files persist them across server restarts. Reach for this when tmux does something no tool here asked for. Read configured tmux commands; accepts no client-supplied executable input. Returned values may contain executable configuration.
- MCP request method
tools/callSendshow_hooksas the tool name, with the arguments below.
Arguments
-
The session whose hooks to read, by
$-prefixed id or name. Omit for the server’s own.
No other arguments are accepted.
Result
Returns object
Types
Annotations
Advertised by the server
destructiveHintfalseidempotentHinttrueopenWorldHintfalsereadOnlyHinttruetitle"Show tmux Hooks"
Capability
- Toolset
- Inspect Request tmux state and terminal output.
- Process reach
none- tmux effects
observe
The capability row states what this tool reads, changes and reaches; the annotations are as the server advertises them.
Protocol data
Use the complete advertised contract for validation and client integration.
Input schema
{"$schema": "https://json-schema.org/draft/2020-12/schema","additionalProperties": false,"properties": {"session": {"description": "The session whose hooks to read, by `$`-prefixed id or name. Omit for\nthe server's own.","type": ["string","null"]}},"type": "object"}Output schema
{"$defs": {"Hook": {"description": "One tmux hook.","properties": {"command": {"description": "The command tmux runs.","type": "string"},"index": {"description": "Its index, when the hook is an array.","minimum": 0,"type": ["integer","null"]},"name": {"description": "The hook name, such as `pane-exited`.","type": "string"}},"required": ["name","index","command"],"type": "object"}},"$schema": "https://json-schema.org/draft/2020-12/schema","properties": {"hooks": {"description": "The hooks, in tmux's own order.","items": {"$ref": "#/$defs/Hook"},"type": "array"}},"required": ["hooks"],"type": "object"}