MCPpre-alphaTools

Choose documentation 3

stable

Current version

stable
English

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

tool MCPstable

set_environment

Set a tmux environment variable.

Use to set variables that will be inherited by new panes and windows. Changes do not affect already-running processes.

Some variables control later shell execution. Bash sources the file named by BASH_ENV, POSIX shells may source the file named by ENV, and Bash evaluates PROMPT_COMMAND before displaying a prompt.

MCP request method
tools/call Send set_environment as the tool name, with the arguments below.

Arguments#

No other arguments are accepted.

Result#

Returns object

Annotations#

destructiveHint
true
idempotentHint
false
openWorldHint
true
readOnlyHint
false

Protocol data#

Use the complete advertised contract for validation and client integration.

Input schema
{
"additionalProperties": false,
"properties": {
"name": {
"description": "Environment variable name.",
"type": "string"
},
"session_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Session ID to set environment for."
},
"session_name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Session name to set environment for."
},
"socket_name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "tmux socket name."
},
"value": {
"description": "Environment variable value.",
"type": "string"
}
},
"required": [
"name",
"value"
],
"type": "object"
}
Output schema
{
"description": "Result of a set_environment call.",
"properties": {
"name": {
"description": "Variable name",
"type": "string"
},
"status": {
"description": "Operation status",
"type": "string"
},
"value": {
"description": "Value that was set",
"type": "string"
}
},
"required": [
"name",
"value",
"status"
],
"type": "object"
}
Esc

Type to search.

Reference preview Open reference