To connect Dex to your Google Workspace environment, you need to configure a Google Cloud service account with domain-wide delegation.
Steps
1Go to the Google Cloud Console and create a new project or select an existing one.
2Navigate to APIs & Services > Library, search for Admin SDK API, and click Enable.
3Go to IAM & Admin > Service Accounts and click Create Service Account; give it a name (e.g., dex-management-sa), click Create and Continue, skip optional permissions, and click Done.
4Select the service account, go to the Keys tab, click Add Key > Create new key, select JSON, and download the key file.
5Open the JSON key file — you will need the client_email (Service Account Email), the private_key (Private Key PEM), and the client_id.
6Open the Google Workspace Admin Console and go to Security > Access and data control > API controls.