模态 MCP 服务器
用于与 Modal 卷交互并从 Cursor 内部部署 Modal 应用程序的 MCP 服务器实现。
安装
克隆此存储库:
使用
uv
安装依赖项:
配置
要在 Cursor 中使用此 MCP 服务器,请将以下配置添加到您的~/.cursor/mcp.json
:
将/path/to/modal-mcp-server
替换为克隆存储库的绝对路径。
要求
Python 3.11 或更高版本
uv
包管理器使用有效凭证配置的模态 CLI
对于模态部署支持:
正在部署的项目必须使用
uv
进行依赖管理Modal 必须安装在项目的虚拟环境中
支持的工具
模态体积操作
列出模态体积(
list_modal_volumes
)列出您环境中的所有 Modal 卷
返回 JSON 格式的卷信息
参数:无
列出卷内容(
list_modal_volume_contents
)列出 Modal 卷中的文件和目录
参数:
volume_name
:Modal卷的名称path
:卷内的路径(默认值:“/”)
复制文件(
copy_modal_volume_files
)复制 Modal 卷内的文件
参数:
volume_name
:Modal卷的名称paths
:最后一条路径为目的地的路径列表
例如:
["source.txt", "dest.txt"]
或["file1.txt", "file2.txt", "dest_dir/"]
删除文件(
remove_modal_volume_file
)从 Modal 卷中删除文件或目录
参数:
volume_name
:Modal卷的名称remote_path
:要删除的文件/目录的路径recursive
:递归删除的布尔标志(默认值:false)
上传文件(
put_modal_volume_file
)将文件或目录上传到 Modal 卷
参数:
volume_name
:Modal卷的名称local_path
:要上传的本地文件/目录的路径remote_path
:要上传到的卷路径(默认值:“/”)force
:布尔标志,用于覆盖现有文件(默认值:false)
下载文件(
get_modal_volume_file
)从 Modal 卷下载文件
参数:
volume_name
:Modal卷的名称remote_path
:要下载的卷中的文件/目录的路径local_destination
:保存下载文件的本地路径(默认值:当前目录)force
:布尔标志,用于覆盖现有文件(默认值:false)
注意:使用“-”作为
local_destination
将文件内容写入 stdout
模态部署
部署模态应用程序(
deploy_modal_app
)部署一个 Modal 应用程序
参数:
absolute_path_to_app
:Modal 应用程序文件的绝对路径
注意:包含 Modal 应用的项目必须:
使用
uv
进行依赖管理在其虚拟环境中安装
modal
CLI
响应格式
所有工具都以标准化格式返回响应,但根据操作类型的不同略有不同:
贡献
欢迎贡献代码!欢迎提交 Pull 请求。
执照
该项目根据 MIT 许可证获得许可 - 有关详细信息,请参阅LICENSE文件。
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
Tools
MCP 服务器使 AI 代理能够与 Modal 交互,从而允许它们在无服务器云环境中部署应用程序和运行功能。
Related MCP Servers
- -securityAlicense-qualityA simple MCP server for interacting with OpenAI assistants. This server allows other tools (like Claude Desktop) to create and interact with OpenAI assistants through the Model Context Protocol.Last updated -36MIT License
- AsecurityAlicenseAqualityA server that uses the Model Context Protocol (MCP) to allow AI agents to safely execute shell commands on a host system.Last updated -1626MIT License
- -securityAlicense-qualityAn MCP server that enables AI assistants to manage infrastructure, applications, databases, and services through the Coolify PaaS platform.Last updated -12MIT License
- AsecurityFlicenseAqualityAn MCP server that enhances AI agents' coding capabilities by providing zero hallucinations, improved code quality, security-first approach, high test coverage, and efficient context management.Last updated -15131