<!-- Use this file to provide workspace-specific custom instructions to Copilot. For more details, visit https://code.visualstudio.com/docs/copilot/copilot-customization#_use-a-githubcopilotinstructionsmd-file -->
# Google Calendar MCP Server Copilot Instructions
This is a Model Context Protocol (MCP) server project for Google Calendar integration. Please follow these guidelines when working with this codebase:
## Project Overview
- This is an MCP server that provides tools for Google Calendar API integration
- Built with TypeScript and uses the @modelcontextprotocol/sdk
- Handles OAuth authentication, event management, and calendar operations
- Follows the Model Context Protocol specification
## MCP Resources
You can find more info and examples at https://modelcontextprotocol.io/llms-full.txt
## Code Guidelines
1. **TypeScript Best Practices**: Use strict typing, proper error handling, and follow the existing code patterns
2. **MCP Protocol**: All tools must follow the MCP tool schema format with proper input validation using Zod
3. **Google Calendar API**: Use the googleapis library and handle authentication properly
4. **Error Handling**: Return structured error responses that follow the MCP format
5. **Security**: Never expose sensitive credentials in logs or responses
## Tool Development
When adding new tools:
- Define proper Zod schemas for input validation
- Create corresponding ToolSchema definitions
- Implement async handlers with proper error handling
- Return structured responses with success/error states
- Add comprehensive JSDoc comments
## Authentication
- Uses Google Service Account authentication
- Environment variables are loaded from .env file
- Handle token refresh and error scenarios gracefully
## Testing
- Test all tools manually using MCP-compatible clients
- Validate input schemas and error cases
- Ensure proper integration with Google Calendar API