Connector guide9-minute read18 MCP tools7 languages

How to Connect Google Chat to Cursor via MCP

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

HCBy HelpCode teamUpdated 9 min read Open-source on GitHub

No credit card · 7-day trial · Self-host alternative available

Google Chat

Google Chat

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts.

tools

18

Region

INTL

Category

Messaging

Authentication

OAuth 2.0

Required env vars

GOOGLE_CLIENT_IDGOOGLE_CLIENT_SECRET
Install in one click on Cloud

7-day free trial · No credit card

  • 7-day free trial
    No credit card required
  • GDPR & SOC 2 ready
    EU data residency, audit logs
  • Open-source on GitHub
    Open source · AGPL-3.0
  • Works with ChatGPT, Claude, Gemini
    Any MCP-compatible client

Skip the install. Get this working in under 2 minutes.

Start a free trial on cloud.anythingmcp.com, add the Google Chat in one click, then point your AI client (Claude, ChatGPT, Copilot or Cursor) at the generated MCP endpoint. No Docker, no git clone, zero engineering experience required.

Start free trial

Summary

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Try asking

Example prompts for Google Chat

Click any prompt to copy it. Paste into Claude, ChatGPT, Cursor, Gemini, Copilot or OpenClaw to run it against this connector.

Google Chat · live via MCP
Share
Opus 4.7

Claude is AI and can make mistakes. Please double-check responses.

💡 No install? Use cloud.anythingmcp.com directly. Sign in, click Connectors → Google Chat, paste your credentials, mint an MCP API key and you're done. No Docker, no git clone, no local server.

Google Chat + Cursor

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Prerequisites

See the full setup instructions baked into the connector (visible in the in-app store when you select the connector). The required environment variables for this connector are:

GOOGLE_CLIENT_ID, GOOGLE_CLIENT_SECRET

Step 1 — Get credentials

Setting up takes about 15 minutes. You need a Google Workspace account (Business, Enterprise or Education): Google Chat API user access does not work with personal Gmail accounts.

  1. Open https://console.cloud.google.com, pick or create a project, then go to APIs & Services → Library and enable the Google Chat API.
  2. Configure the Chat app, which Google requires for Chat API calls made on behalf of a user: open APIs & Services → Enabled APIs → Google Chat API → Configuration (https://console.cloud.google.com/apis/api/chat.googleapis.com/hangouts-chat). Fill in App name (for example AnythingMCP), Avatar URL (any HTTPS link to a square PNG or JPEG) and Description, leave Interactive features turned off and click Save. Without this step, posting fails with "Google Chat app not found".
  3. Open APIs & Services → OAuth consent screen and choose Internal (Google Workspace). An External app with the publishing status Testing loses its refresh token after 7 days.
  4. Open APIs & Services → Credentials → Create credentials → OAuth client ID, choose the application type Web application and add the authorized redirect URI <your AnythingMCP URL>/api/mcp-oauth/callback, on AnythingMCP Cloud https://cloud.anythingmcp.com/api/mcp-oauth/callback.
  5. Paste the client ID into GOOGLE_CLIENT_ID and the client secret into GOOGLE_CLIENT_SECRET, then install the connector.
  6. On the connector page click Authorize with Provider and sign in with the Google Workspace account the AI should act as. The refresh token is stored encrypted and access tokens are renewed automatically.
  7. Run google_chat_list_spaces: it lists the spaces, group chats and direct messages of the signed-in account.

One Google client for all Google connectors: the same Cloud project and OAuth client can serve every Google connector (Gmail, Calendar, Drive, Sheets, Docs, Chat and more). Enable each API in that project, reuse GOOGLE_CLIENT_ID and GOOGLE_CLIENT_SECRET and authorize each connector once; each one asks only for its own scopes.

Whose name it writes in: the connector reads, posts and edits as the signed-in user, exactly as if they typed it, and sees only the spaces that user belongs to. The AI should confirm with you before it posts in your name.

Scopes: chat.spaces.readonly (see spaces), chat.messages (read, post, edit and delete your messages and reactions) and chat.memberships.readonly (see members). For a read-only setup change chat.messages to https://www.googleapis.com/auth/chat.messages.readonly in the connector's OAuth settings, authorize again and disable google_chat_create_message, google_chat_reply_in_thread, google_chat_update_message and google_chat_add_reaction.

What it reads: every space, group chat and direct message you belong to (google_chat_list_spaces, filtered by spaceType SPACE, GROUP_CHAT or DIRECT_MESSAGE), named spaces by name (google_chat_search_spaces, e.g. display_name:"Marketing" AND space_type = "SPACE"), the existing direct message with one person (google_chat_find_direct_message), and a space's details and members. The messages of one space, oldest first or latest first with order_by create_time desc, narrowed by time (create_time > "2026-10-01T00:00:00Z") or to one thread. A keyword search across all spaces and direct messages, newest first, with conditions such as sender.name = "users/[email protected]", createTime >= "2026-10-01T00:00:00Z", annotations.user_mentions.user.name:me (messages that mention you), attachment:*, has_link() or is_unread(). Reactions on a message, a message's attachments, and the change log of a space for the last 28 days: new, changed and deleted messages, reactions, memberships and space changes (google_chat_list_space_events, the filter must name at least one event type such as google.workspace.chat.message.v1.created).

What it writes: posts a message in a space, group chat or direct message (in a threaded space it starts a new thread), replies in an existing thread named by a message's thread.name, replaces the text of your own messages (people see them marked as edited) and adds emoji reactions. Passing request_id keeps a retried post from appearing twice.

Switched off at install: google_chat_delete_message and google_chat_delete_reaction. A deleted message cannot be restored, so an admin switches them on when the team needs them.

Data formats: Chat names things by path: a space is spaces/AAAAMpdlehY, a message spaces/AAAAMpdlehY/messages/ZJ7sqN6qlYk.ZJ7sqN6qlYk, a thread spaces/AAAAMpdlehY/threads/FHT5Rc21TfA, a person users/123456789. Tools take space_id (the part after spaces/) and message_id (the part after /messages/) separately, and thread_name and user in full. In filters and in google_chat_find_direct_message an email works too, as in users/[email protected]. Senders and members usually come back without a display name, so the AI matches people by id or email. Times are RFC 3339 in UTC (2026-10-29T14:05:31.123Z). Card content is left out of answers. Message text supports *bold*, _italic_, ~strike~, inline code in backticks, links as <https://example.com|label> and mentions as <users/123456789> or <users/all>; a message holds at most 32,000 bytes. Uploaded attachments are downloaded up to 10 MB; Google Drive files (source DRIVE_FILE) are read with the Google Drive connector through driveDataRef.driveFileId.

Paging and limits: answers carry nextPageToken while more results exist; the AI calls the same tool again with page_token set to it. google_chat_list_messages returns 25 messages per page by default. Google Chat allows about 3,000 reads per minute per project and about 1 message per second per space; a throttled call answers 429 RESOURCE_EXHAUSTED: wait and retry. The message search skips messages from Chat apps and muted spaces; google_chat_list_messages still reads them.

Common errors: 401 means the authorization expired or was revoked: click Authorize with Provider again. 403 PERMISSION_DENIED means the Chat API is not enabled, a scope is missing, the account is not a Google Workspace account, or you may not do this in that space, such as editing someone else's message. 404 NOT_FOUND is a wrong space or message id, a space you are not a member of, or, when posting, a Chat app that was not configured in step 2. google_chat_find_direct_message answers 404 when you have never had a direct message with that person. 400 INVALID_ARGUMENT is a filter Google does not accept: check quotes, operators and field names.

The connector does not create spaces, add or remove members, open new direct messages, upload files, send cards or post as a Chat app bot, and does not handle pinned messages or read state.

Step 2 — Install the adapter

curl -fsSL https://raw.githubusercontent.com/HelpCode-ai/anythingmcp/main/docker-compose.quickstart.yml -o docker-compose.yml
printf 'JWT_SECRET=%s\nENCRYPTION_KEY=%s\n' "$(openssl rand -hex 32)" "$(openssl rand -hex 32)" > .env
docker compose up -d

Step 3 — Add the connector in Cursor

Your server URL: in AnythingMCP, open MCP Servers → the server this connector is on, and copy its URL (https://cloud.anythingmcp.com/mcp/…). Use it wherever this guide shows YOUR_SERVER_ID.

Cursor reads MCP servers from ~/.cursor/mcp.json. Add this entry:

{
  "mcpServers": {
    "anythingmcp": {
      "url": "https://cloud.anythingmcp.com/mcp/YOUR_SERVER_ID",
      "headers": { "X-API-Key": "YOUR_MCP_API_KEY" }
    }
  }
}
  1. Create an MCP API key in AnythingMCP under MCP Servers → your server → API keys, and paste it in place of YOUR_MCP_API_KEY.
  2. Save the file and restart Cursor.
  3. Open Cursor → Settings → MCP and check that anythingmcp is listed and connected.
  4. Start chatting: the agent can now call the Google Chat tools.

Available tools

ToolWhat it does
google_chat_list_spacesList the spaces, group chats and direct messages the user is a member of: name (spaces/...), displayName (empty for direct messages)…
google_chat_search_spacesSearch the named spaces the user has joined by display name, e.g. query display_name:"Marketing" AND space_type = "SPACE". space_type =…
google_chat_get_spaceGet one space: displayName, spaceType, description and guidelines (spaceDetails), threading state, history state, membershipCount, whether…
google_chat_find_direct_messageFind the existing one-to-one direct message between the signed-in user and another person, to read or post there
google_chat_list_membersList the members of a space: each membership's name, role (ROLE_MEMBER, ROLE_MANAGER), state (JOINED, INVITED), createTime and member (name…
google_chat_list_messagesList the messages of a space, oldest first by default: name, sender (users/{id}, type), createTime, lastUpdateTime, text, thread.name…
google_chat_get_messageGet one message: sender, createTime, lastUpdateTime, text, thread.name, attachments (name, contentName, contentType…
google_chat_search_messagesSearch messages across every space and direct message the user belongs to, newest first. filter takes keywords plus conditions, e.g. budget…
google_chat_list_reactionsList the emoji reactions on a message: each reaction's name, emoji (unicode or customEmoji) and user
google_chat_get_attachmentGet the metadata of a file attached to a message: contentName (file name), contentType, source (UPLOADED_CONTENT or DRIVE_FILE)…
google_chat_download_attachmentDownload a file uploaded to a message (source UPLOADED_CONTENT), handed over as an attached file or image, up to 10 MB
google_chat_list_space_eventsList what happened in a space during the last 28 days: new, changed and deleted messages, reactions, memberships and space changes, each…
google_chat_create_messagePost a text message to a space, group chat or direct message as the signed-in user
google_chat_reply_in_threadReply in an existing thread of a space as the signed-in user. thread_name comes from thread.name of a message
google_chat_update_messageReplace the text of a message the signed-in user sent
google_chat_add_reactionAdd an emoji reaction from the signed-in user to a message, e.g. 👍
google_chat_delete_reactionRemove one of the signed-in user's reactions from a message. reaction_id is the part after /reactions/ in the reaction's name from…
google_chat_delete_messageDelete a message the signed-in user sent (managers can delete others' messages in some spaces)

Example prompts

  • "What was discussed in the Marketing space this week? Summarise each thread in two lines."
  • "Find unread messages from the last three days that mention me."
  • "Draft a reply in the thread about the Q4 budget and show it to me before you post it."
  • "Send [email protected] a direct message saying the deck is ready for review."
  • "Which files were shared in the Product space in October?"

FAQ

Does Cursor support custom MCP servers on the free tier? Yes, MCP is available on Hobby, Pro and Business plans.

Next steps

Was this guide helpful?

Your Google Chat agent is one click away.

Install the connector, paste the key, prompt Cursor. Free for 7 days, no credit card.

Related guides

Connectors

How to Connect Google Chat to ChatGPT via MCP

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Connectors

How to Connect Google Chat to Claude via MCP

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Connectors

How to Connect Google Chat to Gemini via MCP

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Connectors

How to Connect Google Chat to Meta Muse via MCP

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Connectors

Google Chat to MCP: Spaces, Messages, Threads and Reactions in any AI Agent

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.

Connectors

How to Connect Google Chat to Microsoft Copilot via MCP

Let your AI work in Google Chat as you: find spaces, group chats and direct messages, read and search messages and threads, see members, reactions and attachments, follow what changed in a space, post messages and replies, edit your messages and react. Google Workspace accounts, OAuth sign-in; deleting messages and reactions installs switched off.