Setup: Google Workspace MCP (Brainforge)
This guide explains how to install and use the Brainforge Google Workspace MCP from:
- Cursor (recommended for day-to-day agent workflows)
- Codex CLI / Codex Desktop
The MCP server is hosted on Railway; you connect to it via URL.
When to use this MCP
For Cursor/agent workflows, use the BrainForge Google Workspace MCP (brainforge-google) as the default path (search/read, structured retrieval, small updates). Fall back to the Google Workspace CLI (gws) for bulk operations, tight iterative loops, or when MCP is unavailable. See google-workspace-cli-setup.md.
How Cursor loads the Google MCP
When you open this repo
The brainforge-platform repo includes a .cursor folder with an mcp.json that points to the Railway-hosted Google Workspace MCP. When you open the brainforge-platform repo as your Cursor workspace (or as a workspace root), Cursor loads that config automatically and the Google MCP is available.
Location: .cursor/mcp.json (at repo root)
{
"mcpServers": {
"brainforge-google": {
"url": "https://google-workspace-mcp-production-bab7.up.railway.app/mcp",
"headers": {}
}
}
}No extra configuration is needed in that case.
When the playbook is not your top-level workspace
If you open a different folder as your workspace (e.g. the parent BrainforgeAI repo or another project), Cursor looks for MCP config in that workspace’s .cursor/mcp.json or in your user-level settings. The playbook’s .cursor/mcp.json is not used.
In that case, add the Google Workspace MCP entry to your user/workspace MCP config:
- Open Cursor Settings → MCP (or edit the config file directly).
- Ensure your
mcp.jsonincludes the same server entry. For example, merge this into your existingmcpServers:
{
"mcpServers": {
"brainforge-google": {
"url": "https://google-workspace-mcp-production-bab7.up.railway.app/mcp",
"headers": {}
}
}
}- User-level config (all projects):
~/.cursor/mcp.json(e.g.C:\Users\<You>\.cursor\mcp.jsonon Windows,~/.cursor/mcp.jsonon macOS/Linux). - Workspace-level (current project only):
.cursor/mcp.jsonat the root of the folder you opened in Cursor.
If you use workspace-level, create .cursor/mcp.json in that root with the snippet above (and any other MCPs you want for that workspace).
First-time authentication
Brainforge runs this MCP in OAuth 2.1 mode (protocol-level auth). That means:
- Each teammate authenticates with their own Google account
- Your MCP client handles the OAuth flow (you’ll be prompted to open a browser / approve access)
- The legacy
start_google_authflow may be disabled on the server
Cursor (recommended)
- Trigger any Google tool call in chat (e.g. “fetch this Google Doc by ID”).
- Cursor will prompt you through OAuth. Complete the browser flow.
- Retry the original action.
Use the same Google account (e.g. your work email) that has access to the Drive/Docs/Sheets you care about.
Codex CLI
If you’re using Codex CLI, add the server and then run any tool (Codex will drive the OAuth flow):
codex mcp add brainforge-google --url https://google-workspace-mcp-production-bab7.up.railway.app/mcpThen test with a lightweight call (examples below).
Quick test (recommended)
Use an ID you can access:
get_doc_contentwithdocument_id=<google_doc_id>search_drive_fileswith a simple query (e.g. by name)
Example Doc ID used during verification:
15Mj4qGQSmxdJv-E4Cg9LMIc02klCaP85NTwH2oPIIT0
Available tools
Once the MCP is loaded and you’re authenticated, these tools are available to Cursor agents. You can use the MCP for email and calendar—no need to search for alternatives; use the tools below.
Gmail
search_gmail_messages- Search messages with Gmail query syntax (from/to/subject/query)get_gmail_message_content- Get a single messageget_gmail_thread_content- Get full thread (conversation)get_gmail_messages_content_batch/get_gmail_threads_content_batch- Batch fetchdraft_gmail_message- Create a draftsend_gmail_message- Send an email
Google Calendar
list_calendars- List calendars for the authenticated userget_events- Get events (by id or time range; optional keyword query)create_event- Create an event (title, start/end, attendees, optional Meet)modify_event- Update an existing eventdelete_event- Delete an eventquery_freebusy- Free/busy for a set of calendars in a time range
For calendar attendees, resolve team member emails from the Supabase team table (Cursor rule: .cursor/rules/supabase-team-user-lookup.mdc); do not hardcode addresses.
Google Drive
search_drive_files- Search files with query syntaxget_drive_file_content- Read file contentcreate_drive_file- Create new filesshare_drive_file- Share files with users/groupslist_drive_items- List folder contentslist_docs_in_folder- List Google Docs in a Drive folder
Google Docs
get_doc_content- Extract document textcreate_doc- Create new documentsmodify_doc_text- Edit document textfind_and_replace_doc- Find and replace text
Google Sheets
read_sheet_values- Read cell rangesmodify_sheet_values- Write/update cellscreate_spreadsheet- Create new spreadsheetsget_spreadsheet_info- Get spreadsheet metadata
Google Slides
create_presentation- Create new presentationsget_presentation- Retrieve presentation detailsbatch_update_presentation- Apply updates to slides
MCP not showing or “Disabled”
- If you didn’t open brainforge-platform as the workspace root, add the
brainforge-googleentry to your user or workspacemcp.jsonas in the section above. - Reload the window (Command Palette → “Developer: Reload Window”) after changing MCP config.
“Needs authentication” or tools fail
- Trigger any Google tool in chat; complete the OAuth browser flow; retry.
Permission errors
- Use a Google account that has access to the Drive/Docs/Sheets you’re trying to use. For shared drives, ensure the account has the right permissions.
Reference
- BrainForge Google Workspace MCP (Railway):
https://google-workspace-mcp-production-bab7.up.railway.app - Brainforge-owned MCP/server repo:
brainforge-ai/brainforge-mcp_google_workspace - Upstream: taylorwilsdon/google_workspace_mcp
This MCP is part of Brainforge’s plugin/MCP infrastructure: the server implementation lives in the Brainforge-owned repo above, while the brainforge-platform monorepo contains the playbooks + MCP client configuration (e.g. .cursor/mcp.json) that point to the hosted service.