MCP

电报MCP服务器

电报每月拥有超过10亿活跃用户,分享消息、频道、群组、语音笔记、机器人和媒体,成为直接分发、社区管理和快速新闻受众的重要平台。

MCP 版本: 1.0.0 7 MCP工具 身份验证
电报

基本网址

https://mcp.pressmonitor.com/mcp

身份验证

MCP 调用也使用 Bearer 令牌通过 JSON-RPC 2.0 请求。

Authorization: Bearer YOUR_TOKEN

bot_info

机器人信息

参数

名称 类型 必填 描述
username string 用户名

代码示例

curl -X POST "https://mcp.pressmonitor.com/mcp" -H "Authorization: Bearer YOUR_API_KEY" -H "x-subscription-id: YOUR_SUB_ID" -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "bot_info",
    "arguments": {
      "username": "VALUE"
    }
  },
  "id": 1
}'

channel_info

频道信息

参数

名称 类型 必填 描述
username string 用户名

代码示例

curl -X POST "https://mcp.pressmonitor.com/mcp" -H "Authorization: Bearer YOUR_API_KEY" -H "x-subscription-id: YOUR_SUB_ID" -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "channel_info",
    "arguments": {
      "username": "VALUE"
    }
  },
  "id": 1
}'

get_messages

获取消息

参数

名称 类型 必填 描述
username string 用户名
offset string 偏移量

代码示例

curl -X POST "https://mcp.pressmonitor.com/mcp" -H "Authorization: Bearer YOUR_API_KEY" -H "x-subscription-id: YOUR_SUB_ID" -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "get_messages",
    "arguments": {
      "username": "VALUE"
    }
  },
  "id": 1
}'

group_info

群组信息

参数

名称 类型 必填 描述
username string 用户名

代码示例

curl -X POST "https://mcp.pressmonitor.com/mcp" -H "Authorization: Bearer YOUR_API_KEY" -H "x-subscription-id: YOUR_SUB_ID" -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "group_info",
    "arguments": {
      "username": "VALUE"
    }
  },
  "id": 1
}'

search_hashtag

搜索话题标签

参数

名称 类型 必填 描述
hashtag string 话题标签
offset string 偏移量

代码示例

curl -X POST "https://mcp.pressmonitor.com/mcp" -H "Authorization: Bearer YOUR_API_KEY" -H "x-subscription-id: YOUR_SUB_ID" -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "search_hashtag",
    "arguments": {
      "hashtag": "VALUE"
    }
  },
  "id": 1
}'

user_info

用户信息

参数

名称 类型 必填 描述
username string 用户名

代码示例

curl -X POST "https://mcp.pressmonitor.com/mcp" -H "Authorization: Bearer YOUR_API_KEY" -H "x-subscription-id: YOUR_SUB_ID" -H "Content-Type: application/json" -d '{
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "name": "user_info",
    "arguments": {
      "username": "VALUE"
    }
  },
  "id": 1
}'