xserver-files-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@xserver-files-mcplist files on example.com"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
xserver-files-mcp
XServer のファイル操作を SFTP 経由で安全に行うローカル stdio MCP サーバー & CLI。
前提条件: Node.js 20+、SSH アクセスが有効な XServer アカウント。
セットアップガイド
以下の手順を上から順に進めてください。AI エージェント(Claude Code、Codex など)に依頼する場合も、この手順に沿って自動実行されます。[要ユーザー操作] のマークがあるステップのみ人間の操作が必要です。
Step 1: インストール
git clone https://github.com/mocchalera/xserver-files-mcp.git
cd xserver-files-mcp
npm install動作確認(サーバー接続不要):
XSERVER_FILES_CONFIG=config/example.config.json node src/cli.js serversStep 2: XServer の情報を確認 [要ユーザー操作]
設定ファイルを作成するために、以下の情報が必要です。XServer サーバーパネル(https://secure.xserver.ne.jp/xapanel/login/xserver/server/)にログインして確認してください。
必要な情報 | 確認場所 | 例 |
サーバー ID | サーバーパネル上部に表示 |
|
ホスト名 | サーバー情報 → ホスト名 |
|
操作対象のドメイン | ドメイン設定 → ドメイン一覧 |
|
ドキュメントルート | ドメイン設定 → ドメイン一覧の「ドキュメントルート」列 |
|
ヒント: XServer のドキュメントルートは通常
/home/<サーバーID>/<ドメイン>/public_htmlの形式です。
Step 3: 設定ファイルの作成
mkdir -p ~/.config/xserver-files-mcp
cp config/example.config.json ~/.config/xserver-files-mcp/config.json~/.config/xserver-files-mcp/config.json を Step 2 で確認した情報に書き換えます:
{
"defaultServer": "<サーバーID>",
"localWorkspaceRoot": "~/Dev/xserver-sites",
"servers": {
"<サーバーID>": {
"host": "<サーバーID>.xsrv.jp",
"port": 10022,
"username": "<サーバーID>",
"privateKeyPath": "~/.ssh/xserver_<サーバーID>",
"roots": {
"<ドメイン>": "/home/<サーバーID>/<ドメイン>/public_html"
}
}
}
}localWorkspaceRoot はサイトファイルの pull 先です。このリポジトリの外であれば任意のパスで構いません。
Step 4: SSH 鍵の作成
ssh-keygen -t ed25519 -f ~/.ssh/xserver_<サーバーID> -C xserver-<サーバーID>パスフレーズを設定した場合は、設定ファイルの passphraseEnv にパスフレーズを格納する環境変数名を指定し、その環境変数にパスフレーズを設定してください。
Step 5: SSH 公開鍵を XServer に登録 [要ユーザー操作]
この操作は XServer サーバーパネルで手動で行う必要があります。
公開鍵の内容を確認:
cat ~/.ssh/xserver_<サーバーID>.pubXServer サーバーパネルにログイン
「SSH設定」 を開く
SSH 設定が 「ON」 になっていることを確認(OFF なら ON に変更)
「公開鍵登録・更新」 タブを開く
上記の公開鍵の内容を全文貼り付けて 「確認画面へ進む」 → 「登録する」
Step 6: 接続テスト
ssh -p 10022 -i ~/.ssh/xserver_<サーバーID> <サーバーID>@<サーバーID>.xsrv.jp 'pwd'Step 7: doctor で最終確認
node src/cli.js doctorすべて [PASS] になればセットアップ完了です。
トラブルシューティング
doctor の出力 | 原因 | 対処 |
| 設定ファイルが見つからないか JSON が不正 |
|
| 秘密鍵ファイルが見つからない | Step 4 の鍵作成を確認。パスが設定ファイルの |
| SSH 接続に失敗 | Step 5 の公開鍵登録を確認。 |
Related MCP server: mcp_shell_tools
MCP 登録
Claude Code でこのリポジトリを開くと .mcp.json により自動登録されます。
他の MCP クライアント(Claude Desktop、VS Code など)では、設定に以下を追加:
{
"mcpServers": {
"xserver-files": {
"command": "node",
"args": ["/絶対パス/xserver-files-mcp/src/server.js"],
"env": {
"XSERVER_FILES_CONFIG": "/ホームディレクトリ/.config/xserver-files-mcp/config.json"
}
}
}
}パスは自分のマシンの絶対パスに置き換えてください。
CLI の使い方
node src/cli.js <command> [options]診断
コマンド | 説明 |
| 設定ファイル、SSH 鍵、SFTP 接続をチェック |
| 設定済みサーバー一覧を表示(接続不要) |
| 設定済みドメインルート一覧を表示 |
| バージョンを表示 |
ファイル操作
コマンド | 説明 |
| リモートファイル一覧 |
| リモートの UTF-8 テキストファイルを読み取り |
| リモートにファイルを書き込み(既存ファイルは自動バックアップ) |
| テキストの完全一致置換(自動バックアップ) |
| タイムスタンプ付きリモートバックアップを作成 |
| ファイルのリモートバックアップ一覧 |
| 古いバックアップを削除し、最新 N 件を保持(デフォルト 5) |
ワークスペース操作
コマンド | 説明 |
| ドメイン用のローカルワークスペースを作成 |
| リモートファイルをローカルワークスペースに取得 |
| ローカルワークスペースのファイルをサーバーに送信(自動バックアップ) |
pull/push は wp-config.php、uploads、logs、backups、データベースダンプ、アーカイブをデフォルトで拒否します。--allow-sensitive はリスクを確認してから使用してください。
リダイレクト
node src/cli.js redirect old-site.example.com https://new-site.example.com --dry-run
node src/cli.js redirect old-site.example.com https://new-site.example.com.htaccess にマーク付き 301 リダイレクトブロックを挿入・更新します:
# BEGIN xserver-files-mcp redirect old-site.example.com
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www\.)?old-site\.example\.com$ [NC]
RewriteRule ^(.*)$ https://new-site.example.com/$1 [R=301,L]
</IfModule>
# END xserver-files-mcp redirect old-site.example.com共通オプション
すべての書き込みコマンドは --dry-run で変更をプレビューできます。--no-backup で自動バックアップをスキップ。--server <id> でデフォルト以外のサーバーを指定。
MCP ツール一覧
ツール | 説明 |
| 設定済みサーバー一覧 |
| プロファイルのドメインルート一覧 |
| ドメイン用のローカルワークスペースを作成 |
| リモートファイル一覧 |
| UTF-8 テキストファイルを読み取り |
| リモートファイルをローカルワークスペースに取得 |
| ローカルワークスペースのファイルをリモートに送信 |
| リモートファイルのタイムスタンプ付きバックアップを作成 |
| UTF-8 ファイルを書き込み(既存ファイルは自動バックアップ) |
| テキストの完全一致置換(自動バックアップ) |
|
|
複数サーバー
設定ファイルの servers にエントリを追加。MCP では server_id、CLI では --server で指定:
node src/cli.js --server sv67890 roots省略時は defaultServer が使われます。
安全性について
すべてのパスは設定済みの
roots[domain]配下で解決されます。絶対パスと..によるトラバーサルは拒否されます。書き込み操作は既存ファイルをデフォルトで自動バックアップします。
pull/push はリスクの高いパスをデフォルトで除外します:
wp-config.php、uploads、logs、backups、SQL ダンプ、アーカイブ。replaceInFileとset_domain_redirectは読み取り・変換・書き込みを別々の SFTP 操作で行います。他のプロセスが同時に同じファイルを編集すると上書きされる可能性があります。書き込み前に必ず
--dry-runで変更をプレビューしてください。秘密鍵はこのプロジェクトディレクトリの外に保管してください。
エージェント向け情報
このリポジトリは公開配布向けに、エージェント手順の正本を skills/ に置いています。
リポジトリ運用ルール:
AGENTS.md初期セットアップスキル:
skills/xserver-files-setup/SKILL.mdSFTP ファイル操作スキル:
skills/xserver-files-operator/SKILL.mdXServer パネル API スキル:
skills/xserver-mcp-operator/SKILL.md
互換性のため、同じスキルを以下の project-local view からも参照できます:
.claude/skills/.agents/skills/.gemini/skills/.cursor/skills/.grok/skills/.antigravity/skills/
Cursor 向けには .cursor/rules/xserver-files.mdc も同梱しています。CLAUDE.md、GEMINI.md、GROK.md、ANTIGRAVITY.md は AGENTS.md と skills/ への薄い入口です。
GitHub から clone した場合は上記 view が symlink として含まれます。npm tarball では symlink view は含めず、skills/ の正本と .agent-support/ の再生成スクリプトを配布します。
agent view を再生成・検証するには:
npm run agent:install
npm run validate:agent-supportsymlink が使えない環境では copy view を生成できます:
npm run agent:install -- --copy --forceAvailable Tools
13 toolsadd_rootAdd domain root to configA
Register a new domain root for a server profile. Infers the remote path from the server username if not specified, verifies the directory exists via SFTP, and saves to the config file.
| Name | Required | Description | Default |
|---|---|---|---|
| root | No | Absolute remote path. Defaults to /home/{username}/{domain}/public_html. | |
| domain | Yes | Domain name to add, e.g. saiyoken.jp. | |
| dry_run | No | Verify without saving to config. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations indicate it is a write operation (readOnlyHint false) but not destructive (destructiveHint false). The description adds key behaviors beyond annotations: it infers the remote path from the server username if not specified, verifies the directory exists via SFTP, and saves to the config file. This gives the agent insight into side effects and failure modes.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence that packs all essential information—purpose, behavioral details, and default behavior—without fluff. Every phrase adds value, making it concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has a relative simple role, the description covers the main operation, default behavior, verification step, and persistence. It does not mention error cases or interaction with existing entries, but the rich schema and annotations reduce the need for exhaustive detail. The description is complete enough for an agent to invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description adds minimal extra meaning for parameters—it mentions the inference of the remote path (relevant to 'root') and verification via SFTP, which enriches the schema but does not significantly change understanding of parameters like 'domain', 'dry_run', or 'server_id'.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 'Register' with a clear resource ('a new domain root') and context ('for a server profile'). It clearly distinguishes itself from sibling tools like list_roots and discover_roots by focusing on the add operation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides clear context: it is for registering a new domain root and verifies the directory existence, implying it is for adding rather than listing or discovering. It does not explicitly name alternatives or exclusions, but the context is sufficient for an agent to infer appropriate use.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
backup_fileBackup remote fileA
Create a timestamped dotfile backup next to a remote file.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path relative to the configured domain root. | |
| label | No | Backup label used in the generated filename. | |
| domain | Yes | Configured domain root to operate under. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=false and destructiveHint=false, so the agent knows this is a write operation that is safe. The description adds that the backup is timestamped and located next to the original file, which is useful behavioral context. However, it does not mention edge cases such as file existence or overwrite behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence that starts with the action verb and conveys the essential information without waste. It is appropriately sized for the tool's simplicity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple two-required-parameter tool with full schema coverage, the description is adequate. It lacks an explicit mention of return values, but no output schema exists, and the behavior is clear enough to invoke the tool correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema descriptions cover all 4 parameters, so the baseline is 3. The tool description does not add any parameter-specific details beyond what the schema already provides.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses the specific verb 'create' and identifies the resource as a 'timestamped dotfile backup' with location 'next to a remote file.' This clearly distinguishes it from sibling read/write/push/pull tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explains what the tool does but does not explicitly state when to use it or when to prefer alternatives. The context is clear (backup creation), but no exclusions or alternative tool references are provided, so it falls short of explicit guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
discover_rootsDiscover domain roots on serverARead-only
Scan the server home directory for domains with public_html and show which ones are not yet configured. Use add_root to register any you want to manage.
| Name | Required | Description | Default |
|---|---|---|---|
| server_id | No | Server profile id. Defaults to config.defaultServer. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and destructiveHint=false; description reinforces with 'scan' and 'show' and adds context about what is inspected (home directory, public_html presence). No contradiction and useful detail about the discovery criteria. Simple read-only tool needs little more.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, front-loaded with action and output, then a clear follow-up pointer. No filler or repetition of schema/annotations.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given one optional parameter, readOnly annotations, and no output schema, the description fully conveys the tool's input, action, and result. It also directs the agent to a sibling tool for the next action. No significant gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Input schema covers the single optional server_id parameter with a description and default behavior, so schema coverage is 100%. Description does not add parameter-level details, but baseline 3 is appropriate since the schema carries the meaning.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Specific verb 'scan' with explicit resource (server home directory, domains with public_html). It contrasts with list_roots by focusing on unconfigured domains, and references add_root as the next step. Clear differentiation from siblings.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides clear context: use to find domains on the server that have public_html but are not yet configured. Recommends add_root for managing discovered domains. Does not explicitly contrast with list_roots or other alternatives, but the context is strong enough.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
init_site_workspaceInitialize local site workspaceA
Create the local workspace directory for a configured domain outside this repository and add a protective .gitignore.
| Name | Required | Description | Default |
|---|---|---|---|
| domain | Yes | Configured domain root to operate under. | |
| dry_run | No | Return paths without creating directories. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. | |
| workspace_root | No | Local workspace root. Defaults to config.localWorkspaceRoot or ~/Dev/xserver-sites. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the annotations (readOnlyHint=false, destructiveHint=false), the description adds that it creates a directory and adds a .gitignore outside the repo. This clarifies the non-destructive write nature without contradicting annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that conveys the verb, resource, scope, and side effect with zero waste.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool is a straightforward initializer; the schema covers all parameters, and the description covers purpose and main side effects. Lacks edge-case behavior (e.g., existing directory) but is adequate given the simplicity and no output schema.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with detailed parameter descriptions, so the description doesn't need to explain parameters. It adds no additional semantic value beyond the schema, earning the baseline 3.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 'Create' with a clear resource: 'local workspace directory' and '.gitignore', scoped to a configured domain outside this repository. This clearly distinguishes it from sibling tools like add_root or file operations.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides clear context: the tool operates on a configured domain and outside this repository, implying a setup step before file tools. It does not explicitly name alternatives or exclusions, so it misses a top score.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_filesList remote filesARead-only
List files under a configured domain root over SFTP.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Path relative to the configured domain root. | . |
| domain | Yes | Configured domain root to operate under. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare the operation as read-only and non-destructive, so the safety bar is lower. The description adds some context about the scope ('configured domain root') and transport ('SFTP'), but does not disclose additional behavioral traits such as recursiveness or return format.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single efficient sentence with no filler. Every word contributes to the core meaning, and it is front-loaded with the primary action.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple list tool with full schema coverage and read-only annotations, the description is mostly complete. However, it does not clarify whether listing is recursive, what metadata is returned, or how the path parameter behaves by default, though the schema covers the default. The lack of output schema means a small gap in expected return behavior.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the baseline is 3. The description does not add any meaning beyond the schema; it only reinforces the domain parameter concept without explaining the other parameters or their interactions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('List') and resource ('files') with the scoping context ('under a configured domain root over SFTP'). This clearly distinguishes it from siblings like read_file (reads a specific file), list_roots (lists roots), and list_servers (lists server profiles).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives, no explicit exclusion scenarios, and no mention of when not to use it. It simply states the function without additional usage context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_rootsList domain rootsARead-only
List configured domain roots for a server profile.
| Name | Required | Description | Default |
|---|---|---|---|
| server_id | No | Server profile id. Defaults to config.defaultServer. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and destructiveHint=false, so safety is covered. The description adds the 'configured' and 'server profile' scoping, but does not disclose return format, ordering, or potential empty results. This is adequate but minimal beyond annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single clear sentence with no filler. It immediately states the action and scope, earning its place efficiently.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple list operation with one optional parameter and good annotation coverage, the description is mostly complete. It could be slightly richer in explaining what 'roots' are or what a successful response contains, but the title and context fill most gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% for the single parameter 'server_id', and the description repeats the role of a server profile without adding extra meaning. Baseline 3 applies because the schema already documents the parameter.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('List') and resource ('configured domain roots') with a clear scope ('for a server profile'). It distinguishes from the sibling tool 'discover_roots' by emphasizing 'configured' roots rather than discovery or scanning.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance is provided about when to use this tool versus alternatives like 'discover_roots' or 'add_root'. The context implies list operations but does not state exclusions or alternative conditions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_serversList configured XServer profilesARead-only
List configured XServer connection profiles and domain roots without connecting to SFTP.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and destructiveHint=false. The description adds the behavioral detail that it does not connect to SFTP, clarifying that it is a purely local, non-network operation, which goes beyond the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that conveys the action, object, and key qualifier without any unnecessary words or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-parameter, read-only listing tool, the description is fully sufficient. It states what is listed, the scope (configured profiles), and the key behavioral nuance (no SFTP connection). The lack of an output schema is not an issue since the purpose is clear.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, and the input schema is an empty object. The description does not need to explain parameters, and the baseline of 4 applies. No additional parameter information is required.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool lists configured XServer connection profiles and domain roots, with the specific qualifier 'without connecting to SFTP.' This distinguishes it from sibling tools like list_roots or discover_roots, which might involve network connections.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for safely listing local configuration without network access, but it gives no explicit guidance on when to prefer this over alternatives like list_roots or discover_roots. It does not mention exclusions or preferred scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
pull_file_to_workspacePull remote file to local workspaceA
Read one remote UTF-8 file and write it under the matching local site workspace path. Existing local files are backed up by default.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path relative to the configured domain root. | |
| domain | Yes | Configured domain root to operate under. | |
| dry_run | No | Return what would happen without reading or writing. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. | |
| local_backup | No | Back up an existing local file before overwriting it. | |
| workspace_root | No | Local workspace root. Defaults to config.localWorkspaceRoot or ~/Dev/xserver-sites. | |
| allow_sensitive | No | Allow default-excluded paths such as wp-config.php, uploads, logs, backups, and dumps. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations indicate this is not read-only and not destructive. The description adds valuable context by noting that 'Existing local files are backed up by default,' which clarifies the non-destructive behavior and the default backup mechanism. It also specifies the UTF-8 encoding, providing additional behavioral detail beyond the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, concise sentence that front-loads the core functionality and includes the key backup behavior. There is no redundant or extraneous information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With 7 parameters and no output schema, the description covers the primary purpose and a key behavior (backups), but it does not mention return values, error handling, or prerequisites like server connectivity. It is adequate for a straightforward file operation but lacks detail for a complex tool with many configuration options.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the parameters are already well-documented in the schema. The description mentions 'backed up by default,' which aligns with the local_backup parameter, but does not add new parameter meaning beyond what the schema provides. Baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action: 'Read one remote UTF-8 file and write it under the matching local site workspace path.' This specifies the verb, resource, and destination, and distinguishes it from siblings like push_file_from_workspace (which does the reverse) and read_file (which only reads without writing).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies this tool is used for copying a remote file into the local workspace, but it does not explicitly state when to choose this over alternatives or when not to use it. Sibling tools like read_file or backup_file could overlap, but the description gives no direct comparison or exclusion guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
push_file_from_workspacePush local workspace fileADestructive
Read one local workspace file and write it to the matching remote path. Existing remote files are backed up by default.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path relative to the configured domain root. | |
| backup | No | Back up existing remote file before writing. | |
| domain | Yes | Configured domain root to operate under. | |
| dry_run | No | Return what would happen without writing. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. | |
| backup_label | No | Backup label used in the generated filename. | |
| workspace_root | No | Local workspace root. Defaults to config.localWorkspaceRoot or ~/Dev/xserver-sites. | |
| allow_sensitive | No | Allow default-excluded paths such as wp-config.php, uploads, logs, backups, and dumps. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already mark the tool as destructive and not read-only. The description adds a valuable safety behavior: existing remote files are backed up by default. It does not mention sensitive-path exclusions or dry-run, but those are covered in the parameter schema, so the description adds appropriate context beyond annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two concise sentences that front-load the core action and include a key behavioral detail. Every word earns its place, with no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (8 parameters, no output schema), the description only covers the basic operation and backup default. While the schema explains parameters, the description lacks broader deployment context (e.g., typical use cases, behavior when duplicate paths exist, or interaction with domain roots) that would help an agent understand when to invoke it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, and each parameter already has a clear description. The description clarifies the overall flow (local to remote) but does not add meaning beyond the schema, fitting the baseline for high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states the specific action: reading a local workspace file and writing it to the matching remote path. This clearly distinguishes it from reverse operations like pull_file_to_workspace and direct write tools like write_file.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool vs alternatives. It does not mention deployment workflows, nor does it indicate when to avoid it (e.g., for creating new files or inline edits). The sibling tools suggest related operations, but no comparative context is given.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
read_fileRead remote fileBRead-only
Read a UTF-8 text file under a configured domain root over SFTP.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path relative to the configured domain root. | |
| domain | Yes | Configured domain root to operate under. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and destructiveHint=false, covering the safety profile. The description adds minor context (UTF-8 encoding, SFTP protocol, configured domain root) but does not disclose behavior like error handling, size limits, or authentication requirements. This meets the baseline with annotations but adds limited extra value.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that conveys the essential purpose without any wasted words. It is concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity, the schema fully documents parameters, and annotations cover safety, the description is largely complete. It could optionally mention the return value format, but this is not essential for a simple read operation. Sibling differentiation is missing, which prevents a 5.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with all parameters described (domain, path, server_id). The description does not add additional meaning beyond the schema, so a baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'Read' and the resource ('a UTF-8 text file under a configured domain root over SFTP'). However, it does not explicitly differentiate from the sibling tool pull_file_to_workspace, which also involves reading remote files, so it falls short of a 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives no explicit guidance on when to use this tool versus alternatives (e.g., pull_file_to_workspace or list_files). It implies usage for reading file content, but there is no stated context, exclusions, or alternative recommendations.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
replace_in_fileReplace text in remote fileADestructive
Read a file, replace all exact text matches, and write it back with backup by default.
| Name | Required | Description | Default |
|---|---|---|---|
| find | Yes | Exact text to replace. | |
| path | Yes | File path relative to the configured domain root. | |
| backup | No | Back up existing file before writing. | |
| domain | Yes | Configured domain root to operate under. | |
| dry_run | No | Return preview without writing. | |
| replace | No | Replacement text. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. | |
| backup_label | No | Backup label used in the generated filename. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate destructive behavior (destructiveHint=true). The description adds context by noting that replacements are exact text matches and that a backup is created by default, which goes beyond the annotation's binary safety signal.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single sentence that is front-loaded with the core operation and includes the key default behavior. Every word earns its place with no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the 8-parameter schema with 100% coverage and destructive annotations, the description adequately captures the overall workflow. It does not mention return values, but no output schema exists, and the process is clear enough for an agent to invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema covers all 8 parameters with descriptions, so the baseline is 3. The description adds slight value by clarifying that 'find' replaces ALL exact matches and that backup is default, reinforcing parameter semantics beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's action: read a file, replace all exact text matches, and write it back with backup by default. This specific verb+resource+behavior distinguishes it from siblings like read_file, write_file, and backup_file.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for find-and-replace operations but does not explicitly state when to prefer this tool over a combination of read_file and write_file, nor does it mention exclusions or alternatives. No sibling tools are named.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
set_domain_redirectSet domain redirectADestructive
Insert or update a marked .htaccess 301 redirect block for a configured source domain. Creates a backup by default.
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Relative .htaccess path under the source domain root. | .htaccess |
| backup | No | Back up existing .htaccess before writing. | |
| create | No | Create .htaccess if it does not exist. | |
| domain | Yes | Source domain to redirect, such as old-site.example.com. | |
| to_url | Yes | Destination URL, such as https://new-site.example.com. | |
| dry_run | No | Return resulting content without writing. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. | |
| preserve_path | No | Append the original request path to the destination. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description adds meaningful behavior beyond annotations: it states that a backup is created by default, which is important for a destructive operation (destructiveHint=true). It also mentions 'marked' blocks, implying a tracked/replaceable pattern. This supplements the annotation with useful operational detail without contradicting it.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences long and front-loads the core action and backup behavior. Every word adds value; there is no filler or repetition. It is appropriately sized for the tool's complexity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (8 parameters, 2 required) and lack of an output schema, the description provides enough context to understand the tool's core behavior. It does not mention return values, but the absence of an output schema lowers the expectation. The description covers the essential purpose and side effects, though it could mention the 'dry_run' capability or effect on existing redirects for full completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with each parameter having a descriptive explanation. The description itself does not add semantic detail beyond saying 'creates a backup by default' which aligns with the backup parameter. Since the schema already documents all parameters thoroughly, this dimension meets the baseline but does not exceed it.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'Insert or update a marked .htaccess 301 redirect block for a configured source domain.' It specifies a concrete verb (insert/update), a resource (.htaccess redirect block), and a clear scope (for a configured source domain). It is distinct from sibling tools like write_file or replace_in_file by focusing specifically on redirect management.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for setting up 301 redirects via .htaccess, which is a clear context. However, it does not explicitly mention when to prefer this tool over alternatives like write_file or replace_in_file, nor does it provide exclusion criteria. The guidance is implied but not explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
write_fileWrite remote fileADestructive
Write a UTF-8 text file under a configured domain root. Existing files are backed up by default.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path relative to the configured domain root. | |
| backup | No | Back up existing file before writing. | |
| domain | Yes | Configured domain root to operate under. | |
| content | Yes | UTF-8 text content to write. | |
| dry_run | No | Return what would happen without writing. | |
| server_id | No | Server profile id. Defaults to config.defaultServer. | |
| backup_label | No | Backup label used in the generated filename. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already mark the tool as destructive. The description adds useful context by noting that existing files are backed up by default, which goes beyond the bare annotations. No contradiction found.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences with front-loaded purpose and a key behavioral note. Every word earns its place with no redundancy or filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has 7 parameters and no output schema, the description is adequate but lacks details about return values or failure behavior. The schema covers the parameters, but the description doesn't add broader operational context such as dry-run semantics or how backups are labeled.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so parameters are fully documented. The description's mention of UTF-8 and backup default restates schema information but adds no new parameter-level meaning, so it meets the baseline for high coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action: 'Write a UTF-8 text file under a configured domain root.' It specifies the resource and verb, but does not explicitly differentiate from sibling tools like replace_in_file or push_file_from_workspace, though the scope is clear.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Usage is implied: use when you need to write a UTF-8 text file within a configured domain root. However, there are no explicit exclusions or references to alternatives, so the guidance is minimal.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
13 tool updates
v0.1.0- First observed
add_root - First observed
backup_file - First observed
discover_roots - First observed
init_site_workspace - First observed
list_files - First observed
list_roots - First observed
list_servers - First observed
pull_file_to_workspace - First observed
push_file_from_workspace - First observed
read_file - First observed
replace_in_file - First observed
set_domain_redirect - First observed
write_file
TDQS
Most tools have clear distinct purposes (listing, reading, writing, backing up, configuring). However, pull_file_to_workspace overlaps with read_file (both read remote content) and push_file_from_workspace overlaps with write_file (both write remote), which could cause misselection without careful descriptions.
All tool names follow a consistent snake_case verb_noun pattern (e.g., list_files, read_file, write_file, set_domain_redirect). Even the longer names like pull_file_to_workspace and push_file_from_workspace maintain the pattern with clear prepositions, so the naming convention is uniform.
13 tools is well-scoped for a file management server covering configuration, file operations, backups, and workspace sync. Each tool addresses a specific need without unnecessary bloat, making the count appropriate for the domain.
The tool surface covers core file operations (create, read, update) and backups, but notably lacks a delete tool and directory management (mkdir/move/copy). This is a significant gap for a file management server, as agents cannot complete full file lifecycle workflows.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Browse and manage files in your Moxt AI workspace from any MCP client.
Remote MCP server for XDaLa workflow preparation on XGR.Network.
A MCP server built for developers enabling Git based project management with project and personal…
MCP Server for Slima - AI Writing IDE for Novel Authors with AI Beta Reader.
Related MCP Servers
- FlicenseBqualityDmaintenanceA lightweight MCP server for basic file operations, enabling reading, writing, and listing files securely via the Model Context Protocol.31-
- AlicenseNot gradedqualityDmaintenanceA full-featured MCP server for local development with filesystem, shell, editor, session persistence, and security features.2MIT
- FlicenseNot gradedqualityDmaintenanceAn MCP server that provides secure access to local file system operations.-
- AlicenseNot gradedqualityCmaintenanceSSH-based MCP server that enables remote execution of SSH commands, file transfers, and secure server management via the MCP protocol.ISC
Appeared in Searches
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/mocchalera/xserver-files-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server