Skip to main content

Prerequisites

  • A Google Cloud project with BigQuery enabled.
  • A service account with the BigQuery Data Viewer and BigQuery Job User roles (or equivalent).
  • The service account’s JSON key file.

Required fields

FieldDescription
NameA display name for this datasource.
Service accountThe full JSON key for your GCP service account. Paste the entire contents of the downloaded .json file.
The JSON key looks like this:
{
  "type": "service_account",
  "project_id": "your-project",
  "private_key_id": "...",
  "private_key": "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n",
  "client_email": "mora@your-project.iam.gserviceaccount.com",
  "client_id": "...",
  "auth_uri": "https://accounts.google.com/o/oauth2/auth",
  "token_uri": "https://oauth2.googleapis.com/token",
  "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
  "client_x509_cert_url": "..."
}

Steps

  1. Open Settings → Datasources → New.
  2. Enter a name and select Google BigQuery as the type.
  3. Paste your service account JSON into the Service account field.
  4. Click Test connection to verify.
  5. Click Create.

Creating a service account

If you don’t have a service account yet:
  1. Go to the GCP Console → IAM & Admin → Service Accounts.
  2. Click Create Service Account.
  3. Give it a name (e.g. mora-reader) and click Create and Continue.
  4. Grant the roles BigQuery Data Viewer and BigQuery Job User.
  5. Click Done, then click into the new service account.
  6. Go to the Keys tab, click Add Key → Create new key, select JSON, and download the file.
  7. Paste the contents of that file into Mora.