Skip to main content
This guide walks you through obtaining all required credentials for the Google Sheets plugin.

Authentication Method

The Google Sheets plugin uses OAuth 2.0 authentication exclusively.
  • oauth_2 (default) - OAuth 2.0 authentication

OAuth 2.0 Setup

Step 1: Create Google Cloud Project

  1. Go to Google Cloud Console
  2. Click Select a projectNew Project
  3. Enter a project name and click Create
  4. Wait for the project to be created and select it

Step 2: Enable Google Sheets API

  1. In the Google Cloud Console, go to APIs & ServicesLibrary
  2. Search for “Google Sheets API”
  3. Click on Google Sheets API
  4. Click Enable

Step 3: Create OAuth 2.0 Credentials

  1. Go to APIs & ServicesCredentials
  2. Click Create CredentialsOAuth client ID
  3. If prompted, configure the OAuth consent screen:
    • Choose External (unless you have a Google Workspace)
    • Fill in the required information:
      • App name
      • User support email
      • Developer contact information
    • Add scopes:
      • https://www.googleapis.com/auth/spreadsheets
    • Add test users (for testing)
    • Click Save and Continue through all steps
  4. Select Web application
  5. Configure:
    • Name: Your application name
    • Authorized redirect URIs: Add your callback URL (e.g., https://yourapp.com/auth/googlesheets/callback)
  6. Click Create
  7. Copy the Client ID and Client Secret
  8. Store these securely
Storing Credentials: Store your OAuth app credentials, then start the flow:
pnpm corsair setup --plugin=googlesheets client_id=your-client-id client_secret=your-client-secret
pnpm corsair auth --plugin=googlesheets
The CLI will print an authorization URL — open it in a browser. Once you approve, tokens are saved automatically. To verify credentials were stored:
pnpm corsair auth --plugin=googlesheets --credentials

Required Credentials Summary

CredentialRequired ForWhere to Find
Client IDOAuth 2.0Google Cloud Console → APIs & Services → Credentials
Client SecretOAuth 2.0Google Cloud Console → APIs & Services → Credentials
Access TokenOAuth 2.0Obtained automatically after OAuth flow
Refresh TokenOAuth 2.0Obtained automatically after OAuth flow
For general information about how Corsair handles authentication, see Authentication.