Skip to main content
Glama
iMateo

fastpanel-mcp

by iMateo

site_update

Update a site's document root and directory index. Commonly needed when a framework (e.g., Laravel) serves from a subfolder like /public.

Instructions

Change a site's document root (index_dir) and/or directory index, via PUT /api/sites/{site_id}. This is the ONLY way to repoint a site's docroot — nginx renders root from site.index_dir, NOT from the backend, so site_backend_update can't do it. Common need: frameworks that serve from a subfolder (Laravel/Symfony → /public). Pass framework:'laravel' to auto-append '/public' to the current docroot without computing the path yourself. This tool does a read-modify-write: it fetches the current site via site_get and resends the writable fields (docroot, index page, current certificate id, https/http2/http3/hsts flags) so the partial PUT doesn't blank out SSL or flags. ⚠️ UNVERIFIED ENDPOINT: the index_dir write path was not confirmable from the API spec (FastPanel has no OpenAPI). Run with dry_run:true, then a real call on a throwaway site, and check site_get afterwards. If index_dir does NOT change, capture the DevTools request the panel UI fires when you edit the docroot and report it so this can be corrected. WRITE — confirm:true required.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
confirmNo
dry_runNo
site_idYesSite id from sites_list
frameworkNoPreset: sets docroot to <current_index_dir>/public. Ignored if index_dir is given explicitly.
index_dirNoNew absolute document root, e.g. /var/www/www-root/data/www/<domain>/public. Omit if using `framework`.
index_pageNoDirectory index, e.g. 'index.php index.html'. Omit to keep current.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description fully discloses behavioral traits: it is a read-modify-write operation (fetches current site and resends writable fields to avoid blanking SSL/flags). It warns about the endpoint being UNVERIFIED and instructs on safe usage with dry_run and verification. It also states 'WRITE' and that confirm:true is required. Since no annotations are provided, the description carries the full burden and does so excellently.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is lengthy but every sentence adds value. It is well-structured: starts with main function, explains why this tool is needed, details a feature (framework auto-append), then describes the read-modify-write behavior, and ends with a warning and testing instructions. It could be slightly trimmed, but all information is relevant and logically ordered.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema and the complexity of the tool (read-modify-write, unverified endpoint), the description is fully complete. It covers how to use, what it does, potential risks, and verification steps. The sibling tools list provides context that this is among many site-related tools, and the description distinguishes it well.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema has 67% description coverage (4 of 6 parameters described). The description adds significant value beyond the schema: it explains that framework auto-appends '/public', describes the read-modify-write pattern, and clarifies the purpose of dry_run (testing) and confirm (required for write). It also provides context for index_dir and index_page usage. The undocumented parameters are clearly explained in the description.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool changes a site's document root and/or directory index via PUT. It distinguishes from sibling tool site_backend_update by explaining that nginx renders root from site.index_dir, not from the backend, so only this tool can repoint docroot. The specific verb 'change' and resource 'site' are clear, and the use case for frameworks is mentioned.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly states when to use this tool (changing docroot, especially for frameworks like Laravel/Symfony) and mentions that site_backend_update cannot do it. It provides common need examples and includes guidance on using dry_run and verification. However, it does not explicitly list other alternatives or when not to use it, but the context is very clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

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/iMateo/fastpanel-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server