mcp_file_manager
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| FM_HOST | No | Host address for the HTTP server to listen on. | 127.0.0.1 |
| FM_PORT | No | Port for the HTTP server to listen on. | 8787 |
| FM_DATA_DIR | No | Directory to store data (files/, tmp/, index.json). | ./data |
| FM_API_TOKEN | No | Authentication token for write operations. Strongly recommended for non-local deployments. | |
| FM_LOG_LEVEL | No | Logging level: debug, info, warn, or error. | info |
| FM_TTL_HOURS | No | Default retention duration in hours. Files are automatically deleted after this time. | 24 |
| FM_MAX_INLINE_MB | No | Maximum size in megabytes for inline content returned by MCP tools. Larger files return only a link. | 4 |
| FM_MAX_TTL_HOURS | No | Maximum allowed retention hours for a single upload request (30 days). | 720 |
| FM_MAX_UPLOAD_MB | No | Maximum allowed upload file size in megabytes. | 100 |
| FM_PUBLIC_BASE_URL | No | Base URL used to generate public download links. Must be set when behind a reverse proxy or domain. | http://<host>:<port> |
| FM_ALLOW_LOCAL_PATH | No | Set to '1' to allow uploading files from a local server path. | 1 |
| FM_ALLOW_REMOTE_FETCH | No | Set to '1' to allow uploading files from a remote URL. | 1 |
| FM_SWEEP_INTERVAL_MINUTES | No | Interval in minutes for the background expired-file cleanup task. | 10 |
Capabilities
Features and capabilities supported by this server
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| upload_fileA | 上传一个文件并获得标识码与下载链接。 content / text / path / url 四个来源参数只能传其中一个:
|
| download_fileA | 根据标识码取回文件内容。 默认自动选择编码:文本类直接返回正文,二进制返回 base64。 传 savePath 可以直接写到服务器本地路径;文件过大时只返回链接。 |
| get_file_infoA | 根据标识码查看文件名、大小、校验值、下载链接与剩余保留时间,不返回文件内容。 |
| list_filesA | 列出当前未过期的文件,支持关键词、标签过滤与分页。忘记标识码时用它找回文件。 |
| delete_fileA | 立即删除指定标识码的文件与元数据,不等到期。操作不可恢复。 |
| extend_expiryA | 把文件的到期时间重算为“从现在起再保留 N 小时”,上限 720 小时。 |
| create_upload_linkA | 生成一个临时上传页面链接,可以直接发给人类用户在浏览器里上传文件。 用户上传完成后会得到标识码,把标识码告知你即可用 download_file 取用。 |
| sweep_expiredA | 手动触发一次到期清理(后台任务已经定时执行,一般无需调用)。 |
| get_storage_statsA | 查看当前文件数量、占用空间、保留策略与下一个到期时间。 |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
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/xtawa/mcp_file_manager'
If you have feedback or need assistance with the MCP directory API, please join our Discord server