Skip to main content
Glama

Claude-GAS-Bridge

by KaishuShito

克劳德-加斯-布里奇

这是一个使用 Node.js 连接MCP(模型上下文协议)客户端(例如 Claude Desktop)和 GAS 解释器(Google Apps Script 端)的桥接服务器。
bridge.mjs中,启动@modelcontextprotocol/sdk的 MCP 服务器,并提供向 GAS Web 端点进行 HTTP POST 的功能。

配置概述

claude-gas-bridge/ ├─ bridge.mjs # メインのMCPサーバーコード ├─ package.json ├─ package-lock.json └─ ... (その他ファイル)
  • bridge.mjs
    MCP 服务器本身。定义一个名为execute-gas的工具,将从客户端收到的GAS脚本传输到指定的WebApp(Apps Script)端点。
    调用该工具时,标题、脚本文本和 API 密钥以 JSON 格式发送。

要求

  • Node.js 18 及以上版本
    @modelcontextprotocol/sdk建议使用 Node 18 及以上版本
  • GAS 解释器已部署
    在 Google Apps Script 中正确部署 GAS 解释器并获取 Web 应用的 URL。
  • (可选)MCP 客户端,例如 Claude Desktop

设置

  1. 获取源代码
    git clone <このリポジトリのURL> cd claude-gas-bridge
  2. 安装依赖包
    npm install
    * 纱线也可以接受
  3. 设置 GAS 部署 URL
    bridge.mjs中的GAS_ENDPOINT替换为实际的 Apps Script URL。
    例子:
    const GAS_ENDPOINT = "https://script.google.com/macros/s/AKfycbxxxxx/exec";
  4. 使用 Node.js 启动服务器
    node bridge.mjs
    当控制台显示"Bridge server started (Stdio). Waiting for requests..."服务器处于待机模式,将接受来自 MCP 客户端的调用。

与 Claude Desktop 集成(示例)

如果您使用的是 Claude Desktop,请将以下内容添加到claude_desktop_config.json

{ "mcpServers": { "gas-bridge": { "command": "node", "args": [ "/絶対パス/claude-gas-bridge/bridge.mjs" ] } } }
  1. 重启Claude桌面
  2. 您应该在聊天屏幕底部的工具列表(锤子图标)中看到execute-gas
  3. 当你发出诸如“我想通过 ChatGPT 运行 GAS 脚本”之类的指令时, bridge.mjs会接收请求并将其转发给 GAS 解释器。

管理 API 密钥

  • 如果 GAS 解释器需要 API 密钥,请在调用该工具时指定"apiKey": "..." ,或者引用bridge.mjs中的环境变量并根据需要嵌入。
Install Server
A
security – no known vulnerabilities
F
license - not found
A
quality - confirmed to work

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

将 MCP 客户端(如 Claude Desktop)连接到 Google Apps Script 的桥接服务器,允许通过自然语言界面执行 GAS 脚本。

  1. 配置概述
    1. 要求
      1. 设置
        1. 与 Claude Desktop 集成(示例)
          1. 管理 API 密钥

            Related MCP Servers

            • A
              security
              A
              license
              A
              quality
              An MCP server implementation that integrates Claude with Salesforce, enabling natural language interactions with Salesforce data and metadata for querying, modifying, and managing objects and records.
              Last updated -
              7
              180
              45
              TypeScript
              MIT License
            • A
              security
              A
              license
              A
              quality
              An MCP server implementation that integrates Claude with Salesforce, enabling natural language interactions with Salesforce data and metadata for querying, modifying, and managing objects and records.
              Last updated -
              7
              18
              4
              TypeScript
              MIT License
              • Apple
              • Linux
            • -
              security
              F
              license
              -
              quality
              An MCP server that allows AI assistants like Claude to execute terminal commands on the user's computer and return the output, functioning like a terminal through AI.
              Last updated -
              7
              Python
              • Apple
            • -
              security
              F
              license
              -
              quality
              An MCP server that connects Claude for Desktop with blockchain functionality, allowing users to check balances and send tokens on EVM and Solana chains through natural language interactions.
              Last updated -
              TypeScript
              • Apple

            View all related MCP servers

            MCP directory API

            We provide all the information about MCP servers via our MCP API.

            curl -X GET 'https://glama.ai/api/mcp/v1/servers/KaishuShito/gas-interpreter-mcp'

            If you have feedback or need assistance with the MCP directory API, please join our Discord server