GCP Project Level Onboarding Guide

Last updated: April 6, 2026

This guide explains how to onboard a GCP Project into the Matters platform using the Project access scope.

As part of the setup, you will need to download and run a Terraform template provided by Matters.

The provided Terraform template (gcp_project_onboarding.tf and gcp_project_onboarding.tfvars) will:

  • Enable the required Google Cloud APIs in the target project

  • Create a custom IAM role at the Project level

  • Assign the required permissions to that custom role

  • Bind the role to an existing Service Account

Prerequisites

Before starting, ensure the following:

  1. You have Matters Super Admin access.

  1. You have access to the target GCP project with permissions to:

    • Enable APIs (serviceusage.services.enable)

    • Create project-level custom roles

    • Create IAM bindings at project level

  1. You will run Terraform from Google Cloud Shell (recommended) or any environment authenticated to the project.

Terraform Enables Following Google APIs

Terraform script enables below listed APIs automatically using google_project_service.

Note: The script sets disable_on_destroy = false, so APIs will not be disabled if Terraform resources are destroyed.

Step 1 Configure Integration in Matters Console

  • Log in to the Matters Console as a Super Admin.

  • Navigate to:

    Integrations → Cloud → Google Cloud

    (URL: https://app.matters.ai/data-security/integrations?type=cloud.

    If you use a dedicated tenant, replace app with your tenant name.)

  • Click Connect on the GCP integration card.

  • Provide:

    • Integration Name

    • Access Level Scope → Project

  • Enter:

    • Project ID

  • Click Continue Setup.

image.png

Step 2: Download and Extract the Terraform Script

  1. Click on the Google Cloud Shell hyperlink to log in to the GCP Admin account.

Screenshot 2026-03-03 at 2.20.06 PM.png

  1. In the next step on the Matters Dashboard, click Download Script.

Screenshot 2026-03-03 at 2.24.10 PM.png

A .zip file will be downloaded.

  1. Extract the zip — it contains two Terraform files:

    • gcp_project_onboarding.tf → Terraform configuration to:

      • Enable required project APIs

      • Create a project-level custom IAM role

      • Bind the role to a service account

    • gcp_project_onboarding.tfvars → Variable file where you provide:

      • project_id

      • matters_service_account_email

      • role_id

Step 3: Open Google Cloud Shell

  1. In the GCP Management Console, click SSH (top-right corner) to activate Cloud Shell.

Screenshot 2026-03-02 at 3.18.29 PM.png
  1. Authorize access when prompted. Cloud Shell will now be ready for Terraform execution.

image.png

Step 4: Upload the Terraform Folder to Cloud Shell

  1. In Cloud Shell, click the Upload option.

image (60).png
  1. Select the extracted folder from your system and click on upload.

image.png

  1. Once upload is complete, navigate into the folder:

    cd <folder_name>
  1. Confirm files exist:

ls

You should see gcp_org_onboarding.tf and gcp_org_onboarding.tfvars.

Step 5: Run Terraform to Create Required Resources

  1. In Cloud Shell, navigate to the folder where the files were uploaded and execute the following command (you may also copy this command from the Matters Dashboard):

terraform init && terraform apply -auto-approve -var-file="gcp_org_onboarding.tfvars"
Screenshot 2026-03-02 at 3.24.43 PM.png

Screenshot 2026-03-02 at 3.29.16 PM.png
  1. After Terraform completes successfully:

    Click Validate in the Matters Console. Matters will verify access and permissions.

Screenshot 2026-03-02 at 3.32.49 PM (1).png

Step 6: Integration Complete

You will see “Integration Successful” message once Integration is complete

image.png

Once the account is successfully integrated, all supported data stores across the selected GCP account will be automatically discovered in the Matters dashboard.

image (1).png

After discovery, you can click on the data store selectively and can run scans on specific data stores to identify and classify sensitive entities as per your requirements. This allows you to focus on relevant resources and efficiently manage sensitive data across your organization.

Understanding What the Terraform Script Configures (Project Scope)

1) Enables Required APIs (Project Level)

The script enables required APIs in the project via:

  • google_project_service.required_apis

  • It loops through a list of APIs and enables each one.

  • It does not disable APIs on destroy (disable_on_destroy = false).

2) Custom IAM Role Creation (Project Level)

Terraform creates a custom IAM role at the Project level:

  • Role title: Matters Integration Role

  • Role ID: from role_id in tfvars

  • Stage: GA

  • Permissions: a curated set used for discovery / inventory / limited export across:

    • BigQuery

    • Cloud Storage

    • Cloud SQL

    • Cloud KMS

    • Dataform

    • Dataplex

    • Resource Manager (project + IAM policy visibility)

IAM Permissions Included in the Custom Role (Project Template)

Below is the permission set used by the project onboarding Terraform

Service AreaIAM PermissionCapability / Purpose

BigQuery

bigquery.jobs.list

List query and load jobs

BigQuery

bigquery.jobs.create

Run BigQuery jobs (queries, exports)

BigQuery

bigquery.datasets.get

View dataset metadata

BigQuery

bigquery.datasets.getIamPolicy

View dataset IAM policies

BigQuery

bigquery.tables.list

List tables

BigQuery

bigquery.tables.get

View table metadata

BigQuery

bigquery.tables.getData

Read table data

BigQuery

bigquery.tables.getIamPolicy

View table IAM policies

BigQuery

bigquery.tables.export

Export table data

BigQuery

bigquery.tables.createSnapshot

Create table snapshots

BigQuery

bigquery.readsessions.create

Create read sessions

BigQuery

bigquery.readsessions.update

Update read sessions

BigQuery

bigquery.readsessions.getData

Retrieve read session data

BigQuery

bigquery.models.list

List ML models

BigQuery

bigquery.models.getMetadata

View ML model metadata

BigQuery

bigquery.models.getData

Read ML model data

BigQuery

bigquery.models.export

Export ML models

BigQuery

bigquery.routines.list

List routines (UDFs/procedures)

BigQuery

bigquery.routines.get

View routine definitions

BigQuery

bigquery.savedqueries.list

List saved queries

BigQuery

bigquery.savedqueries.get

View saved query definitions

BigQuery

bigquery.transfers.get

View Data Transfer configurations

BigQuery

bigquery.config.get

View BigQuery project configuration

BigQuery

bigquery.reservations.get

View reservation configuration

BigQuery

bigquery.reservations.list

List reservations

BigQuery

bigquery.reservations.use

Use BigQuery slot reservations

BigQuery

bigquery.reservations.listFailoverDatasets

List failover datasets

BigQuery

bigquery.reservationAssignments.list

List reservation assignments

BigQuery

bigquery.reservationAssignments.search

Search reservation assignments

BigQuery

bigquery.capacityCommitments.get

View capacity commitments

BigQuery

bigquery.capacityCommitments.list

List capacity commitments

BigQuery

bigquery.bireservations.get

View BI reservation settings

BigQuery

bigquerymigration.translation.translate

Translate SQL to BigQuery

Cloud Storage

storage.buckets.list

List buckets

Cloud Storage

storage.buckets.get

View bucket metadata

Cloud Storage

storage.buckets.getIamPolicy

View bucket IAM policy

Cloud Storage

storage.objects.list

List objects

Cloud Storage

storage.objects.get

Read objects

Cloud SQL

cloudsql.instances.list

List Cloud SQL instances

Cloud SQL

cloudsql.instances.get

View Cloud SQL instance metadata

Cloud SQL

cloudsql.instances.connect

Connect using ephemeral certificate

Cloud SQL

cloudsql.instances.export

Export Cloud SQL data

Cloud KMS

cloudkms.keyHandles.create

Create key handles

Cloud KMS

cloudkms.keyHandles.get

View key handles

Cloud KMS

cloudkms.keyHandles.list

List key handles

Cloud KMS

cloudkms.operations.get

View KMS operations

Cloud KMS

cloudkms.projects.showEffectiveAutokeyConfig

View Autokey configuration

Dataform

dataform.locations.list

List Dataform locations

Dataform

dataform.locations.get

View Dataform location metadata

Dataform

dataform.repositories.list

List Dataform repositories

Dataform

dataform.repositories.create

Create repositories

Dataplex

dataplex.projects.search

Discover projects via Dataplex

Resource Manager

resourcemanager.projects.get

View project metadata

Resource Manager

resourcemanager.projects.getIamPolicy

View project IAM policy