logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

g-suite-api-orchestrator

Programmatic interface for interfacing with Gmail and Google Calendar services. Facilitates operations like retrieving, querying, dispatching, and modifying electronic messages, alongside creating, refreshing, and retiring scheduled agenda entries.

Author

g-suite-api-orchestrator logo

epaproditus

MIT License

Quick Info

GitHub GitHub Stars 26
NPM Weekly Downloads 0
Tools 1
Last Updated 2026-02-19

Tags

gmailcalendarapisgmail calendarinteract gmailemails calendar

Google Workspace MCP Server Adapter

This Model Context Protocol (MCP) adapter furnishes utilities for seamless integration with the Gmail and Calendar Application Programming Interfaces (APIs). It empowers automated management of correspondence and scheduling via the MCP framework.

Capabilities

Electronic Mail Functions (Gmail)

  • list_emails: Retrieve a manifest of recent inbox items, supporting fine-grained selection criteria.
  • search_emails: Execute sophisticated queries against messages utilizing Gmail's specialized search syntax.
  • send_email: Compose and dispatch new electronic correspondence, complete with optional carbon copy (CC) and blind carbon copy (BCC) destinations.
  • modify_email: Adjust message metadata, such as applying/removing tags (e.g., archiving, trashing, marking as read/unread).

Scheduling Functions (Calendar)

  • list_events: Fetch a chronological series of upcoming scheduled occurrences, filterable by specified time windows.
  • create_event: Institute novel agenda appointments, including attendee specifications.
  • update_event: Apply revisions to pre-existing scheduled items.
  • delete_event: Permanently remove defined calendar occurrences.

Initial Requirements

  1. Runtime Environment: Installation of Node.js, version 14 or newer.
  2. Google Cloud Configuration:
  3. Navigate to the Google Cloud Console.
  4. Establish a new project or select an existing one.
  5. Activate the necessary APIs:
    1. Access "APIs & Services" > "Library".
    2. Locate and enable "Gmail API".
    3. Locate and enable "Google Calendar API".
  6. Configure OAuth 2.0 Credentials:
    1. Proceed to "APIs & Services" > "Credentials".
    2. Select "Create Credentials" > "OAuth client ID".
    3. Designate the application type as "Web application".
    4. Ensure the "Authorized redirect URIs" list includes: http://localhost:4100/code.
    5. Carefully record the generated Client ID and Client Secret.

Deployment Steps

  1. Acquire and Install Dependencies: bash git clone https://github.com/epaproditus/google-workspace-mcp-server.git cd google-workspace-mcp-server npm install

  2. Establish Credentials File: Generate a file named credentials.json in the repository's root directory with the following structure:

{ "web": { "client_id": "YOUR_CLIENT_ID", "client_secret": "YOUR_CLIENT_SECRET", "redirect_uris": ["http://localhost:4100/code"], "auth_uri": "https://accounts.google.com/o/oauth2/auth", "token_uri": "https://oauth2.googleapis.com/token" } }

  1. Obtain Refresh Token: Execute the following script: bash node get-refresh-token.js

This action initiates: - A web browser prompt for Google authentication. - A request for the following access permissions (scopes): - https://www.googleapis.com/auth/gmail.modify - https://www.googleapis.com/auth/calendar - https://www.googleapis.com/auth/gmail.send - Persistence of the authorization data into token.json. - Output of the necessary refresh token to the terminal.

  1. MCP Configuration Integration: Incorporate the server connection details into your designated MCP configuration file:
  2. VSCode Integration Path: ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
  3. Claude Desktop Path: ~/Library/Application Support/Claude/claude_desktop_config.json

Insert the following structure within the mcpServers object:

{ "mcpServers": { "google-workspace": { "command": "node", "args": ["/path/to/google-workspace-server/build/index.js"], "env": { "GOOGLE_CLIENT_ID": "your_client_id", "GOOGLE_CLIENT_SECRET": "your_client_secret", "GOOGLE_REFRESH_TOKEN": "your_refresh_token" } } } }

  1. Compile and Initiate Service: bash npm run build

Operational Illustrations

Gmail Functions Examples

  1. Listing Recent Messages:

{ "maxResults": 5, "query": "is:unread" }

  1. Message Search:

{ "query": "from:example@gmail.com has:attachment", "maxResults": 10 }

  1. Dispatching Correspondence:

{ "to": "recipient@example.com", "subject": "Greetings", "body": "The message content.", "cc": "cc@example.com", "bcc": "bcc@example.com" }

  1. Message Tag Manipulation:

{ "id": "message_id", "addLabels": ["UNREAD"], "removeLabels": ["INBOX"] }

Calendar Functions Examples

  1. Retrieving Appointments:

{ "maxResults": 10, "timeMin": "2024-01-01T00:00:00Z", "timeMax": "2024-12-31T23:59:59Z" }

  1. Scheduling a New Event:

{ "summary": "Team Synchronization", "location": "Virtual Venue", "description": "Weekly status update session", "start": "2024-01-24T10:00:00Z", "end": "2024-01-24T11:00:00Z", "attendees": ["colleague@example.com"] }

  1. Modifying an Existing Appointment:

{ "eventId": "event_id", "summary": "Revised Session Title", "location": "Physical Location", "start": "2024-01-24T11:00:00Z", "end": "2024-01-24T12:00:00Z" }

  1. Eliminating an Appointment:

{ "eventId": "event_id" }

Issue Resolution

  1. Authorization Failures:
  2. Confirm that all requisite OAuth scopes have been successfully granted.
  3. Double-check the accuracy of the client identifier and secret.
  4. Validate the current validity of the stored refresh token.

  5. API Operational Errors:

  6. Investigate the Google Cloud Console to review API rate limits and quotas.
  7. Ensure the targeted APIs are explicitly enabled for the associated project.
  8. Confirm request payloads adhere precisely to the mandated parameter specifications.

Licensing

This software is distributed under the terms of the MIT License.

== Organizational Performance Enhancement Methods == Business operational systems encompass the frameworks, software, control mechanisms, calculation engines, and procedural guidelines utilized by organizations to maintain market agility, secure competitive standing, and elevate overall operational efficacy. These mechanisms facilitate adaptation to shifting commercial landscapes.

=== Functional Categorization Overview === Management tools can be segmented based on departmental needs across various operational dimensions, such as: strategic forecasting, workflow management, documentation control, personnel administration, strategic deliberation aids, oversight mechanisms, and performance measurement systems. A functional taxonomy often distinguishes these aspects:

Tools designed for data ingestion and verification across any organizational unit. Mechanisms focused on regulating and refining intra-company workflows. Instruments utilized for aggregating information to support high-level decision-making. Modern management utilities have undergone profound transformations in the recent decade, driven by rapid technological advancements. This proliferation makes selecting optimal business instruments for a specific corporate context increasingly challenging. This complexity is fueled by continuous pressure to reduce expenditures, maximize revenue generation, deeply understand client demands, and deliver requisite products in the preferred manner. In this environment, managerial focus should prioritize a strategic approach to adopting management mechanisms rather than merely chasing the newest available application. Often, managers implement tools without tailoring them to existing structures, leading to operational instability. Therefore, business management instruments must be chosen deliberately and then meticulously customized to fit the organization's specific requirements, reversing the common approach.

== Prevalent Tools (2013 Survey Insights) == A 2013 investigation by Bain & Company illustrated the global adoption patterns of business utilities, reflecting how their resultant benefits align with regional necessities, considering market fluctuations. The leading ten instruments identified included:

Strategic foresight planning Client relationship stewardship (CRM) Personnel sentiment assessment programs Comparative industry analysis (Benchmarking) Performance measurement frameworks (Balanced Scorecard) Identification of core organizational strengths External resource allocation (Outsourcing) Programs for managing organizational transitions Logistics and material flow oversight (SCM) Formal articulation of corporate objectives (Mission/Vision statements) Customer base subdivision Comprehensive standards adherence programs (TQM)

== Commercial Software Solutions == Software or integrated suites employed by enterprise personnel to execute diverse commercial functions are termed business applications. These solutions aim to augment productivity metrics, quantify output efficiency, and execute various corporate functions with precision. The evolution progressed from foundational Management Information Systems (MIS) to comprehensive Enterprise Resource Planning (ERP) systems. Subsequently, Customer Relationship Management (CRM) capabilities were integrated, ultimately leading to the current landscape dominated by cloud-based enterprise administration platforms. While a verifiable relationship exists between IT investment and organizational performance, two elements are crucial multipliers: the efficacy of the deployment process and the rigorous selection and customization of the chosen instrument set.

== Specialized Resources for Small and Medium Enterprises (SMEs) == Resources tailored for SMEs are vital as they furnish cost-effective avenues for operational optimization, enabling these entities to compete effectively against larger corporations by streamlining processes and improving resource allocation.

See Also

`