{
  "name": "snapshot_pane",
  "wireName": "snapshot_pane",
  "source": {
    "repo": "libtmux/libtmux-rs",
    "revision": "2cef1aa642182dd1970c3688feb6a568ff666e64",
    "extractedRevision": "2cef1aa642182dd1970c3688feb6a568ff666e64",
    "file": "crates/tmux-mcp/src/tools/inspect.rs",
    "line": 257
  },
  "description": "Read pane content with cursor position, mode state, and scroll position in one reply. The state query and capture are separate, so the result is not atomic. Prefer this over capture_pane when you need to reason about where the pane is rather than only what it says -- a cursor at column zero on a fresh line is a shell waiting, and a pane in a mode may route keys to tmux instead of the workload. Read pane output; accepts no client-supplied executable input. Returned content may be sensitive or untrusted.",
  "schemaStatus": "runtime",
  "inputSchema": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "additionalProperties": false,
    "properties": {
      "history": {
        "default": false,
        "description": "Include scrollback rather than only the visible screen.",
        "type": "boolean"
      },
      "max_lines": {
        "description": "The most content lines to return, oldest dropped first.\n\nDefaults to the whole visible screen. The end of a pane is what says\nwhat just happened, so a limit keeps the end.",
        "minimum": 0,
        "type": [
          "integer",
          "null"
        ]
      },
      "pane": {
        "description": "The `%`-prefixed pane id.",
        "type": "string"
      }
    },
    "required": [
      "pane"
    ],
    "type": "object"
  },
  "outputSchema": {
    "$defs": {
      "PaneView": {
        "description": "One pane, as the protocol sees it.",
        "properties": {
          "active": {
            "description": "Whether this is the window's active pane.",
            "type": "boolean"
          },
          "caller": {
            "$ref": "#/$defs/Relation",
            "description": "Whether this is the pane the MCP server itself runs in.\n\n`self` only on a confirmed match of both socket and pane id; `other`\nfor every pane that is not, including one this crate cannot prove\neither way; `unknown` when the server is not running inside tmux, so\nthe question has no answer."
          },
          "command": {
            "description": "The command currently running.",
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "description": "The `%`-prefixed tmux identity.",
            "type": "string"
          },
          "path": {
            "description": "The pane's working directory.",
            "type": [
              "string",
              "null"
            ]
          },
          "window_id": {
            "description": "The window that contains the pane.",
            "type": "string"
          }
        },
        "required": [
          "id",
          "window_id",
          "active",
          "caller"
        ],
        "type": "object"
      },
      "Relation": {
        "description": "How a pane relates to the process answering the request.\n\nThree values rather than a boolean, because \"not the caller's pane\" and\n\"there is no caller\" are different answers and an agent acts differently on\neach.",
        "oneOf": [
          {
            "const": "unknown",
            "description": "This process is not running inside tmux, so no pane is its own.",
            "type": "string"
          },
          {
            "const": "self",
            "description": "Confirmed: the same tmux server, and the same pane.",
            "type": "string"
          },
          {
            "const": "other",
            "description": "Some other pane, or a pane this crate cannot prove is the caller's.",
            "type": "string"
          }
        ]
      }
    },
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "properties": {
      "content": {
        "description": "What the pane is showing.",
        "type": "string"
      },
      "cursor_x": {
        "description": "Where the cursor sits, counting from the left.",
        "minimum": 0,
        "type": [
          "integer",
          "null"
        ]
      },
      "cursor_y": {
        "description": "Where the cursor sits, counting from the top.",
        "minimum": 0,
        "type": [
          "integer",
          "null"
        ]
      },
      "dead": {
        "description": "Whether the process in it has ended.",
        "type": "boolean"
      },
      "dropped": {
        "description": "How many older lines were dropped to honour `max_lines`.",
        "minimum": 0,
        "type": "integer"
      },
      "height": {
        "description": "How tall it is, in rows.",
        "minimum": 0,
        "type": "integer"
      },
      "in_mode": {
        "description": "Whether the pane is in a mode, where keys navigate rather than type.",
        "type": "boolean"
      },
      "lines": {
        "description": "How many lines of it are reported.",
        "minimum": 0,
        "type": "integer"
      },
      "mode": {
        "description": "Which mode, when it is in one.",
        "type": [
          "string",
          "null"
        ]
      },
      "pane": {
        "$ref": "#/$defs/PaneView",
        "description": "The pane itself."
      },
      "scroll_position": {
        "description": "How far it is scrolled back, when it is in copy mode.",
        "format": "int32",
        "type": [
          "integer",
          "null"
        ]
      },
      "width": {
        "description": "How wide it is, in columns.",
        "minimum": 0,
        "type": "integer"
      }
    },
    "required": [
      "pane",
      "width",
      "height",
      "in_mode",
      "dead",
      "content",
      "lines",
      "dropped"
    ],
    "type": "object"
  },
  "annotations": {
    "destructiveHint": false,
    "idempotentHint": true,
    "openWorldHint": true,
    "readOnlyHint": true,
    "title": "Snapshot Pane State"
  },
  "meta": {
    "anthropic/alwaysLoad": true,
    "com.git-pull.libtmux-mcp/capability": {
      "amplifiesFutureInput": false,
      "inputLiteralization": {},
      "mayExposeSecrets": true,
      "mayReturnUntrustedContent": true,
      "nestedAuthority": [],
      "outputClasses": [
        "tmux-metadata",
        "terminal-content"
      ],
      "processReach": "none",
      "tmuxEffects": [
        "observe"
      ],
      "toolset": "inspect"
    }
  }
}
