Back to MCP directory
publicPublicdnsLocal runtime

custom-mcp-server

天气数据获取项目,包含STDIO和SSE两种传输方式

article

README

🚀 天气数据获取器

本项目包含两种不同运输方式的天气数据获取器,分别使用 STDIO 和 Server-Sent Events (SSE) 进行数据传输。

🚀 快速开始

项目结构

  • stdio/:使用 STDIO 运输的天气数据获取器
  • sse/:使用 Server-Sent Events (SSE) 运输的天气数据获取器

📚 详细文档

MCP 配置

全局 MCP 配置存储在 ~/.cursor/mcp.json 中,具体配置如下:

// stdio
"weather-data-fetcher": {
  "command": "node",
  "args": ["/path/to/mcp/stdio/index.js"]
},

// sse
"weather-data-fetcher-sse": {
  "url": "http://localhost:3000/sse"
}
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client