google-calendar-mcp
Google Calendar MCP Setup Guide
Set up Google Calendar integration for Claude Code CLI using the @cocal/google-calendar-mcp server.
Source: https://github.com/nspady/google-calendar-mcp
Prerequisites
- Node.js installed (for npx)
- Google account
- Claude Code CLI installed
Part 1: Google Cloud Console Setup
Step 1: Create Project
- Go to https://console.cloud.google.com/
- Click project dropdown (top-left) → New Project
- Name:
Claude Calendar→ Create - Select the new project from dropdown
Step 2: Enable Calendar API
- Go to APIs & Services → Library
- Search "Google Calendar API" → Click → Enable
Step 3: OAuth Consent Screen
- Go to APIs & Services → OAuth consent screen
- Select External → Create
- Fill required fields:
- App name:
Claude Calendar - User support email: (your email)
- Developer contact: (your email)
- App name:
- Click Save and Continue
- Scopes page → Add or Remove Scopes
- Add:
https://www.googleapis.com/auth/calendar - Click Update → Save and Continue
- Add:
- Test Users → Add Users → Add your Gmail → Save and Continue
Step 4: Create Credentials
- Go to APIs & Services → Credentials
- Click + Create Credentials → OAuth client ID
- Application type: Desktop app
- Name:
Claude Code - Click Create → Download JSON
Part 2: Save Credentials
Save the downloaded JSON file:
Windows:
C:\Users\salmanferoz\.google-calendar-mcp\gcp-oauth.keys.json
Mac/Linux:
~/.google-calendar-mcp/gcp-oauth.keys.json
Create the .google-calendar-mcp folder if it doesn't exist.
Part 3: Add MCP to Claude Code
Auto-Setup Command
When the user has saved their credentials, run this command automatically:
Windows:
claude mcp add --scope user --transport stdio google-calendar --env GOOGLE_OAUTH_CREDENTIALS="C:\Users\salmanferoz\.google-calendar-mcp\gcp-oauth.keys.json" -- npx -y @cocal/google-calendar-mcp
Mac/Linux:
claude mcp add --scope user --transport stdio google-calendar --env GOOGLE_OAUTH_CREDENTIALS="$HOME/.google-calendar-mcp/gcp-oauth.keys.json" -- npx -y @cocal/google-calendar-mcp
Manual JSON Config (Alternative)
Add to ~/.claude.json:
{
"mcpServers": {
"google-calendar": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@cocal/google-calendar-mcp"],
"env": {
"GOOGLE_OAUTH_CREDENTIALS": "/path/to/.google-calendar-mcp/gcp-oauth.keys.json"
}
}
}
}
Part 4: First Authorization
- Restart Claude Code:
claude - Ask: "What's on my calendar today?"
- Browser opens → Sign in with Google
- Click Continue (ignore "unverified app" warning)
- Grant calendar permissions
- Token saved automatically to
.google-calendar-mcp/token.json
Available Tools
| Tool | Description |
|---|---|
| list-calendars | Enumerate available calendars |
| list-events | Retrieve events with date filtering |
| get-event | Fetch specific event details by ID |
| search-events | Query events by text |
| create-event | Add new calendar events |
| update-event | Modify existing events |
| delete-event | Remove events |
| respond-to-event | Accept/decline/maybe invitations |
| get-freebusy | Check cross-calendar availability |
| get-current-time | Retrieve current date/time in timezone |
| list-colors | View available event colors |
| manage-accounts | Add/list/remove Google accounts |
Features
| Feature | Description |
|---|---|
| Multi-Account | Connect multiple Google accounts |
| Multi-Calendar | Query multiple calendars at once |
| Conflict Detection | Find overlapping events across accounts |
| Full CRUD | Create, read, update, delete events |
| Recurring Events | Manage recurring event patterns |
| Free/Busy | Check availability across calendars |
| Natural Language | Schedule events using natural language |
| Event Import | Import events from images/PDFs/web links |
Environment Variables
| Variable | Description |
|---|---|
| GOOGLE_OAUTH_CREDENTIALS | Path to OAuth credentials file (required) |
| GOOGLE_CALENDAR_MCP_TOKEN_PATH | Custom token storage location (optional) |
MCP Management Commands
# List configured servers
claude mcp list
# Check status (inside Claude Code)
/mcp
# Remove server
claude mcp remove google-calendar
# Get server details
claude mcp get google-calendar
Troubleshooting
| Issue | Solution |
|---|---|
| "Credentials not found" | Check GOOGLE_OAUTH_CREDENTIALS path is correct |
| "Access denied" | Add your email as test user in OAuth consent screen |
| "API not enabled" | Enable Google Calendar API in Cloud Console |
| Token expired | Delete token.json and re-authorize |
| Weekly re-auth required | Publish app to production mode in Cloud Console |
File Locations Summary
| File | Purpose | Location |
|---|---|---|
| gcp-oauth.keys.json | OAuth credentials | ~/.google-calendar-mcp/ |
| token.json | Auth token (auto-created) | ~/.google-calendar-mcp/ |
| ~/.claude.json | Claude Code config | User home directory |
More from salmanferozkhan/cloud-and-fast-api
chainlit
Expert guidance for building conversational AI applications with Chainlit framework in Python. Use when (1) creating chat interfaces for LLM applications, (2) building apps with OpenAI, LangChain, LlamaIndex, or Mistral AI, (3) implementing streaming responses, (4) adding UI elements like images, files, charts, (5) handling user file uploads, (6) implementing authentication (OAuth, password), (7) creating multi-step workflows with visible steps, (8) building RAG applications with document upload, or (9) deploying chat apps to web, Slack, Discord, or Teams.
87sqlmodel
Expert guidance for SQLModel - the Python library combining SQLAlchemy and Pydantic for database models. Use when (1) creating database models that work as both SQLAlchemy ORM and Pydantic schemas, (2) building FastAPI apps with database integration, (3) defining model relationships (one-to-many, many-to-many), (4) performing CRUD operations with type safety, (5) setting up async database sessions, (6) integrating with Alembic migrations, (7) handling model inheritance and mixins, or (8) converting between database models and API schemas.
17fastapi
Expert guidance for building REST APIs with FastAPI framework in Python. Use when (1) creating new FastAPI projects from scratch, (2) implementing API endpoints with routing, (3) working with Pydantic models for validation, (4) setting up dependency injection, (5) implementing authentication (OAuth2, JWT, API keys), (6) integrating databases (SQLAlchemy sync/async), (7) writing tests for FastAPI apps, (8) deploying FastAPI to production (Docker, Gunicorn), or (9) implementing advanced features like WebSockets, middleware, background tasks.
5microsoft-agent-framework
Expert guidance for building AI agents and multi-agent workflows using Microsoft Agent Framework for .NET. Use when (1) creating AI agents with OpenAI or Azure OpenAI, (2) implementing function tools and structured outputs, (3) building multi-turn conversations, (4) designing graph-based workflows with streaming/checkpointing, (5) implementing middleware pipelines, (6) orchestrating multi-agent systems with fan-out/fan-in patterns, (7) adding human-in-the-loop interactions, (8) integrating OpenTelemetry observability, or (9) exposing agents as MCP tools.
3docx
Comprehensive document creation, editing, and analysis with support for tracked changes, comments, formatting preservation, and text extraction. When Claude needs to work with professional documents (.docx files) for: (1) Creating new documents, (2) Modifying or editing content, (3) Working with tracked changes, (4) Adding comments, or any other document tasks
3xlsx
Comprehensive spreadsheet creation, editing, and analysis with support for formulas, formatting, data analysis, and visualization. When Claude needs to work with spreadsheets (.xlsx, .xlsm, .csv, .tsv, etc) for: (1) Creating new spreadsheets with formulas and formatting, (2) Reading or analyzing data, (3) Modify existing spreadsheets while preserving formulas, (4) Data analysis and visualization in spreadsheets, or (5) Recalculating formulas
3