Skip to main content
The Google Workspace integration lets Sofie use Gmail, Google Calendar, and Google Drive when your organization enables the provider and a user connects their account. Use this guide if you administer Google Cloud or Google Workspace apps for your organization.

What Sofie can use

Depending on permissions and user consent, Sofie may use Google Workspace to:
  • Search and read Gmail messages.
  • Draft and send Gmail messages after review.
  • Read Google Calendar events.
  • Create calendar events after review.
  • Search Google Drive files.
  • Import useful Drive files into a Workspace.

Before you start

You need:
  • Access to the Google Cloud project used for Sofie OAuth.
  • Permission to configure the OAuth consent screen.
  • Permission to create OAuth client credentials.
  • The Sofie domain users open in the browser.
  • Access to Sofie Organization Settings > Integrations.

Redirect URI

Add this authorized redirect URI to the Google OAuth client:
https://<your-sofie-domain>/api/integrations/callback/google
Use the exact Sofie domain for the environment. Add staging and production redirect URIs separately when needed.
1

Open Google Cloud Console

Open the Google Cloud project that should own the Sofie OAuth app.
2

Open OAuth consent

Go to APIs & Services and open the OAuth consent or branding area shown by your Google Cloud Console.
3

Choose user type

Choose the user type your organization requires. Internal apps are typically limited to your Google Workspace organization.
4

Add application details

Add the app name, support email, authorized domains, and contact information.
5

Add scopes

Add only the Gmail, Calendar, Drive, and profile scopes your organization wants Sofie to use.
6

Add test users if needed

If the app is still in testing, add test users before asking them to connect.
Google reference: OAuth 2.0 for web server applications.

Create the OAuth client

1

Open Credentials

In Google Cloud Console, go to APIs & Services > Credentials.
2

Create OAuth client ID

Choose Create credentials > OAuth client ID.
3

Choose Web application

Select Web application as the application type.
4

Add redirect URI

Add https://<your-sofie-domain>/api/integrations/callback/google under authorized redirect URIs.
5

Copy credentials

Copy the client ID and client secret.

Enable Google APIs

Enable the APIs that match the Sofie capabilities you want to support:
  • Gmail API.
  • Google Calendar API.
  • Google Drive API.
Google API references:

Configure scopes

Sofie may request scopes for the capabilities your organization enables.
CapabilityGoogle scope examples
Gmail read and searchhttps://www.googleapis.com/auth/gmail.readonly
Gmail sendhttps://www.googleapis.com/auth/gmail.send
Calendar readhttps://www.googleapis.com/auth/calendar.readonly
Calendar event writehttps://www.googleapis.com/auth/calendar.events
Drive file readhttps://www.googleapis.com/auth/drive.readonly
Drive metadatahttps://www.googleapis.com/auth/drive.metadata.readonly
User profilehttps://www.googleapis.com/auth/userinfo.email, https://www.googleapis.com/auth/userinfo.profile
Some Google scopes may require additional review or verification by Google depending on your app configuration and audience. Confirm requirements in Google Cloud before rolling out broadly.

Add values in Sofie

In Sofie, go to Organization Settings > Integrations and open Google. Enter:
Sofie fieldGoogle value
Client IDOAuth client ID.
Client SecretOAuth client secret.
Enable Google and save settings.

Test the connection

1

Connect a test user

Use a Google Workspace account with representative access.
2

Review the consent screen

Confirm the requested scopes match the capabilities you expect.
3

Test Gmail

Ask Sofie to search a known test email thread.
4

Test Calendar

Ask Sofie to find or draft a test event.
5

Test Drive

Ask Sofie to find a known Drive file and recommend whether it should be imported into a Workspace.

User prompt examples

Search Google Drive for protocol drafts that mention media fill acceptance criteria. Do not import anything yet. Return file name, date, likely relevance, and question to confirm.
Find Google Calendar meetings next week with the validation team and draft a proposed agenda. Do not create an event yet.
Search Gmail for recent messages about release assay readiness. Summarize open questions and list sender, date, and thread title.

Troubleshooting

Confirm Google is enabled in Sofie, the OAuth client is a web application, the redirect URI matches exactly, and the user is allowed by the consent screen configuration.
Check the OAuth consent screen status, test user list, authorized domains, and whether Google requires verification for the requested scopes.
Confirm the user can access the file directly in Google Drive and that the integration includes Drive read or metadata scopes.
Confirm the matching Gmail or Calendar API is enabled and the requested scope is included in the OAuth app configuration.

Official Google references