Google Workspace
Why Google Workspace is the holy grail
If you’re like me, you probably run your life using Google Workspace. Letting Hermes draft emails, schedule meetings, and edit your Google Docs makes it much more useful.
However, I have to warn you that the setup process is pretty painful. If you do not believe me, just ask Hermes:
How do I connect you to Google Workspace: Gmail, Calendar, Docs, Sheets, Slides, and Drive? List the steps.It is going to give you a very, very long list of steps. Do not be overwhelmed. I will walk you through it with some humor in the steps below.
It is worth it, I promise.
Connect Hermes to Google Workspace
1. Open Google Cloud Console
Go to Google Cloud Console and sign in with your Google account.
2. Create a Google Cloud project
On the top bar, click the Project Picker and select New project.
Call it:
HermesFollow the steps to create the new project.
This is the Google app that lets Hermes connect to your Gmail, Calendar, Drive, Docs, and Sheets.
Select the project you just created before moving on.
3. Enable the APIs
In the search box, search for and select the following APIs one by one:
- Gmail API
- Google Calendar API
- Google Drive API
- Google Docs API
- Google Sheets API
On each API page, select Enable. Then search for the next API, go to the page, and hit Enable again. Repeat until you have enabled all the APIs above.
Google makes this annoying, but this part is normal.
4. Set up OAuth consent
Now go to the OAuth Overview screen and hit Get Started.
Enter the following in the form:
- App name: Hermes
- User support email: your email
- Audience: External
- Contact email: your email
My recommendation: Do not worry about sharing your real email. You can also use the email you made for your bot. Either way, there will not be any users of this app except for you.
Agree to the terms and hit Create.
If you did everything right, you should see this screen:
Click Create OAuth client. Then use these settings:
- Application type: Desktop app
- Name: Hermes Desktop
- Click Create
You should now see the OAuth client created screen.
Important: Do not close this screen before you hit the button to download the JSON file.
It should look something like this:
client_secret_1234567890.jsonYou can close the dialog box after you download the file.
5. Set up test users
Now go to the Audience tab, scroll down to Test users, hit Add users, and add your email as a test user.
Do not skip this. If you skip it, Google may block you later with an “access denied” error.
6. Give the JSON file to Hermes
Go back to Hermes and either drag and drop the JSON file into its chat or tell it where it is:
The Google client JSON is at /Users/peter/Downloads/client_secret_1234567890.jsonHermes will do a bunch of setup work afterward.
7. Sign in and approve access
Hermes will give you a Google sign-in link. Open it, sign in, and approve access.
Google may show a scary “Google hasn’t verified this app” warning. That is normal for a private app you just made. Make sure you grant all the permissions it requests.
8. Paste the final URL back into Hermes
After approval, your browser may land on a broken-looking page with a URL like:
http://localhost:1/?code=...This is expected. Nothing is broken.
Copy the entire URL from the browser address bar and paste it back into Hermes.
Use Google Workspace in Hermes
I know that was very painful, but now Hermes really is much more useful. Try asking it things like:
Read my Gmail and let me know what I should unsubscribe from.What meetings do I have today?Book a meeting for me tomorrow at 10am.Edit this Google Doc to do X: [link to doc]
This gets even more powerful when you set up cron jobs that can do Google Workspace tasks automatically. We will talk about that in the cron jobs section.