@teamsparta/mcp-server-google-calendar
v1.0.3
Published
MCP server for interacting with Google Calendar
Maintainers
Keywords
Readme
Google Calendar MCP Server
MCP Server for the Google Calendar API, enabling Claude to interact with Google Calendar to manage events and find free time slots.
🚀 Quick Setup
For All
Download OAuth Credentials (2 minutes)
- Go to Google Cloud Console (url은 1password의 'google calendar mcp google cloud url'를 참고)
- Download the JSON file of 'Google Calendar MCP 용 데스크톱 클라이언트 1'
For Project Maintainers
Clone the Repository (1 minute)
git clone https://github.com/TeamSparta-Inc/mcp.git cd mcp npm installRun Setup Script (1 minute)
cd src/google-calendar node setup-credentials.js /path/to/oauth-file.jsonConfigure Claude Desktop - Copy the config the script shows you
For Teammates
Run Setup Script (1 minute)
npx @teamsparta/mcp-server-google-calendar gcalendar-setup /path/to/oauth-file.jsonConfigure Claude Desktop - Copy the config the script shows you
🎯 What You Can Do
Once set up, ask Claude to:
- Find free time across team calendars
- Schedule meetings with teammates
- Check availability before planning events
- Create/update/delete calendar events
Example Commands
"Find a 1-hour slot next week when me, [email protected], and [email protected] are all free"
"Schedule a team standup tomorrow at 10 AM with the whole team"
"What meetings do I have today?"
🔧 Available Tools
- google_calendar_list_calendars - List all accessible calendars
- google_calendar_list_events - List events from a specific calendar within a time range
- google_calendar_fetch_event - Fetch details of a specific event
- google_calendar_get_busy_times - Get busy time periods across multiple calendars
- google_calendar_find_free_time - Find available time slots across multiple calendars
- google_calendar_create_event - Create a new calendar event
- google_calendar_update_event - Update an existing calendar event
- google_calendar_delete_event - Delete a calendar event
Tool Examples
Find Free Time for Team Meetings
google_calendar_find_free_time({
calendarIds: ["primary", "[email protected]", "[email protected]"],
timeMin: "2024-01-15T09:00:00Z",
timeMax: "2024-01-15T18:00:00Z",
duration: 60,
});Create Team Events
google_calendar_create_event({
summary: "Team Standup",
start: "2024-01-15T10:00:00+09:00",
end: "2024-01-15T10:30:00+09:00",
attendees: ["[email protected]", "[email protected]"],
location: "Conference Room A",
});Check Availability
google_calendar_get_busy_times({
calendarIds: ["primary", "[email protected]"],
timeMin: "2024-01-15T09:00:00Z",
timeMax: "2024-01-15T18:00:00Z",
});⚙️ Configuration
Claude Desktop Config
{
"mcpServers": {
"google-calendar": {
"command": "npx",
"args": ["-y", "@teamsparta/mcp-server-google-calendar"],
"env": {
"GOOGLE_CREDENTIALS_PATH": "/path/to/gcalendar-server-credentials.json"
}
}
}
}Alternative: Individual Environment Variables
{
"mcpServers": {
"google-calendar": {
"command": "npx",
"args": ["-y", "@teamsparta/mcp-server-google-calendar"],
"env": {
"GOOGLE_CLIENT_ID": "your-client-id",
"GOOGLE_CLIENT_SECRET": "your-client-secret",
"GOOGLE_ACCESS_TOKEN": "your-access-token",
"GOOGLE_REFRESH_TOKEN": "your-refresh-token"
}
}
}
}🔄 Token Management
- Access tokens expire after ~1 hour
- Refresh tokens last much longer (months/years)
- Automatic refresh - The server automatically refreshes expired tokens
- Auto-save - Updated tokens are saved back to the credentials file
- One-time setup - Teammates rarely need to re-run setup
💡 Pro Tips
- Credentials file location: Put it somewhere permanent like
~/.config/or~/Documents/ - Calendar IDs: Use
google_calendar_list_calendarsto find available calendars - Shared calendars: Calendar IDs are usually email addresses (e.g.,
[email protected]) - Time format: Use ISO 8601 format (
2024-01-15T10:00:00+09:00) - Timezone: Server uses Asia/Seoul timezone by default
🆘 Troubleshooting
Setup Issues
- Script fails: Make sure you downloaded OAuth credentials (not service account)
- File not found: Check the file path is correct
- Port in use: Wait a moment and try again
Authentication Errors
- Token expired: Re-run the setup script to refresh tokens
- Permission denied: Ensure OAuth app has calendar scope
- Credentials file: Make sure the path in your config is correct
Calendar Issues
- Calendar not found: Use
list_calendarsto verify calendar IDs - No access: Make sure you have access to shared calendars
- Time format error: Use ISO 8601 format
Getting Calendar IDs
- Use
google_calendar_list_calendarsto see all accessible calendars - For shared calendars, the ID is usually the email address
- For resource calendars (meeting rooms), use the resource email
🐳 Docker Support
Build:
docker build -t mcp/google-calendar -f src/google-calendar/Dockerfile .Run:
docker run -i --rm \
-e GOOGLE_CREDENTIALS_PATH=/credentials.json \
-v /path/to/credentials.json:/credentials.json \
mcp/google-calendar📋 Requirements
- Node.js 18+
- Google Cloud Project with Calendar API enabled
- OAuth 2.0 credentials
🌍 Cross-Platform
Works on:
- ✅ macOS
- ✅ Windows
- ✅ Linux
📄 License
MIT License - see LICENSE file for details.
