Token导航 LogoToken导航TokenDH.com
Tiny Erp Server logo
AI代理stdio官方级别未说明来源级核验

Tiny Erp Server

MCP Server

一个完整的Tiny ERP集成服务器,提供68+工具全面访问Tiny API,支持JWT认证、MCP协议和FastAPI自动文档。

工具数

0

提示词数

0

GitHub Stars

1

资源数

0
API集成PythonFastAPI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

DanielRudnick

提供方

DanielRudnick

最后核验

2026/5/17 20:21

运行时

Python

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

命令预览

python -m venv venv

详细介绍

🚀 MCP微型ERP服务器

完整的模型上下文协议(MCP)服务器,可与Tiny ERP集成,实现 68+ 工具 完全访问Tiny API。

✨ 特点

  • 🎯 68+ MCP工具 涵盖整个 Tiny ERP API
  • 🔐 JWT 认证 与tiny_token集成
  • 📡 MCP协议 2025-06-18 (可流式传输HTTP)
  • 🚀 准备生产 (铁路、Fly.io等)
  • 📊 快速API 自动文档(Swagger)
  • 🔄 异步/等待 为了更好的性能

📦 可用工具

订单 (7)

  • tiny_pedidos_pesquisar - 搜索订单
  • tiny_pedido_obter - 订单详情
  • tiny_pedido_incluir - 创建订单
  • tiny_pedido_alterar - 更改订单
  • tiny_pedido_alterar_situacao - 改变状态
  • tiny_pedido_obter_rastreamento - 跟踪

产品 (7)

  • tiny_produtos_pesquisar - 产品搜索
  • tiny_produto_obter - 产品详情
  • tiny_produto_incluir - 创建产品
  • tiny_produto_alterar 更改产品
  • tiny_produto_obter_estoque 查看库存
  • tiny_produto_atualizar_estoque 更新库存
  • tiny_produto_obter_preco - 查看价格

联系方式 (4)

  • tiny_contatos_pesquisar - 联系人搜索
  • tiny_contato_obter - 联系方式
  • tiny_contato_incluir - 创建联系人
  • tiny_contato_alterar - 更改联系人

税务说明 (7)

  • tiny_notas_fiscais_pesquisar NFE 搜索
  • tiny_nota_fiscal_obter NFE 详情
  • tiny_nota_fiscal_incluir -埃米蒂尔NFe
  • tiny_nota_fiscal_gerar_pedido -订单NFE
  • tiny_nota_fiscal_enviar_email 发送 NFE
  • tiny_nota_fiscal_obter_xml -下载XML
  • tiny_nota_fiscal_cancelar -取消NFe

金融 (8)

  • tiny_contas_receber_pesquisar - 应收账款
  • tiny_conta_receber_obter - 详情
  • tiny_conta_receber_incluir - 创建账户
  • tiny_conta_receber_baixar - 下载/删除
  • tiny_contas_pagar_pesquisar - 应付账款
  • tiny_conta_pagar_obter - 详情
  • tiny_conta_pagar_incluir - 创建账户
  • tiny_conta_pagar_baixar - 下载/删除

客户关系管理(4)

  • tiny_crm_oportunidades_pesquisar - 机会
  • tiny_crm_oportunidade_obter - 详情
  • tiny_crm_oportunidade_incluir - 创建
  • tiny_crm_oportunidade_alterar -其他

超过30个工具:

  • 运输公司
  • 卖家
  • 分类
  • 标签
  • 存款
  • 预算
  • 采购订单
  • 宣言
  • 服务订单
  • 套件
  • 探险
  • PDV
  • 门票
  • 报告
  • 库存转移
  • 网络钩子
  • 集成
  • 市场

🚀 快速部署(Railway)

1. 准备仓库

# Clone ou navegue até o projeto
cd mcp-tiny-erp-server

# Adicione todos os arquivos
git add -A

# Commit
git commit -m "feat: MCP Tiny ERP Server completo com 68+ ferramentas"

# Push para GitHub
git push origin main

2.不部署铁路

  1. 爱搜索https://railway.app
  2. Clique em“新项目”
  3. Selecione“从GitHub部署”
  4. 选择您的仓库
  5. Railway 将自动检测 Dockerfile
  6. 等待部署(~3-5分钟)

3. 获取网址

部署后:

  1. 转到 Settings → Networking
  2. Clique em“生成域名”
  3. 您的URL将类似于: https://seu-projeto.railway.app

🧪 测试服务器

健康检查

curl https://SUA-URL.railway.app/health

MCP信息

curl https://SUA-URL.railway.app/mcp/info

Swagger文档

在浏览器中登录 :

https://SUA-URL.railway.app/docs

🔐 认证

服务器正在等待 JWT 令牌:

  • tenant_id -ID做租户
  • tiny_token -API小代币

MCP 调用示例:

curl -X POST "https://SUA-URL.railway.app/mcp" \
  -H "Authorization: Bearer SEU_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -H "MCP-Protocol-Version: 2025-06-18" \
  -d '{
    "jsonrpc": "2.0",
    "id": 1,
    "method": "initialize",
    "params": {
      "protocolVersion": "2025-06-18",
      "capabilities": {},
      "clientInfo": {
        "name": "test-client",
        "version": "1.0.0"
      }
    }
  }'

🛠️ 地方 发展

要求

  • Python 3.11+

安装

# Clone o repositório
git clone https://github.com/SEU_USUARIO/mcp-tiny-erp-server.git
cd mcp-tiny-erp-server

# Crie ambiente virtual
python -m venv venv
source venv/bin/activate  # Linux/Mac
# ou
venv\Scripts\activate  # Windows

# Instale dependências
pip install -r requirements.txt

# Execute
python -m uvicorn src.main:app --reload

访问 :

  • APIhttp://localhost:8000
  • 文件:http://localhost:8000/docs

📁 项目结构

mcp-tiny-erp-server/
├── src/
│   ├── __init__.py
│   ├── api/
│   │   ├── __init__.py
│   │   ├── mcp_server.py      # Servidor MCP
│   │   └── mcp_tools.py       # 68 ferramentas
│   ├── services/
│   │   ├── __init__.py
│   │   └── tiny_client.py     # Cliente API Tiny
│   └── main.py                # Entry point
├── Dockerfile
├── requirements.txt
├── .env.example
├── .gitignore
└── README.md

🔧 环境变量

复制 .env.example 段落 .env e配置:

TINY_API_BASE_URL=https://api.tiny.com.br/api2
TINY_API_TIMEOUT=30
ENVIRONMENT=production
DEBUG=false
PORT=8000
CORS_ORIGINS=*

📝 许可证

麻省理工学院许可证 - 详情请参阅许可证。

🤝 贡献

欢迎捐款!请:

  1. 分叉工程
  2. 创建分支(git checkout -b feature/MinhaFeature)
  3. 提交您的更改(git commit -m 'Add: MinhaFeature')
  4. 推动一个分支(git push origin feature/MinhaFeature)
  5. Abra um Pull请求

📞 支持

  • 📖 文档 : /docs 没有服务器
  • 🐛 问题:
  • 📧 电子邮件:seu-email@exemplo.com

🎯 下一步

  • \[ \] 添加单元测试
  • \[\]实现缓存Redis
  • \[\]租户的费率限制
  • \[\]Webhooks做Tiny
  • \[ \] 结构化日志
  • \[ \] 普罗米修斯计量

______________________________________________________________________

开发于❤️ 使用 FastAPI 和 MCP 协议

目录标签

目录标签

API集成PythonFastAPIERP集成本地部署API工具JWT认证MCP协议

接入字段

传输方式(transport,传输协议)

stdio

鉴权方式(authType,认证方式)

token

运行时(runtime,运行环境)

Python

工具数量(toolCount,工具数)

0

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

stdiotoken部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

来源信息

继续浏览同类 MCP