Skip to main content

Tushare Docs MCP Server - 提供Tushare接口文档查询功能

Project description

Tushare Docs MCP Server

一个提供 Tushare 接口文档查询功能的 MCP (Model Context Protocol) 服务器。

功能特性

  • 📚 提供完整的 Tushare 接口文档查询
  • 🔍 支持按目录浏览和搜索文档
  • ⚡ 快速响应的文档检索
  • 🛠️ 支持多种传输方式 (HTTP/stdio)

安装

使用 pip 安装

pip install tushare-docs-mcp

使用 uvx 运行(推荐)

uvx tushare-docs-mcp stdio

使用方法

作为 MCP 服务器运行

  1. 标准输入输出模式(适用于 Claude 等 AI 工具):
tushare-docs-mcp stdio
  1. HTTP 模式(适用于开发和测试):
# 默认端口 8888
tushare-docs-mcp

# 指定端口
tushare-docs-mcp 8080

配置 Claude Desktop

claude_desktop_config.json 中添加:

{
  "mcpServers": {
    "tushare-docs": {
      "command": "uvx",
      "args": ["tushare-docs-mcp", "stdio"]
    }
  }
}

可用工具

  • tushare_basic: 获取 Tushare 库的基础用法说明
  • tushare_docs_catalog: 获取 Tushare 库的接口文档目录
  • tushare_docs: 根据路径获取特定接口的文档

使用示例

在 Claude 中,你可以这样询问:

"请帮我查看 Tushare 中获取股票列表的接口文档"

"显示 Tushare 的基础用法说明"

"我想了解日线行情的接口,路径是 01_股票数据 02_行情数据 01_历史日线"

开发

本地开发

# 克隆仓库
git clone https://github.com/momojie/tushare-docs-mcp.git
cd tushare-docs-mcp

# 安装依赖
pip install -e .

# 运行服务器
python -m tushare_docs_mcp.main stdio

构建

# 构建分发包
python -m build

# 检查包
twine check dist/*

许可证

MIT License

贡献

欢迎提交 Issue 和 Pull Request!

相关链接

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tushare_docs_mcp-0.1.0.tar.gz (183.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tushare_docs_mcp-0.1.0-py3-none-any.whl (325.5 kB view details)

Uploaded Python 3

File details

Details for the file tushare_docs_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: tushare_docs_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 183.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for tushare_docs_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 007a44c0ac1cdf9a380a898178aabb6f4ff58e09ffe0e208b6f27fc7343a52b5
MD5 97a65cba93f0ecf0aa280aba92a1699d
BLAKE2b-256 b1810937ecdec231ac46fcc933eae63f79fb265d9643c4951471527e2755518b

See more details on using hashes here.

File details

Details for the file tushare_docs_mcp-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for tushare_docs_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 60b6ec8843e5f364e261928afb0f0a2506729b9e14872d5591482d9291466fa7
MD5 810e3613cef5dbdb1837fc7ed9136b5c
BLAKE2b-256 efc73b2194b91c68a4d9eedf00f16fc451d081a438988c37467ff9e1fe1cc118

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page