MCP (Model Context Protocol) server for Claude Desktop that provides access to Google Sheets, Gmail, and Google Calendar.
概览
MCP (Model Context Protocol) server for Claude Desktop that provides access to Google Sheets, Gmail, and Google Calendar. - : - : Read, write, append, and get sheet info - : List, search, get details, and send emails - : List, create, update, delete, and get event details - Python 3.8 or higher - Google Cloud Project with APIs enabled: - Google Sheets API - Gmail API - Google Calendar API - OAuth 2.0 credentials (credentials.json) - Claude Desktop installed 1. Download credentials.json from Google Cloud Console 2. Place credentials.json in the project root directory 3. Run the setup script to authenticate: 4. Follow the prompts to authorize access to your Google account 5. The script will create tokens.json with your access tokens : spreadsheetId and calendarId are optional - you can specify them per tool call. Example: C:\Users\YourName\AppData\Roaming\Claude\claude_desktop_config.json Open the config file (create it if it doesn't exist) and add:
README
以下为原文 README 节选,完整内容请查看原文。
Google Services MCP Server
MCP (Model Context Protocol) server for Claude Desktop that provides access to Google Sheets, Gmail, and Google Calendar.
Features
- 13 MCP Tools:
- Google Sheets (4 tools): Read, write, append, and get sheet info
- Gmail (4 tools): List, search, get details, and send emails
- Google Calendar (5 tools): List, create, update, delete, and get event details
Prerequisites
- Python 3.8 or higher
- Google Cloud Project with APIs enabled:
- Google Sheets API
- Gmail API
- Google Calendar API
- OAuth 2.0 credentials (
credentials.json) - Claude Desktop installed
Installation
1. Clone and Install Dependencies
# Navigate to project directory
cd mcplatestv1
# Install dependencies
pip install -r requirements.txt
2. Setup Google OAuth
- Download
credentials.jsonfrom Google Cloud Console - Place
credentials.jsonin the project root directory - Run the setup script to authenticate:
python src/setup.py
- Follow the prompts to authorize access to your Google account
- The script will create
tokens.jsonwith your access tokens
3. Configure Your Services
Edit config.json:
{
"google": {
"clientId": "your-client-id",
"clientSecret": "your-client-secret",
"redirectUri": "http://localhost",
"spreadsheetId": "your-spreadsheet-id",
"calendarId": "primary"
}
}
Note: spreadsheetId and calendarId are optional - you can specify them per tool call.
Claude Desktop Setup
Step 1: Find Claude Desktop Config File
Windows:
%APPDATA%\Claude\claude_desktop_config.json
Example: C:\Users\YourName\AppData\Roaming\Claude\claude_desktop_config.json
Mac:
~/Library/Application Support/Claude/claude_desktop_config.json
Linux:
~/.config/Claude/claude_desktop_config.json
Step 2: Edit Config File
Open the config file (create it if it doesn’t exist) and add:
{
"mcpServers": {
"google-services": {
"command": "python",
"args": [
"D:\\mcplatestv1\\src\\mcp_server.py"
],
"env": {}
}
}
}
Important:
- Update the path to match your actual project location
- On Windows, use double backslashes (
\\) in the path - On Mac/Linux, use forward slashes (
/)
Step 3: Restart Claude Desktop
Completely quit and restart Claude Desktop for the changes to take effect.
Step 4: Verify Connection
After restarting:
- Claude Desktop will automatically start the MCP server
- All 13 tools should be available
- Test by asking Claude: “What tools do you have access to?”
Usage
Once connected, you can ask Claude to:
- Read from Sheets: “Read the data from Sheet1!A1:B10”
- Write to Sheets: “Write these values to my spreadsheet: [[‘Name’, ‘Age’], [‘John’, ‘30’]]”
- List Emails: “Show me my last 10 emails”
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →配置
{
"mcpServers": {
"google-services": {
"command": "python",
"args": [
"D:\\mcplatestv1\\src\\mcp_server.py"
],
"env": {}
}
}
}