List Directory
list_directoryLists files and directories directly inside an allowed path, marking each entry as [FILE] or [DIR] so you can inspect directory contents.
Instructions
List the files and directories directly inside a path, each marked [FILE] or [DIR]. Use it to see what a directory contains; when you also need each entry's size or want entries sorted by size, use list_directory_with_sizes instead, and for a recursive view use directory_tree. Returns one line per entry. Only works within allowed directories.
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": {
"path": "<path>"
},
"name": "list_directory"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The directory to list. Absolute, or relative to an allowed directory; it must resolve inside the allowed directories. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| content | Yes |