Google OAuth2 Setup Guide
Complete step-by-step guide to configure Google OAuth2 client ID for the QuickERP Chrome extension.
Prerequisites
- Google account
- Access to Google Cloud Console
Step 1: Create Google Cloud Project
- 1Go to Google Cloud Console
- 2Click "Select a project" → "New Project"
- 3Enter project name:
IIT-KGP-ERP-Extension(or your preferred name) - 4Click "Create"
Step 2: Enable Required APIs
- 1In the project dashboard, go to "APIs & Services" → "Library"
- 2Search for and enable these APIs:
- Gmail API - Required for reading OTP emails
- Google+ API - Required for user profile information
- 3Click on each API and click "Enable"
Gmail Account Requirement
Currently, QuickERP only supports @gmail.com accounts. Make sure to connect with a Gmail account during setup, not other Google Workspace or custom domain emails.
Note
Google+ API is needed even though it's deprecated, as it still handles the userinfo scopes used by Chrome extensions.
Step 3: Configure OAuth Consent Screen
Initial Setup
- 1Go to "APIs & Services" → "OAuth consent screen"
- 2Select "External" user type (unless you have Google Workspace)
- 3Click "Create"
Required Information
- App name:
QuickERP - User support email: Your email address
- App logo: (Optional) Upload extension icon
- App domain: Leave blank for Chrome extensions
- Developer contact information: Your email address
Add Scopes
- 1Click "Add or Remove Scopes"
- 2Add these scopes:
• https://www.googleapis.com/auth/userinfo.email • https://www.googleapis.com/auth/userinfo.profile • https://www.googleapis.com/auth/gmail.readonly • openid
Important
In the scope justification field for gmail.readonly, add:
"Required to automatically read OTP verification codes from ERP system emails. Without this permission, the extension cannot function."
Step 4: Create OAuth2 Client ID
- 1Go to "APIs & Services" → "Credentials"
- 2Click "Create Credentials" → "OAuth client ID"
- 3Select "Chrome extension" as application type
- 4Name:
QuickERP Extension Client - 5Application ID: Enter your Chrome extension ID
If you don't have it yet, use a placeholder like
abcdefghijklmnopqrstuvwxyzabcdef
Step 5: Update manifest.json
After creation, copy the Client ID and update your extension's manifest.json:
{
"oauth2": {
"client_id": "YOUR_CLIENT_ID_HERE.apps.googleusercontent.com",
"scopes": [
"https://www.googleapis.com/auth/userinfo.email",
"https://www.googleapis.com/auth/userinfo.profile",
"https://www.googleapis.com/auth/gmail.readonly",
"openid"
]
}
}Quick Tips
- Use minimal required scopes for security
- Add test users during development
- Monitor API usage in console
- Never commit client secrets
Publishing
Development/Testing:
- • Add test users to OAuth consent
- • Works only for test users
- • No verification required
Public Release:
- • Google verification required
- • Privacy policy needed
- • May take several days