Grist Mcp Server

io.github.gwhthompson由 GitHub 帳號 gwhthompson 發布v2.0.33更新於 Oct 24, 2026

11 tools for managing Grist documents with AI

概覽

AI 產生的概覽

本機 MCP 伺服器,透過 11 個工具讓助理瀏覽、查詢與修改 Grist 的文件、記錄、資料表結構與頁面。

可以做什麼
列出並尋找工作區與文件,建立新文件或複製現有文件。檢視資料表結構,並執行含 JOIN 與彙總的 SQL 查詢。依條件取得記錄,並執行記錄的新增、讀取、更新、刪除(含 upsert)。管理資料表結構(資料表、欄位、彙總)與頁面版面。建立與管理用於即時事件通知的 webhook。透過內建說明工具查詢工具說明與 JSON schema。
適用情境
適合將結構化資料存放在 Grist,並希望助理直接探索資料、以 SQL 回答問題、匯入或更新記錄,或在不切換 Grist 介面的情況下建立資料表與調整頁面的情境。
執行需求
以本機程序執行,可透過 npx 或從原始碼以 Node.js 啟動;需要 GRIST_API_KEY 提供 Grist API 金鑰,GRIST_BASE_URL 指定執行個體(預設為 Grist 託管服務)。需要能連線至該 Grist 執行個體的網路。選用的 Cloudflare Workers 部署改用標頭驗證。
安裝前請注意
API 金鑰可存取你 Grist 帳號下的文件,請勿放入共用設定。記錄、資料表結構、頁面與 webhook 相關工具可新增、更新、刪除與覆寫資料,執行前應確認變更。webhook 會向你設定的位址傳送事件通知。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Grist Mcp Server,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

Grist MCP Server

[CI] [codecov] [npm] [License] [MCP]

MCP server for Grist. 11 tools for documents, records, SQL, and pages.

Quick Start

Claude Code (recommended)

bash
claude mcp add grist --env GRIST_API_KEY=your_api_key --env GRIST_BASE_URL=https://docs.getgrist.com -- npx -y grist-mcp-server

Claude Desktop (MCPB bundle)

  1. Download grist-mcp-server.mcpb from Releases
  2. In Claude Desktop: Settings → Developer → MCP Servers → Install from MCPB
  3. Configure your Grist API key and base URL
  4. Restart Claude Desktop

Manual configuration (.mcp.json)

Add to your .mcp.json file:

json
{  "mcpServers": {    "grist": {      "command": "npx",      "args": ["-y", "grist-mcp-server"],      "env": {        "GRIST_API_KEY": "your_api_key",        "GRIST_BASE_URL": "https://docs.getgrist.com"      }    }  }}

Install from source

bash
git clone https://github.com/gwhthompson/grist-mcp-server.gitcd grist-mcp-servernpm install && npm run build

Add to your MCP config:

json
{  "mcpServers": {    "grist": {      "command": "node",      "args": ["/path/to/grist-mcp-server/dist/index.js"],      "env": {        "GRIST_API_KEY": "your_api_key",        "GRIST_BASE_URL": "https://docs.getgrist.com"      }    }  }}

Cloudflare Workers (HTTP transport)

Deploy as a remote MCP server using Cloudflare Workers for HTTP-based access.

Local development:

bash
npm run worker:dev

Deploy to Cloudflare:

bash
npm run worker:deploy

Configuration:

The Workers deployment uses header-based authentication:

  • X-Grist-API-Key: Your Grist API key (required)
  • X-Grist-Base-URL: Grist instance URL (optional, defaults to https://docs.getgrist.com)

Endpoint: https://your-worker.workers.dev/mcp

Example request:

bash
curl -X POST https://your-worker.workers.dev/mcp \  -H "Content-Type: application/json" \  -H "X-Grist-API-Key: your_api_key" \  -d '{"jsonrpc":"2.0","method":"tools/list","id":1}'

Notes:

  • Stateless design: Each request creates a fresh server instance
  • CORS enabled for all origins (safe because auth uses headers, not cookies)
  • Configure environment variables via wrangler secret put GRIST_API_KEY

Tools

ToolPurpose
grist_get_workspacesList and filter workspaces
grist_get_documentsFind documents by ID, name, or workspace
grist_get_tablesGet table structure and schema
grist_query_sqlRun SQL queries with JOINs and aggregations
grist_get_recordsFetch records with filters
grist_manage_recordsAll record CRUD operations (add/update/delete/upsert)
grist_manage_schemaSchema operations: tables, columns, summaries
grist_manage_pagesPage layout and management
grist_create_documentCreate new Grist documents or copy existing ones
grist_manage_webhooksCreate and manage webhooks for real-time event notifications
grist_helpDiscover tools and get detailed documentation with JSON schemas

Examples

Create a database

1. grist_get_workspaces → find workspace2. grist_create_document → create document3. grist_manage_schema → create tables with columns

Import data

1. grist_get_documents → find document2. grist_get_tables → check structure3. grist_manage_records → upsert data (adds new, updates existing)

Query data

1. grist_get_tables → understand schema2. grist_query_sql → run SQL with JOINs and aggregations

Troubleshooting

Server won't start: Check GRIST_API_KEY is set in config.

Authentication fails: Verify API key at https://docs.getgrist.com/settings/keys.

Empty document list: Check GRIST_BASE_URL matches your Grist instance.

Connection errors (self-hosted): Verify URL includes https:// and server is reachable.

Testing

bash
npm test  # Docker required - container lifecycle is automatic

Documentation

Tool descriptions are concise. Use grist_help for details:

  • grist_help({tools: ["grist_manage_records"], only: ["examples"]})
  • grist_help({tools: ["grist_query_sql"], only: ["errors"]})

See CHANGELOG.md for version history.

Links

來源:README.md,提交 d75706c

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v2.0.33最新Sep 16, 2026

評分

已滿足適用檢查項的 40%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。