Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tasks | {
"list": {},
"cancel": {},
"requests": {
"tools": {
"call": {}
}
}
} |
| tools | {
"listChanged": true
} |
| logging | {} |
| prompts | {
"listChanged": true
} |
| resources | {
"listChanged": true
} |
| completions | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| roots | List allowed workspace roots. Call first — all other tools are scoped to these directories. |
| ls | List immediate directory contents (non-recursive): name, path, type, size, modified date. Omit path for workspace root. |
| find | Find files by glob pattern (e.g. |
| tree | Render a directory tree (bounded recursion). Returns ASCII tree + structured JSON. |
| read | Read text file contents. Use |
| read_many | Read multiple text files in one request with contents and metadata. For a single file, use |
| stat | Get file/directory metadata: size, modified, permissions, mime, tokenEstimate. Use |
| stat_many | Get metadata for multiple files/directories in one request. Use |
| grep | Search file contents for text (grep-like). Returns matching lines. Scope with |
| mkdir | Create a new directory at the specified path (recursive). |
| write | Write content to a file, OVERWRITING ALL existing content. Creates the file and parent directories if needed. |
| edit | Apply sequential literal string replacements to a file (first occurrence per edit). |
| mv | Move or rename a file or directory. |
| rm | Permanently delete a file or directory. This action is irreversible. |
| calculate_hash | Calculate SHA-256 hash of a file or directory. |
| diff_files | Generate a unified diff between two files. Output feeds directly into |
| apply_patch | Apply a unified diff patch to one or more files. Single-file: throws on failure. Multi-file: best-effort per file with |
| search_and_replace | Bulk search-and-replace across files matching a glob. Replaces ALL occurrences per file (unlike |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| get-help | Return filesystem-mcp usage instructions. |
| compare-files | Generate a workflow for comparing two files using diff_files. |
| analyze-path | Generate a workflow for analyzing a file or directory using stat, read, and tree. |
| get-tool-help | Return a prompt with the authoritative contract for a specific filesystem-mcp tool. |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| filesystem-mcp-instructions | Comprehensive rules and guidelines for filesystem-mcp usage. |
| filesystem-mcp-catalog | Tool selection guide and data flow map. |
| filesystem-mcp-workflows | Standard operating procedures for exploration, search, edit, and patch. |
| filesystem-mcp-metrics | Live per-tool call/error/avgDurationMs metrics snapshot. |
| roots | List allowed workspace roots. Call first — all other tools are scoped to these directories. |
| ls | List immediate directory contents (non-recursive): name, path, type, size, modified date. Omit path for workspace root. `includeIgnored=true` for node_modules etc. For recursive search, use `find`. |
| find | Find files by glob pattern (e.g. `**/*.ts`). Returns matching files with metadata. For content search, use `grep`. For bulk edits, pass the same glob to `search_and_replace`. |
| tree | Render a directory tree (bounded recursion). Returns ASCII tree + structured JSON. `maxDepth=0` returns only the root node. |
| read | Read text file contents. Use `head` to preview first N lines of large files. For multiple files, use `read_many`. |
| read_many | Read multiple text files in one request with contents and metadata. For a single file, use `read`. |
| stat | Get file/directory metadata: size, modified, permissions, mime, tokenEstimate. Use `tokenEstimate` (size÷4) to pre-screen token cost before reading. |
| stat_many | Get metadata for multiple files/directories in one request. Use `tokenEstimate` (size÷4) to pre-screen token cost before reading. |
| grep | Search file contents for text (grep-like). Returns matching lines. Scope with `filePattern` (e.g. `**/*.ts`) to reduce noise. `includeHidden=true` for dotfiles. |
| mkdir | Create a new directory at the specified path (recursive). |
| write | Write content to a file, OVERWRITING ALL existing content. Creates the file and parent directories if needed. |
| edit | Apply sequential literal string replacements to a file (first occurrence per edit). `oldText` must match exactly — include 3–5 lines of context for unique targeting. Use `dryRun:true` to preview. |
| mv | Move or rename a file or directory. |
| rm | Permanently delete a file or directory. This action is irreversible. |
| calculate_hash | Calculate SHA-256 hash of a file or directory. |
| diff_files | Generate a unified diff between two files. Output feeds directly into `apply_patch`. `isIdentical=true` means files match — no patch needed. |
| apply_patch | Apply a unified diff patch to one or more files. Single-file: throws on failure. Multi-file: best-effort per file with `results[]`. Workflow: `diff_files` → `apply_patch(dryRun:true)` → `apply_patch`. On failure, regenerate the patch from current file content. |
| search_and_replace | Bulk search-and-replace across files matching a glob. Replaces ALL occurrences per file (unlike `edit`: first only). Always `dryRun:true` first — returns a unified diff. Literal matching by default; `isRegex:true` enables RE2 with capture groups ($1, $2). |