apply_patchStage, validate, and atomically apply a patch envelope. Example: *** Begin Patch
*** Update File: app.py
@@
-old
+new
*** End PatchInput schema{
"type": "object",
"properties": {
"patch": {
"type": "string",
"minLength": 1
},
"dry_run": {
"type": "boolean",
"default": false
}
},
"required": [
"patch"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Apply patch",
"readOnlyHint": false,
"destructiveHint": true,
"idempotentHint": false,
"openWorldHint": false
} | — | WritesDestructiveNon-idempotentClosed world | — |
check_exec_environmentReturn lightweight exec_command sandbox and environment status known to the server.Input schema{
"type": "object",
"properties": {},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Check exec environment",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
exec_commandRun a bounded command under runtime policy. Pass workdir explicitly for reconnect-safe paths. A still-running command returns command_id. Example: {"cmd":"pytest -q","workdir":".","yield_time_ms":30000}. Retained output is bounded per stream; for very large output redirect to a file (cmd > out.log 2>&1) and page it with read_file or search_text.Input schema{
"type": "object",
"properties": {
"cmd": {
"type": "string",
"minLength": 1
},
"workdir": {
"type": "string",
"default": "."
},
"cwd": {
"type": "string"
},
"timeout_ms": {
"type": "integer",
"minimum": 1,
"maximum": 600000,
"default": 30000
},
"yield_time_ms": {
"type": "integer",
"minimum": 0,
"maximum": 30000,
"default": 10000
},
"max_output_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 65536
},
"verbosity": {
"type": "string",
"enum": [
"summary",
"preview",
"full"
]
},
"preview_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 4096
},
"stdin": {
"type": "string",
"default": ""
},
"tty": {
"type": "boolean",
"default": false
},
"env": {
"type": "object",
"additionalProperties": {
"type": "string"
},
"default": {}
}
},
"required": [
"cmd"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Execute command",
"readOnlyHint": false,
"destructiveHint": true,
"idempotentHint": false,
"openWorldHint": true
} | — | WritesDestructiveNon-idempotentOpen world | — |
git_blameReturn bounded git blame metadata for a workspace file.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1
},
"rev": {
"type": "string"
},
"start_line": {
"type": "integer",
"minimum": 1,
"default": 1
},
"end_line": {
"type": "integer",
"minimum": 1
},
"max_lines": {
"type": "integer",
"minimum": 1,
"maximum": 1000,
"default": 200
}
},
"required": [
"path"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Git blame",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
git_diffReturn unified git diff for workspace changes.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string"
},
"paths": {
"type": "array",
"items": {
"type": "string"
}
},
"staged": {
"type": "boolean",
"default": false
},
"unstaged": {
"type": "boolean",
"default": true
},
"context_lines": {
"type": "integer",
"minimum": 0,
"maximum": 20,
"default": 3
},
"max_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 262144
}
},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Git diff",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
git_logReturn recent git commits with bounded structured metadata.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"default": "."
},
"ref": {
"type": "string",
"default": "HEAD"
},
"max_count": {
"type": "integer",
"minimum": 1,
"maximum": 100,
"default": 20
},
"skip": {
"type": "integer",
"minimum": 0,
"maximum": 10000,
"default": 0
}
},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Git log",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
git_showReturn bounded git show output for a revision.Input schema{
"type": "object",
"properties": {
"rev": {
"type": "string",
"default": "HEAD"
},
"path": {
"type": "string"
},
"paths": {
"type": "array",
"items": {
"type": "string"
}
},
"include_diff": {
"type": "boolean",
"default": true
},
"context_lines": {
"type": "integer",
"minimum": 0,
"maximum": 20,
"default": 3
},
"max_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 262144
}
},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Git show",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
git_statusReturn git working tree status for the workspace.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"default": "."
},
"include_untracked": {
"type": "boolean",
"default": true
},
"max_entries": {
"type": "integer",
"minimum": 1,
"maximum": 10000,
"default": 1000
}
},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Git status",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
kill_commandTerminate a server-managed command by command_id. Example: {"command_id":"abc","signal":"KILL"}.Input schema{
"type": "object",
"properties": {
"command_id": {
"type": "string",
"minLength": 1
},
"signal": {
"type": "string",
"enum": [
"TERM",
"KILL",
"INT"
],
"default": "TERM"
},
"wait_ms": {
"type": "integer",
"minimum": 0,
"maximum": 30000,
"default": 5000
},
"kill_wait_ms": {
"type": "integer",
"minimum": 0,
"maximum": 30000,
"default": 2000
},
"max_output_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 65536
},
"verbosity": {
"type": "string",
"enum": [
"summary",
"preview",
"full"
]
},
"preview_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 4096
}
},
"required": [
"command_id"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Kill command",
"readOnlyHint": false,
"destructiveHint": true,
"idempotentHint": false,
"openWorldHint": false
} | — | WritesDestructiveNon-idempotentClosed world | — |
list_dirList directory entries inside the configured workspace.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"default": "."
},
"recursive": {
"type": "boolean",
"default": false
},
"max_depth": {
"type": "integer",
"minimum": 1,
"maximum": 20,
"default": 1
},
"max_entries": {
"type": "integer",
"minimum": 1,
"maximum": 10000,
"default": 1000
},
"include_hidden": {
"type": "boolean",
"default": false
},
"include_ignored": {
"type": "boolean",
"default": false
},
"sort": {
"type": "string",
"enum": [
"name",
"type",
"modified"
],
"default": "name"
}
},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "List directory",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
list_filesList workspace files using glob filters.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"default": "."
},
"patterns": {
"type": "array",
"items": {
"type": "string"
}
},
"glob": {
"type": "string"
},
"exclude_patterns": {
"type": "array",
"items": {
"type": "string"
}
},
"include_hidden": {
"type": "boolean",
"default": false
},
"include_ignored": {
"type": "boolean",
"default": false
},
"max_results": {
"type": "integer",
"minimum": 1,
"maximum": 50000,
"default": 5000
},
"sort": {
"type": "string",
"enum": [
"path",
"modified"
],
"default": "path"
}
},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "List files",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
read_fileRead a UTF-8 text file slice inside the configured workspace.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1
},
"start_line": {
"type": "integer",
"minimum": 1,
"default": 1
},
"end_line": {
"type": "integer",
"minimum": 1
},
"max_lines": {
"type": "integer",
"minimum": 1
},
"max_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 131072
},
"encoding": {
"type": "string",
"enum": [
"utf-8"
],
"default": "utf-8"
}
},
"required": [
"path"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Read file",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
read_outputRead retained command output using an output_ref returned by exec_command/write_stdin. Each stream retains the earliest output (head) plus the most recent output (rolling tail); bytes between them may be evicted and are reported via evicted_gap_bytes. Example: {"output_ref":"command:abc:stdout","offset":0,"limit":4096}.Input schema{
"type": "object",
"properties": {
"output_ref": {
"type": "string",
"minLength": 1
},
"stream": {
"type": "string",
"enum": [
"stdout",
"stderr"
]
},
"offset": {
"type": "integer",
"minimum": 0,
"default": 0
},
"limit": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 4096
}
},
"required": [
"output_ref"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Read output",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
request_permissionsReport scoped permission-request status without silently granting operations.Input schema{
"type": "object",
"properties": {
"tool_name": {
"type": "string",
"enum": [
"exec_command",
"apply_patch"
]
},
"permission": {
"type": "string",
"enum": [
"network",
"destructive_command",
"long_timeout",
"sensitive_env",
"shell_expansion",
"inline_script",
"privileged_executable",
"write_generated_or_ignored"
]
},
"reason": {
"type": "string",
"minLength": 1
},
"arguments": {
"type": "object",
"additionalProperties": true
},
"scope": {
"type": "string",
"enum": [
"once",
"session"
],
"default": "once"
},
"ttl_seconds": {
"type": "integer",
"minimum": 1,
"maximum": 3600,
"default": 300
}
},
"required": [
"tool_name",
"permission",
"reason",
"arguments"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Request permissions",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": false,
"openWorldHint": false
} | — | Read onlyNon-destructiveNon-idempotentClosed world | — |
search_textSearch UTF-8 workspace files for text or regex matches.Input schema{
"type": "object",
"properties": {
"query": {
"type": "string",
"minLength": 1
},
"path": {
"type": "string",
"default": "."
},
"regex": {
"type": "boolean",
"default": false
},
"case_sensitive": {
"type": "boolean",
"default": false
},
"include_globs": {
"type": "array",
"items": {
"type": "string"
}
},
"glob": {
"type": "string"
},
"exclude_globs": {
"type": "array",
"items": {
"type": "string"
}
},
"context_lines": {
"type": "integer",
"minimum": 0,
"maximum": 5,
"default": 0
},
"max_results": {
"type": "integer",
"minimum": 1,
"maximum": 10000,
"default": 1000
},
"max_preview_bytes": {
"type": "integer",
"minimum": 80,
"maximum": 4096,
"default": 512
}
},
"required": [
"query"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Search text",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
server_infoReturn server, workspace, project-context, auth, policy, and fixed-tool metadata.Input schema{
"type": "object",
"properties": {},
"required": [],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Server info",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
view_imageReturn a workspace image as MCP image content.Input schema{
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1
},
"max_bytes": {
"type": "integer",
"minimum": 1024,
"maximum": 10485760,
"default": 5242880
},
"max_width": {
"type": "integer",
"minimum": 1,
"maximum": 10000,
"default": 2000
},
"max_height": {
"type": "integer",
"minimum": 1,
"maximum": 10000,
"default": 2000
},
"auto_resize": {
"type": "boolean",
"default": true
}
},
"required": [
"path"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "View image",
"readOnlyHint": true,
"destructiveHint": false,
"idempotentHint": true,
"openWorldHint": false
} | — | Read onlyNon-destructiveIdempotentClosed world | — |
write_stdinPoll or interact with a running command by command_id. Empty chars wait for output; non-empty chars writes to stdin. Example: {"command_id":"abc","chars":"","yield_time_ms":10000}.Input schema{
"type": "object",
"properties": {
"command_id": {
"type": "string",
"minLength": 1
},
"chars": {
"type": "string",
"default": ""
},
"yield_time_ms": {
"type": "integer",
"minimum": 0,
"maximum": 30000,
"default": 10000
},
"max_output_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 65536
},
"verbosity": {
"type": "string",
"enum": [
"summary",
"preview",
"full"
]
},
"preview_bytes": {
"type": "integer",
"minimum": 1,
"maximum": 1048576,
"default": 4096
}
},
"required": [
"command_id"
],
"additionalProperties": false
}Output schema{
"type": "object",
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"category": {
"type": "string"
},
"retryable": {
"type": "boolean"
},
"details": {
"type": "object",
"additionalProperties": true
}
},
"required": [
"code",
"message",
"category",
"retryable",
"details"
],
"additionalProperties": true
}
},
"required": [
"ok"
],
"additionalProperties": true
}Annotations{
"title": "Write stdin",
"readOnlyHint": false,
"destructiveHint": false,
"idempotentHint": false,
"openWorldHint": false
} | — | WritesNon-destructiveNon-idempotentClosed world | — |