
Prerequisites
To follow this guide, you need:- A GCP project with BigQuery enabled
- Permissions to create a service account and assign roles in your project
- An Openlayer project with monitoring mode enabled
Setup Guide
Step 1: Create a service account
Create a dedicated service account in your GCP project for Openlayer to use:Step 2: Grant required roles
Grant the following roles to the new service account:roles/bigquery.jobUser
: run queriesroles/bigquery.dataViewer
: read table dataroles/bigquery.metadataViewer
: read metadata
Step 3: Allow Openlayer to impersonate your service account
Grant Openlayer’s service account permission to impersonate yours:Step 4: Connect inside Openlayer
In your Openlayer workspace:- Go to Data sources and select BigQuery.
- Click Connect.
- Fill in the fields:
- Target principal: your service account email
(e.g.
openlayer-bigquery@your-project-id.iam.gserviceaccount.com
) - Billing project: your GCP project ID (where query costs are billed)
- Name: a descriptive label for this connection

Step 5: Configure your table
After the connection is created, configure the table you want to monitor:- Project: GCP project containing the table
- Dataset: dataset name
- Table: table name
- Data source name: a descriptive name for this table in Openlayer

Optional: ML-specific settings
If the table contains ML outputs, you can provide additional context:- Class names
- Feature names
- Categorical feature names
Troubleshooting
- Permission errors → confirm the roles above are granted to your service account
- Impersonation errors → ensure
roles/iam.serviceAccountTokenCreator
is granted to Openlayer’s service account