Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

paste_text

Paste multi-line text into a pane using tmux paste buffers.

Uses tmux’s load-buffer and paste-buffer for clean multi-line input, avoiding the issues of sending text line-by-line via send_keys. Supports bracketed paste mode for terminals that handle it.

When to use this vs. load_buffer + paste_buffer: paste_text is the fire-and-forget path — the buffer is created, pasted, and deleted in one call. Use load_buffer + paste_buffer when you need to stage content first, paste it into multiple panes, or inspect it with show_buffer before pasting.

All Python tools · JSON · Source

Arguments

bracket optional · boolean
Whether to use bracketed paste mode. Default True. Bracketed paste wraps the text in escape sequences that tell the terminal "this is pasted text, not typed input".

Default: true.

pane_id optional
Pane ID (e.g. '%1').

Default: null.

session_id optional
Session ID for pane resolution.

Default: null.

session_name optional
Session name for pane resolution.

Default: null.

socket_name optional
tmux socket name.

Default: null.

text required · string
The text to paste.
window_id optional
Window ID for pane resolution.

Default: null.

Schemas

The schema defines required fields, nested values, defaults, and validation constraints.

Input schema
{
"additionalProperties": false,
"properties": {
"bracket": {
"default": true,
"description": "Whether to use bracketed paste mode. Default True.\nBracketed paste wraps the text in escape sequences that tell\nthe terminal \"this is pasted text, not typed input\".",
"type": "boolean"
},
"pane_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Pane ID (e.g. '%1')."
},
"session_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Session ID for pane resolution."
},
"session_name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Session name for pane resolution."
},
"socket_name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "tmux socket name."
},
"text": {
"description": "The text to paste.",
"type": "string"
},
"window_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Window ID for pane resolution."
}
},
"required": [
"text"
],
"type": "object"
}
Output schema
{
"properties": {
"result": {
"type": "string"
}
},
"required": [
"result"
],
"type": "object",
"x-fastmcp-wrap-result": true
}
Tool annotations
{
"destructiveHint": true,
"idempotentHint": false,
"openWorldHint": true,
"readOnlyHint": false
}
Esc

Type to search.