npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@jrg/mcp-google-slides

v0.1.5

Published

MCP server for Google Slides integration

Downloads

381

Readme

Google Slides MCP Server

This project provides a Model Context Protocol (MCP) server for interacting with the Google Slides API. It allows you to create, read, and modify Google Slides presentations programmatically.

Prerequisites

  • Node.js (v18 or later recommended)
  • npm (usually comes with Node.js)
  • Google Cloud Project with the Google Slides API enabled.
  • OAuth 2.0 Credentials downloaded from Google Cloud Console (stored in ~/.gmail-mcp/gcp-oauth.keys.json).

Setup

  1. Clone the repository (if applicable) or ensure you are in the project directory.

  2. Install dependencies:

    npm install
  3. Build the Server: Compile the TypeScript code to JavaScript:

    npm run build

    This will create a build directory containing the compiled JavaScript code.

  4. Obtain and Configure Google API Credentials:

    This server uses file-based authentication stored in ~/.gmail-mcp/ directory (same as Gmail MCP Server for credential reuse).

    Step A: Download OAuth 2.0 Credentials

    • Go to the Google Cloud Console.
    • Create a new project or select an existing one.
    • Navigate to "APIs & Services" > "Enabled APIs & services".
    • Click "+ ENABLE APIS AND SERVICES", search for "Google Slides API", and enable it.
    • Navigate to "APIs & Services" > "Credentials".
    • Click "+ CREATE CREDENTIALS" > "OAuth client ID".
    • If prompted, configure the OAuth consent screen. For "User type", choose "External" unless you have a Google Workspace account and want to restrict it internally. Provide an app name, user support email, and developer contact information.
    • On the "Scopes" page during consent screen setup, click "ADD OR REMOVE SCOPES". Search for and add the following scopes:
      • https://www.googleapis.com/auth/presentations (To view and manage your presentations)
      • https://www.googleapis.com/auth/drive.readonly (To access Drive files)
      • https://www.googleapis.com/auth/gmail.modify (Optional: if you want to reuse credentials with Gmail MCP)
      • https://www.googleapis.com/auth/gmail.settings.basic (Optional: if you want to reuse credentials with Gmail MCP)
    • Save the consent screen configuration.
    • Go back to "Credentials", click "+ CREATE CREDENTIALS" > "OAuth client ID".
    • Select "Desktop app" as the Application type.
    • Give it a name (e.g., "Google MCP Client").
    • Click "Create", then click "DOWNLOAD JSON" to download your OAuth client credentials.

    Step B: Place Credentials File

    • The downloaded JSON file should be renamed to gcp-oauth.keys.json
    • Place it in one of these locations:
      • ~/.gmail-mcp/gcp-oauth.keys.json (recommended - shared with Gmail MCP)
      • OR in the current working directory (it will be automatically copied to ~/.gmail-mcp/)

    Step C: Authenticate (First Time Only)

    • The first time you run the server, it will detect that you don't have credentials and will automatically:
      1. Open your browser to the Google OAuth consent page
      2. Ask you to sign in and grant permissions
      3. Save the tokens to ~/.gmail-mcp/credentials.json
    • After this one-time setup, the server will automatically refresh tokens as needed.

    Reusing Credentials with Gmail MCP: If you already have Gmail MCP Server configured, you can reuse the same credentials! Just ensure both APIs have the required scopes. The credentials in ~/.gmail-mcp/ will work for both servers.

  5. Add to Claude Code:

    Option A: Using Claude Code CLI (Recommended)

    Add the server to Claude Code using the claude mcp add command:

    claude mcp add google-slides-mcp npx -y @jrg/mcp-google-slides

    To verify it was added:

    claude mcp list

    Option B: Manual Configuration

    Locate your MCP settings file. Find or create the entry for "google-slides-mcp":

    "google-slides-mcp": {
      "transportType": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@jrg/mcp-google-slides"
      ]
    }

Running the Server

Execute the compiled code:

npm run start

The server will start and listen for MCP requests on standard input/output (stdio). You should see a message like: Google Slides MCP server running and connected via stdio.

Available Tools

The server exposes the following tools via the Model Context Protocol:

  • create_presentation: Creates a new Google Slides presentation.

    • Input:
      • title (string, required): The title for the new presentation.
    • Output: JSON object representing the created presentation details.
  • get_presentation: Retrieves details about an existing presentation.

    • Input:
      • presentationId (string, required): The ID of the presentation to retrieve.
      • fields (string, optional): A field mask (e.g., "slides,pageSize") to limit the returned data.
    • Output: JSON object representing the presentation details.
  • batch_update_presentation: Applies a series of updates to a presentation. This is the primary method for modifying slides (adding text, shapes, images, creating slides, etc.).

    • Input:
      • presentationId (string, required): The ID of the presentation to update.
      • requests (array, required): An array of request objects defining the updates. Refer to the Google Slides API batchUpdate documentation for the structure of individual requests.
      • writeControl (object, optional): Controls write request execution (e.g., using revision IDs).
    • Output: JSON object representing the result of the batch update.
  • get_page: Retrieves details about a specific page (slide) within a presentation.

    • Input:
      • presentationId (string, required): The ID of the presentation containing the page.
      • pageObjectId (string, required): The object ID of the page (slide) to retrieve.
    • Output: JSON object representing the page details.
  • summarize_presentation: Extracts and formats all text content from a presentation for easier summarization.

    • Input:
      • presentationId (string, required): The ID of the presentation to summarize.
      • include_notes (boolean, optional): Whether to include speaker notes in the summary. Defaults to false.
    • Output: JSON object containing:
      • title: The presentation's title
      • slideCount: Total number of slides
      • lastModified: Revision information
      • slides: Array of slide objects containing:
        • slideNumber: Position in presentation
        • slideId: Object ID of the slide
        • content: All text extracted from the slide
        • notes: Speaker notes (if requested and available)

(More tools can be added by extending src/index.ts)