Skip to main content
Glama
yshumei2025

ID Factory MCP Server

by yshumei2025

ID Factory MCP Server

一个基于 Model Context Protocol (MCP) 的 ID Factory 解析服务器,提供统一的 ID 句柄解析和查询功能。

功能特性

  • 单个ID解析 - 解析ID句柄获取详细信息

  • 批量解析 - 同时解析多个ID句柄

  • 组件分析 - 解析并格式化ID组件信息

  • 完整响应数据 - 包括站点信息、归属信息、权限设置等

安装

使用 pip

pip install mcp

使用 uv (推荐)

uv pip install mcp

快速开始

方式1: 直接运行

python idfactory_mcp_server.py

方式2: 使用包管理器

# 安装
pip install -e .

# 运行
idfactory-mcp-server

MCP 配置

在 Claude Code 的配置文件中添加:

{
  "mcpServers": {
    "idfactory": {
      "command": "python",
      "args": ["/path/to/idfactory_mcp_server.py"],
      "env": {}
    }
  }
}

使用示例

# 解析单个ID
请帮我解析ID句柄 700.100

# 批量解析
批量解析这些ID:700.100, 700.1, 700.2

# 组件分析
详细解析ID 700.100的所有组件信息

API 端点

  • Base URL: http://resolve.idfactory.cn:8081

  • 无需认证:公开API,无需密钥

工具列表

工具名

描述

参数

resolve_id

解析ID获取详细信息

handle (必需)

batch_resolve_ids

批量解析多个ID句柄

handles (必需, 数组)

parse_id_components

解析并格式化ID组件

handle (必需), format_output (可选)

项目结构

.
├── idfactory_mcp_server/      # 包目录
│   ├── __init__.py
│   └── server.py              # MCP服务器实现
├── idfactory_mcp_server.py    # 单文件版本
├── pyproject.toml             # 项目配置
├── requirements.txt           # 依赖列表
└── README.md                  # 本文档

开发

运行测试

python test_idfactory.py

调试模式

# 启用详细日志
LOGLEVEL=DEBUG python idfactory_mcp_server.py

依赖

  • Python >= 3.10

  • mcp >= 1.0.0

License

MIT License

作者

yshumei098

相关链接

-
security - not tested
F
license - not found
-
quality - not tested

Resources

Looking for Admin?

Admins can modify the Dockerfile, update the server description, and track usage metrics. If you are the server author, to access the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/yshumei2025/idfactory-mcp-server-test'

If you have feedback or need assistance with the MCP directory API, please join our Discord server