MCPconceptTools

Choose documentation 3

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

MoreLess about this notice

Concept example A working example of the core library. It can change without notice. What concept means

tool MCP

create_session

create_session( height?: integer | null, name?: string | null, startDirectory?: string | null, width?: integer | null, )

Start a pane’s configured process; accepts no command payload. Create a detached tmux session and return its ids. Give a width and height when nothing will attach to it: a session with no client keeps tmux’s default 80x24, which truncates wide output.

MCP request method
tools/call Send create_session as the tool name, with the arguments below.
Wraps
LibTmux.Server.CreateSessionAsyncThe library call this tool makes: src/LibTmux.Mcp/Tools/WriteTools.Layout.cs:34.

Arguments

  • height? = null (integer | null)

    Rows. Omit for tmux’s default of 24.

    minimum
    -2147483648
    maximum
    2147483647
  • name? = null (string | null)

    The session name. Omit and tmux names it with a number.

  • startDirectory? = null (string | null)

    The literal starting directory. Omit for the MCP server’s own working directory.

  • width? = null (integer | null)

    Columns. Omit for tmux’s default of 80.

    minimum
    -2147483648
    maximum
    2147483647

No other arguments are accepted.

Result

Returns object

Annotations

Advertised by the server

destructiveHint
true
idempotentHint
false
openWorldHint
true
readOnlyHint
false
title
"Create session"

Capability

Toolset
Execute Start or drive pane processes, or store state that can control later execution.
Process reach
configured-process
tmux effects
change observe

Every C# tool advertises the same annotations, so a host that approves by annotation cannot tell tools apart. The capability row is what tells them apart.

Protocol data

Use the complete advertised contract for validation and client integration.

Input schema
{
"additionalProperties": false,
"properties": {
"height": {
"default": null,
"description": "Rows. Omit for tmux's default of 24.",
"maximum": 2147483647,
"minimum": -2147483648,
"type": [
"integer",
"null"
]
},
"name": {
"default": null,
"description": "The session name. Omit and tmux names it with a number.",
"type": [
"string",
"null"
]
},
"startDirectory": {
"default": null,
"description": "The literal starting directory. Omit for the MCP server's own working directory.",
"type": [
"string",
"null"
]
},
"width": {
"default": null,
"description": "Columns. Omit for tmux's default of 80.",
"maximum": 2147483647,
"minimum": -2147483648,
"type": [
"integer",
"null"
]
}
},
"type": "object"
}
Output schema
{
"properties": {
"changed": {
"type": "string"
},
"paneId": {
"default": null,
"type": [
"string",
"null"
]
},
"sessionId": {
"default": null,
"type": [
"string",
"null"
]
},
"windowId": {
"default": null,
"type": [
"string",
"null"
]
}
},
"required": [
"changed"
],
"type": "object"
}
Esc
Search in

Type to search.

Reference previewOpen reference