Google Mail OAuth Integration Guide
Google OAuth Setup for Gmail Integration with Knit
This guide walks you through creating your own Google OAuth App in Google Cloud Console so your users will see your brand and logo when integrating Gmail with Knit.
Step 1: Create a Google Cloud Project
- Login or Sign up at Google Cloud Console
- Create a new project (if you don’t already have one)
→ Refer: Create a Google Cloud Project | Google for Developers
Step 2: Enable Gmail API
- In the left sidebar, go to APIs & Services → Library
- Search for Gmail API and click Enable

Step 3: Configure OAuth Consent Screen
- Navigate to APIs & Services → OAuth consent screen
- Under User Type, choose Internal and click Create
- Fill in your App name, support email, and branding details
- Upload your company logo (optional but recommended)

Step 4: Create OAuth Client Credentials
-
Go to APIs & Services → Credentials
-
Click Create Credentials → OAuth Client ID
-
Select Web application as the application type
-
Provide a name (e.g., “Knit Gmail OAuth”)
-
Under Authorized redirect URIs, add:
https://app.getknit.dev/oauth/authorize
-
Click Create
You'll receive a Client ID and Client Secret — these are required for integrating Gmail with Knit.
Step 5: Add Gmail Scopes
To enable Gmail integration, you need to add specific OAuth scopes under the "Scopes" section of the OAuth consent screen.
At a minimum, you must include the following scopes:
https://www.googleapis.com/auth/gmail.readonly
https://www.googleapis.com/auth/userinfo.email
📘 Additional Scopes (Optional)
Depending on your use case and the type of Gmail data or actions you want to enable, you can add additional scopes when configuring your OAuth app.
Refer to this guide to understand which scopes are required for different Gmail APIs and Knit features: View Gmail Scopes Guide
Step 6: Copy Client ID & Secret
After creating your credentials, your Client ID and Client Secret will be shown. Copy and securely store them — they are required to authenticate Gmail integrations with Knit.

Updated about 5 hours ago