trackmcp
Back to directory
smehmood

modal-mcp-server

View on GitHub

MCP Server for managing Modal applications

3 stars PythonServers & Infrastructure Updated Apr 19, 2025

Documentation

Modal MCP Server

An MCP server implementation for interacting with Modal volumes and deploying Modal applications from within Cursor.

Installation

1. Clone this repository:

bash
git clone https://github.com/smehmood/modal-mcp-server.git
cd modal-mcp-server

2. Install dependencies using `uv`:

bash
uv sync

Configuration

To use this MCP server in Cursor, add the following configuration to your `~/.cursor/mcp.json`:

json
{
  "mcpServers": {
    "modal-mcp-server": {
      "command": "uv",
      "args": [
        "--project", "/path/to/modal-mcp-server",
        "run", "/path/to/modal-mcp-server/src/modal_mcp/server.py"
      ]
    }
  }
}

Replace `/path/to/modal-mcp-server` with the absolute path to your cloned repository.

Requirements

  • Python 3.11 or higher
  • `uv` package manager
  • Modal CLI configured with valid credentials
  • For Modal deploy support:
    • Project being deployed must use `uv` for dependency management
    • Modal must be installed in the project's virtual environment

Supported Tools

1. List Modal Volumes (`list_modal_volumes`)

    2. List Volume Contents (`list_modal_volume_contents`)

      3. Copy Files (`copy_modal_volume_files`)

        4. Remove Files (`remove_modal_volume_file`)

          5. Upload Files (`put_modal_volume_file`)

            6. Download Files (`get_modal_volume_file`)

              1. Deploy Modal App (`deploy_modal_app`)

                Response Format

                All tools return responses in a standardized format, with slight variations depending on the operation type:

                python
                # JSON operations (list volumes, list contents):
                {
                    "success": True,
                    "data": {...}  # JSON data from Modal CLI
                }
                
                # File operations (put, get, copy, remove):
                {
                    "success": True,
                    "message": "Operation successful message",
                    "command": "executed command string",
                    "stdout": "command output",  # if any
                    "stderr": "error output"     # if any
                }
                
                # Error case (all operations):
                {
                    "success": False,
                    "error": "Error message describing what went wrong",
                    "command": "executed command string",  # for file operations
                    "stdout": "command output",  # if available
                    "stderr": "error output"     # if available
                }

                Contributing

                Contributions are welcome! Please feel free to submit a Pull Request.

                License

                This project is licensed under the MIT License - see the LICENSE file for details.

                Frequently asked questions

                What is modal-mcp-server?

                modal-mcp-server is MCP Server for managing Modal applications

                How do I install modal-mcp-server?

                Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.

                Is modal-mcp-server open source?

                Yes — it is hosted on GitHub at https://github.com/smehmood/modal-mcp-server and has 3 stars.

                Related MCP tools

                Run your own MCP server? See who uses it and what to fix.

                Measure it with TrackMCP