Google Services OAuth (Individual Setup)
This guide is for one person running MindRoom and creating their own Google OAuth app.
For team/shared deployments, use Google Services OAuth (Admin Setup).
What You Need Before Starting
- A Google account
- Access to Google Cloud Console
- A running MindRoom instance with the bundled dashboard (default URL:
http://localhost:8765)
The callback path is always:
So the default full callback URL is:
Step 1: Create Google Cloud Project
- Open Google Cloud Console.
- Create or select a project.
- Save the project ID for
GOOGLE_PROJECT_ID.
Step 2: Enable APIs
- Go to APIs & Services → Library.
- Enable:
- Gmail API
- Google Calendar API
- Google Drive API
- Google Sheets API
Step 3: Configure OAuth Consent Screen
- Go to APIs & Services → OAuth consent screen.
- Choose
External. - Fill required fields and save.
- Add your own email as a test user.
- Add scopes:
https://www.googleapis.com/auth/gmail.readonlyhttps://www.googleapis.com/auth/gmail.modifyhttps://www.googleapis.com/auth/gmail.composehttps://www.googleapis.com/auth/calendarhttps://www.googleapis.com/auth/spreadsheetshttps://www.googleapis.com/auth/drive.fileopenidhttps://www.googleapis.com/auth/userinfo.emailhttps://www.googleapis.com/auth/userinfo.profile
Step 4: Create OAuth Client ID
- Go to APIs & Services → Credentials.
- Click Create Credentials → OAuth client ID.
- Choose Web application.
- Add redirect URI:
http://localhost:8765/api/google/callback- Copy client ID and client secret.
Step 5: Configure MindRoom
Add this to .env (or export in your shell):
MINDROOM_PORT=8765
GOOGLE_CLIENT_ID=your-client-id.apps.googleusercontent.com
GOOGLE_CLIENT_SECRET=your-client-secret
GOOGLE_PROJECT_ID=your-project-id
GOOGLE_REDIRECT_URI=http://localhost:8765/api/google/callback
Restart MindRoom.
Step 6: Verify MindRoom Reads Credentials
Run:
Expected:
- "has_credentials": true
Step 7: Connect in Frontend
- Open Integrations → Google Services.
- Click Login with Google.
- Sign in and approve requested scopes.
- You should see Connected and your available services.
Step 8: Enable Google Tools in config.yaml
After OAuth is connected, add Google tools to your agent config:
agents:
email_assistant:
display_name: Email Assistant
role: Help manage and respond to emails
tools:
- gmail
- google_calendar
- google_sheets
instructions:
- Search important unread emails first.
- Draft replies and ask for confirmation before sending.
Gmail tool capabilities include:
- gmail_search: Search emails with Gmail query syntax (for example is:unread or from:boss@company.com)
- gmail_latest: Read latest inbox emails
- gmail_unread: Read unread emails only
After editing config.yaml, restart MindRoom to reload configuration.
Disconnect Later (Optional)
- In MindRoom frontend, click Disconnect Google Account.
- Optional: also revoke app access in Google Account Permissions.
Troubleshooting
"Admin Setup Required" shown in frontend
MindRoom does not have valid Google OAuth env vars yet.
"Failed to complete OAuth flow"
Check redirect URI exact match between Google Cloud Console and MindRoom.
Access blocked by Google
If your app is in testing mode, ensure your account is listed as a test user.