Google Sheets API MCP Server logo

Google Sheets API MCP Server

by mattcoatsworth

A comprehensive Model Context Protocol (MCP) server for interacting with the Google Sheets API. This server provides tools and resources for managing spreadsheets, sheets, values, and developer metadata.

View on GitHub

Last updated: N/A

What is Google Sheets API MCP Server?

This server is a Model Context Protocol (MCP) server designed to facilitate interaction with the Google Sheets API. It provides a set of tools and resources for managing spreadsheets, sheets, values, and developer metadata within Google Sheets.

How to use Google Sheets API MCP Server?

To use this server, you need to clone the repository, install the dependencies using npm install, configure your Google API credentials in a .env file, and then start the server using npm start. You can then interact with the server using MCP Inspector or by making direct API calls to the available resources.

Key features of Google Sheets API MCP Server

  • Create, read, update, and delete spreadsheets

  • Manage sheets within spreadsheets

  • Read, write, append, and clear values

  • Work with developer metadata

  • Access spreadsheet data through MCP resources

  • OAuth 2.0 authentication

Use cases of Google Sheets API MCP Server

  • Automating spreadsheet management tasks

  • Integrating Google Sheets data with other applications

  • Building custom reporting dashboards

  • Programmatically updating and retrieving data from Google Sheets

FAQ from Google Sheets API MCP Server

What is MCP?

MCP stands for Model Context Protocol, a protocol for accessing and manipulating data.

What are the prerequisites for running this server?

You need Node.js 16 or higher, a Google Cloud Platform project with the Google Sheets API enabled, and OAuth 2.0 credentials.

How do I authenticate with the Google Sheets API?

You need to provide your Google API client ID, client secret, redirect URI, and refresh token in the .env file.

How do I create a new spreadsheet?

You can use the createSpreadsheet tool or the corresponding MCP resource.

How do I get values from a range?

You can use the getValues tool or the sheets://spreadsheet/{spreadsheetId}/values/{range} resource.