Modal MCP Server

local-only server

The server can only run on the client’s local machine because it depends on local resources.

Integrations

  • Serves as the API framework for the MCP server, providing documentation at /docs endpoint and RESTful endpoints for tool invocation.

  • Provides repository access for the MCP server code, supporting installation via git clone from a GitHub repository.

  • Provides tools for deploying and running Modal applications in the cloud, allowing AI agents to deploy Modal apps and execute functions within Modal applications.

모달 MCP 서버

Cursor 내에서 Modal 볼륨과 상호 작용하고 Modal 애플리케이션을 배포하기 위한 MCP 서버 구현입니다.

설치

  1. 이 저장소를 복제하세요:

지엑스피1

  1. uv 사용하여 종속성을 설치합니다.
uv sync

구성

Cursor에서 이 MCP 서버를 사용하려면 ~/.cursor/mcp.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" ] } } }

/path/to/modal-mcp-server 복제된 저장소의 절대 경로로 바꾸세요.

요구 사항

  • Python 3.11 이상
  • uv 패키지 관리자
  • 유효한 자격 증명으로 구성된 모달 CLI
  • Modal 배포 지원:
    • 배포되는 프로젝트는 종속성 관리를 위해 uv 사용해야 합니다.
    • Modal은 프로젝트의 가상 환경에 설치되어야 합니다.

지원되는 도구

  1. 모달 볼륨 목록 ( list_modal_volumes )
    • 사용자 환경의 모든 모달 볼륨을 나열합니다.
    • JSON 형식의 볼륨 정보를 반환합니다.
    • 매개변수: 없음
  2. 볼륨 내용 목록 ( list_modal_volume_contents )
    • 모달 볼륨의 파일 및 디렉토리를 나열합니다.
    • 매개변수:
      • volume_name : 모달 볼륨의 이름
      • path : 볼륨 내 경로(기본값: "/")
  3. 파일 복사 ( copy_modal_volume_files )
    • 모달 볼륨 내의 파일을 복사합니다.
    • 매개변수:
      • volume_name : 모달 볼륨의 이름
      • paths : 마지막 경로가 목적지인 경로 목록
    • 예: ["source.txt", "dest.txt"] 또는 ["file1.txt", "file2.txt", "dest_dir/"]
  4. 파일 제거 ( remove_modal_volume_file )
    • 모달 볼륨에서 파일이나 디렉토리를 삭제합니다.
    • 매개변수:
      • volume_name : 모달 볼륨의 이름
      • remote_path : 삭제할 파일/디렉토리 경로
      • recursive : 재귀적 삭제에 대한 부울 플래그(기본값: false)
  5. 파일 업로드 ( put_modal_volume_file )
    • 모달 볼륨에 파일이나 디렉토리를 업로드합니다.
    • 매개변수:
      • volume_name : 모달 볼륨의 이름
      • local_path : 업로드할 로컬 파일/디렉토리 경로
      • remote_path : 업로드할 볼륨의 경로(기본값: "/")
      • force : 기존 파일을 덮어쓸지 여부를 지정하는 부울 플래그(기본값: false)
  6. 파일 다운로드 ( get_modal_volume_file )
    • 모달 볼륨에서 파일을 다운로드합니다.
    • 매개변수:
      • volume_name : 모달 볼륨의 이름
      • remote_path : 다운로드할 볼륨의 파일/디렉토리 경로
      • local_destination : 다운로드한 파일을 저장할 로컬 경로(기본값: 현재 디렉토리)
      • force : 기존 파일을 덮어쓸지 여부를 지정하는 부울 플래그(기본값: false)
    • 참고: 파일 내용을 stdout에 쓰려면 local_destination 으로 "-"를 사용하세요.
  1. 모달 앱 배포 ( deploy_modal_app )
    • 모달 애플리케이션을 배포합니다
    • 매개변수:
      • absolute_path_to_app : Modal 애플리케이션 파일에 대한 절대 경로
    • 참고: Modal 앱이 포함된 프로젝트는 다음과 같아야 합니다.
      • 종속성 관리를 위해 uv 사용하세요
      • 가상 환경에 modal CLI를 설치하세요

응답 형식

모든 도구는 작업 유형에 따라 약간의 차이가 있지만 표준화된 형식으로 응답을 반환합니다.

# 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 }

기여하다

기여를 환영합니다! 풀 리퀘스트를 제출해 주세요.

특허

이 프로젝트는 MIT 라이선스에 따라 라이선스가 부여되었습니다. 자세한 내용은 라이선스 파일을 참조하세요.

-
security - not tested
A
license - permissive license
-
quality - not tested

AI 에이전트가 Modal과 상호 작용하여 서버리스 클라우드 환경에서 앱을 배포하고 기능을 실행할 수 있도록 하는 MCP 서버입니다.

  1. Installation
    1. Configuration
      1. Requirements
        1. Supported Tools
          1. Modal Volume Operations
          2. Modal Deployment
        2. Response Format
          1. Contributing
            1. License
              ID: gmerfou61f