Tree
treeRender a directory tree with bounded recursion. Control depth, hidden files, ignored items, and file sizes. Returns ASCII and structured JSON for filesystem navigation.
Instructions
Render a directory tree (bounded recursion). Returns ASCII tree + structured JSON. maxDepth=0 returns only the root node.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Base directory (default: root). Absolute path required if multiple roots. | |
| maxDepth | No | Depth (0=root node only, no children). Default: 5 | |
| maxEntries | No | Max entries. Default: 1000 | |
| includeHidden | No | Include hidden items (starting with .) | |
| includeIgnored | No | Include ignored items. Disables .gitignore. | |
| includeSizes | No | Include file sizes in tree entries |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| root | No | ||
| tree | No | ||
| ascii | No | ||
| truncated | No | ||
| totalEntries | No |