Skip to main content

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"]
    }
  }
}

其他工具同理。

配置 Claude Code

claude mcp add --transport stdio tushare-docs-mcp -- uvx 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

相关链接

Metadata

Release files for tushare-docs-mcp 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tushare-docs-mcp 0.2.0
File Size Uploaded Provenance
tushare_docs_mcp-0.2.0.tar.gz 204.4 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for tushare-docs-mcp 0.2.0
File Interpreter ABI Platform
tushare_docs_mcp-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 527.7 kB

Release files / tushare_docs_mcp-0.2.0.tar.gz

Download URL tushare_docs_mcp-0.2.0.tar.gz
Size 204.4 kB
Tags Source
SHA-256 checksum
How to use checksums
20d2940c31025df37b8ca98eaf9bd2ac5606e4af8aa93e6ff6bd6d3b56489efb
BLAKE2b-256 checksum
How to use checksums
18130c96317ed729b6707b653bf17834e405480cece96f6222a139f39b63aaa2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.14

Release files / tushare_docs_mcp-0.2.0-py3-none-any.whl

Download URL tushare_docs_mcp-0.2.0-py3-none-any.whl
Size 323.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e7f710ffb2abf51ec6e2ae7aea9d7ad4fe148ec097dbb223623a1f62c23d6c7d
BLAKE2b-256 checksum
How to use checksums
d75d471018b1dd6b66ffb93483363a2a0221bffe60ab5fd28da126b5aea3df03
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.14

Security for tushare-docs-mcp 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page