List Workspace
list_workspaceLists files and folders in a Jenkins job's current workspace on the agent for a given build, including non-archived files and pipeline node-specific workspaces.
Instructions
Files in a job's workspace (folders end with '/'), for files that were not archived (e.g. app-queue.log).
Pipeline: the workspace of a node block of the build; with several blocks it lists them first.
Shows the CURRENT state on the agent. Needs the Job/Workspace permission and a reachable agent.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"job": "<job>"
},
"name": "list_workspace"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| job | Yes | Job full name like 'cd/master/my-app' (folders separated by '/'), or a Jenkins job/build URL (instance is then detected from the URL). | |
| path | No | Folder inside the workspace; empty = root | |
| build | No | Build number or permalink: lastBuild, lastFailedBuild, lastSuccessfulBuild, lastCompletedBuild, lastUnsuccessfulBuild. Empty = build from the URL, else lastBuild. | |
| node_id | No | Pipeline only: workspace of which node block (node_id from list_workspace); empty = the only one | |
| instance | No | Jenkins instance name from list_instances. Empty = default instance. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||