模型上下文协议服务器

高性能模型上下文协议(MCP)服务器,提供无缝访问Attio API的能力,使AI助手如Claude和Cursor能够通过人类可读工具与您的Attio工作空间交互。

  • by itsbrex
  • JavaScript
  • 本地部署
  • 7 星标
  • 更新于
在 GitHub 查看 itsbrex/attio-mcp-server

使用说明

Attio MCP服务器

一个高性能的模型上下文协议(MCP)服务器,提供对Attio API的无缝访问,使Claude和Cursor等人工智能助手能够通过人机交互工具与您的Attio工作空间进行交互。

特性

  • 🏷️ 人类可读工具名称:自动转换API技术名称(如 getv2objects)明确、分类的名称(如 list_objects)
  • 📊 API全面覆盖:访问对象、记录、属性、列表、任务、笔记等
  • 📁 按类别组织:工具按逻辑类别分组,便于导航
  • 🤖 AI助手就绪:与Claude Desktop和Cursor无缝协作
  • ⚡ 高性能:使用Bun构建,实现快速执行和原生TypeScript支持
  • 🔧 简易安装:具有智能配置检测功能的自动设置脚本

https://github.com/user-attachments/assets/c3a5fe4c-e97e-4bcb-8140-a88c712a35cd

快速开始

  1. 先决条件:

    # Install Bun (if not already installed)
    curl -fsSL https://bun.sh/install | bash
    
  2. 安装并配置:

    ./install.sh
    
  3. 将您的Attio访问令牌添加到 .env:

    ATTIO_ACCESS_TOKEN=your_token_here
    

    从以下位置获取您的令牌:https://app.attio.com/settings/api

  4. 重新启动克劳德桌面或光标

手动安装

适用于克劳德桌面

./install-claude.sh

这将自动:

  • 将服务器添加到Claude的配置中
  • 使用您的访问令牌配置身份验证
  • 创建现有配置的备份

对于光标

./install-cursor.sh

这将自动:

  • 将服务器添加到Cursor的设置中
  • 使用您的访问令牌配置身份验证
  • 创建现有设置的备份

可用工具

MCP服务器将所有Attio API端点公开为具有可供人修改的名称的工具,按类别组织:

核心数据管理

  • 对象: list_objects, create_object, get_object, update_object
  • 记录: list_records, create_record, query_records, delete_record
  • 属性: list_attributes, create_attribute, update_attribute_status

列表和条目

  • 列表: list_lists, create_list, update_list
  • 输入序列: create_list_entry, query_list_entries, update_list_entry

协作

  • 任务: list_tasks, create_task, update_task, delete_task
  • 备注: list_notes, create_note, get_note, delete_note
  • 评论: create_comment, get_comment, list_comment_threads

行政

  • 工作区: list_workspace_members, get_workspace_member
  • 网页插件: list_webhooks, create_webhook, update_webhook
  • 认证: get_current_user

手动测试

要直接测试服务器,请执行以下操作:

bun start

配置

服务器使用以下环境变量:

  • ATTIO_ACCESS_TOKEN:您的Attio工作区访问令牌(必需)
  • PORT:web传输端口(默认值:3000)
  • LOG_LEVEL:日志记录级别(默认值:info)

故障排除

  1. 服务器未显示在Claude/Cursor中:

    • 安装后重新启动应用程序
    • 检查日志是否有任何错误
    • 确保服务器已构建: bun run build
  2. 身份验证错误:

    • 在中验证您的访问令牌 .env
    • 确保令牌具有必要的权限
  3. 构建错误:

    • 跑 bun install 确保所有依赖项都已安装
    • 跑 bun run build 编译TypeScript

发展

要修改服务器,请执行以下操作:

  1. 编辑 src/index.ts
  2. 跑 bun run build
  3. 测试用 bun test
  4. 重新启动Claude/Cursor以加载更改

开发命令

# Install dependencies
bun install

# Build the server
bun run build

# Run tests
bun test

# Run tests with coverage
bun test --coverage

# Format and lint code
bun run check

# Manual testing
bun run test:manual

支持

对于以下问题:

  • 此MCP服务器:在此存储库中创建问题
  • 阿提奥API:联系方式support@attio.com
  • MCP协议:参观https://modelcontextprotocol.io

贡献

欢迎投稿!请随时提交拉取请求。对于重大更改,请先打开一个问题来讨论您想要更改的内容。

许可证

这个项目是开源的,可以在MIT许可证下使用。


Built with ❤️ for the AI community