通知服务MCP服务器

一个用于通过模拟GC Notify服务发送通知的模型上下文协议(MCP)服务器。

  • by patheard
  • Python
  • 本地部署
  • 更新于
在 GitHub 查看 patheard/mcp-server-mock-notify

使用说明

GC通知的MCP服务器

一种模型上下文协议(MCP)服务器,用于通过模拟GC Notify服务发送通知。

设置

此项目使用 紫外线 用于Python包管理。

  1. 安装紫外线或使用提供的 devcontainer:

    curl -LsSf https://astral.sh/uv/install.sh | sh
    
  2. 安装依赖项:

    uv sync --directory server
    

在本地运行

使用uvicorn启动MCP通知服务器:

uv run --directory server uvicorn server:app

服务器将在以下时间可用 http://localhost:8000/notify/mcp/.

作为AWS Lambda函数运行

Terraform创建了一个具有函数URL的函数:

DOCKER_TAG="$AWS_ACCOUNT_ID.dkr.ecr.ca-central-1.amazonaws.com/mcp-server-mock-notify"

# Build the Docker image
docker build -t $DOCKER_TAG -f ./server/Dockerfile ./server

# Create the function
cd terraform
terraform init
terraform apply -target=aws_ecr_repository.mcp_server_mock_notify
docker push $DOCKER_TAG
terraform apply