Skip to main content

BigQuery

The BigQuery connection uses a Google service account so FunnelStory can run read-only jobs against your datasets and drive data models from BigQuery tables and views.

What FunnelStory uses it for

  • Data models — Query BigQuery with SQL compatible with the BigQuery engine.

Before you connect

FunnelStory needs a service account with read-only access to BigQuery. Minimum permissions include:

  1. bigquery.datasets.get
  2. bigquery.tables.get
  3. bigquery.tables.getData
  4. bigquery.tables.list
  5. bigquery.jobs.create

You can define a custom IAM role with those permissions, or attach the predefined roles BigQuery Data Viewer and BigQuery Job User to the service account.

  • BigQuery Data Viewer — View datasets, tables, and read table data (no writes).
  • BigQuery Job User — Create and manage query jobs in the project (required to run queries).

Enable the BigQuery API

  1. Open the Google Cloud Console and select the correct project from the project picker at the top of the page.

  2. In the left navigation, open APIs & Services. Then either:

    • Go to Dashboard and click + ENABLE APIS AND SERVICES (or Enable APIs and Services), or
    • Go to Library (or Enabled APIs & services+ ENABLE APIS AND SERVICES).
  3. Search for BigQuery API, open it, and click Enable.

Create a service account and grant roles

  1. In the left navigation, go to IAM & AdminService accounts.

  2. Click + CREATE SERVICE ACCOUNT (or Create service account).

  3. Enter a Service account name (and optional description), then continue.

  4. On the Grant this service account access to project step, click Select a role, add:

    • BigQuery Data Viewer
    • BigQuery Job User

    Add each role with Add another role if the UI offers it, then continue and finish creating the account.

Service account creation showing BigQuery Data Viewer and BigQuery Job User roles

If roles are missing from the service account

If the account was created without those roles, add them on the project IAM policy:

  1. Go to IAM & AdminIAM.

  2. Click Grant access (or + GRANT ACCESS / Add depending on console version).

  3. Paste the service account email (for example name@project-id.iam.gserviceaccount.com).

  4. Assign BigQuery Data Viewer and BigQuery Job User, then save.

Project ID, JSON key, and optional endpoint

Project ID

  • Use the project picker at the top of the console: the project’s ID is shown in the project details (not only the display name).
  • Or open IAM & AdminSettings and copy Project ID.
  • The downloaded key file also contains "project_id".

Credentials JSON

  1. Go to IAM & AdminService accounts.

  2. Open your service account (click the email or name).

  3. Open the Keys tab.

  4. Select Add keyCreate new keyJSON. A key file downloads immediately. Store it securely; you will paste or upload its contents in FunnelStory.

Endpoint (optional)

  • Leave Endpoint empty unless your organization requires a non-default BigQuery API base URL (for example a restricted or private endpoint). If unsure, leave it blank.

Add the connection in FunnelStory

  1. Open Configuration → ConnectionsAdd connection, then choose BigQuery.

  2. Complete the fields in the connection form:

BigQuery connection form with fields and Validate

FieldDescription
Connection nameDisplay name (for example BigQuery — production).
Project ID (optional)GCP project ID. Often inferred from the JSON; set explicitly if needed.
Endpoint (optional)Custom BigQuery API base URL only if required by your network or org policy.
Credentials JSONFull contents of the service account JSON key. The account must have BigQuery Data Viewer and BigQuery Job User (or equivalent custom permissions).
  1. Click Validate, then Add Connection.

After you connect

Configure models with BigQuery SQL. See Writing queries for guidance on types and timestamps.