execute_terminal
Send one bounded command through Core to one exact Server, container, named service of a Server-backed Stack, or Server-backed Deployment. Requires independent KOMODO_ALLOW_TERMINAL=true plus operate, and Core Read + Terminal; container identity additionally needs Inspect. Creates a fresh private 90-second shell, never attaches/recreates, streams once, and checks owned cleanup even after cancellation. No Swarm tasks, persistent state, replay or update ID. A spoofable upstream exit marker is reported separately from removal/termination uncertainty. Core/Periphery may record commands; arbitrary output cannot be guaranteed secret-free.
Availability
KOMODO_ALLOW_OPERATE=true and KOMODO_ALLOW_TERMINAL=true
The instance’s tool selection and upstream Core permissions also apply. Some inputs require additional grants.
Effect annotations
readOnlyHint—falsedestructiveHint—trueidempotentHint—false
Inputs
The registered schema gives field types, alternatives and declared bounds. The description and operator guides also cover checks applied at runtime.
command- Required ·
type "string" max_output_bytestype "integer"·minimum 0·default 4096observation_secondstype "integer"·minimum 0·default 15target- Required · Schema
Target
Show input JSON Schema
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false,
"properties": {
"command": {
"type": "string"
},
"max_output_bytes": {
"default": 4096,
"format": "uint",
"minimum": 0,
"type": "integer"
},
"observation_seconds": {
"default": 15,
"format": "uint64",
"minimum": 0,
"type": "integer"
},
"target": {
"$ref": "#/$defs/Target"
}
},
"required": [
"target",
"command"
],
"$defs": {
"ContainerSelector": {
"anyOf": [
{
"additionalProperties": false,
"properties": {
"id": {
"type": "string"
}
},
"required": [
"id"
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"name": {
"type": "string"
}
},
"required": [
"name"
],
"type": "object"
}
]
},
"DetailInput": {
"additionalProperties": false,
"oneOf": [
{
"required": [
"id"
]
},
{
"required": [
"name"
]
}
],
"properties": {
"id": {
"description": "Exact stable resource ID returned by a list tool.",
"pattern": "^[0-9a-fA-F]{24}$",
"type": "string"
},
"name": {
"description": "Exact, case-sensitive name within this family; never interpreted as an ID.",
"minLength": 1,
"pattern": "\\S",
"type": "string"
}
},
"type": "object"
},
"Target": {
"oneOf": [
{
"additionalProperties": false,
"properties": {
"kind": {
"const": "server",
"type": "string"
},
"target": {
"$ref": "#/$defs/DetailInput"
}
},
"required": [
"kind",
"target"
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"container": {
"$ref": "#/$defs/ContainerSelector"
},
"kind": {
"const": "container",
"type": "string"
},
"server": {
"$ref": "#/$defs/DetailInput"
}
},
"required": [
"kind",
"server",
"container"
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"kind": {
"const": "stack",
"type": "string"
},
"service": {
"type": "string"
},
"target": {
"$ref": "#/$defs/DetailInput"
}
},
"required": [
"kind",
"target",
"service"
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"kind": {
"const": "deployment",
"type": "string"
},
"target": {
"$ref": "#/$defs/DetailInput"
}
},
"required": [
"kind",
"target"
],
"type": "object"
}
]
}
}
}Output
This tool omits outputSchema in discovery. The shape below comes from its Rust result and tool error types.
Outputattempts,cleanup,duration_ms,limitations,observation,remote_shell_lifetime_seconds,target,terminalAppErrorcandidates,correction,field,kind,message,operation,status
Show output JSON Schema
{
"type": "object",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"anyOf": [
{
"$ref": "#/$defs/Output"
},
{
"$ref": "#/$defs/AppError"
}
],
"$defs": {
"AppError": {
"additionalProperties": false,
"description": "Only application-owned messages and selected, nonsensitive metadata survive.",
"properties": {
"candidates": {
"items": {
"$ref": "#/$defs/Candidate"
},
"type": [
"array",
"null"
]
},
"correction": {
"type": [
"string",
"null"
]
},
"field": {
"type": [
"string",
"null"
]
},
"kind": {
"$ref": "#/$defs/ErrorKind"
},
"message": {
"type": "string"
},
"operation": {
"type": "string"
},
"status": {
"format": "uint16",
"maximum": 65535,
"minimum": 0,
"type": [
"integer",
"null"
]
}
},
"required": [
"kind",
"message",
"operation"
],
"type": "object"
},
"Candidate": {
"additionalProperties": false,
"description": "A bounded ambiguity hint, never a raw upstream resource.",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
],
"type": "object"
},
"ErrorKind": {
"description": "Stable public categories. No variant contains a raw upstream error.",
"enum": [
"invalid_arguments",
"not_found",
"ambiguous_target",
"incomplete_resolution",
"configuration",
"authentication",
"permission_denied",
"timeout",
"unreachable",
"upstream",
"invalid_response",
"response_too_large",
"capability_disabled",
"unsupported_target",
"stale_preview",
"invalid_preview"
],
"type": "string"
},
"Observation": {
"properties": {
"end": {
"type": "string"
},
"error_kind": {
"anyOf": [
{
"$ref": "#/$defs/ErrorKind"
},
{
"type": "null"
}
]
},
"output": {
"type": [
"string",
"null"
]
},
"output_truncated": {
"type": "boolean"
},
"reported_exit_code": {
"format": "uint8",
"maximum": 255,
"minimum": 0,
"type": [
"integer",
"null"
]
}
},
"required": [
"end",
"reported_exit_code",
"output",
"output_truncated",
"error_kind"
],
"type": "object"
},
"Output": {
"properties": {
"attempts": {
"additionalProperties": {
"format": "uint",
"minimum": 0,
"type": "integer"
},
"description": "Counts of create, command and delete attempts.",
"type": "object"
},
"cleanup": {
"additionalProperties": true,
"description": "Owned cleanup state with the observed reason or evidence of absence.",
"type": "object"
},
"duration_ms": {
"format": "uint128",
"minimum": 0,
"type": "integer"
},
"limitations": {
"items": {
"type": "string"
},
"type": "array"
},
"observation": {
"$ref": "#/$defs/Observation"
},
"remote_shell_lifetime_seconds": {
"format": "uint64",
"minimum": 0,
"type": "integer"
},
"target": {
"additionalProperties": true,
"description": "The resolved Core terminal target, identifying one server or container.",
"type": "object"
},
"terminal": {
"type": "string"
}
},
"required": [
"target",
"terminal",
"observation",
"cleanup",
"attempts",
"duration_ms",
"remote_shell_lifetime_seconds",
"limitations"
],
"type": "object"
}
}
}