Extracting Employee Data with the BambooHR APIExtracting Employee Data with the BambooHR API - Practical Examples.

A Guide to Creating an OAuth App for a Google BigQuery Integration

Introduction

Google BigQuery is a fully-managed, serverless data warehouse that enables super-fast SQL queries using the processing power of Google's infrastructure. Integrating BigQuery into your application allows you to analyze large datasets in real-time. This guide will walk you through the steps to create an OAuth app for Google BigQuery integration.

Step 1: Prerequisites

Before you begin, make sure you have the following:

  1. A Google account
  2. An Apideck account

Step 2: Setting up the Google Developer Console

  1. Navigate to the Google Developer Console (https://console.developers.google.com/).
  2. Sign in with your Google account.
  3. If you haven't created a project yet, click the "Create Project" button and follow the prompts. Otherwise, select an existing project.

Step 3: Enabling the BigQuery API

  1. In the Google Developer Console, click on the "Enable APIs and Services" button.
  2. Search for "BigQuery API" in the search bar and click on it.
  3. Click the "Enable" button to enable the BigQuery API for your project.

Step 4: Creating OAuth 2.0 credentials

  1. Navigate to the "Credentials" tab on the left side of the Google Developer Console.
  2. Click on the "Create credentials" button and select "OAuth client ID" from the dropdown menu.
  3. Choose the appropriate application type, depending on your project (e.g., Web application, Android, iOS, etc.).
  4. Fill in the required fields, such as "Name," "Authorized JavaScript origins," and "Authorized redirect URIs." Make sure to use the correct redirect URIs for your app.
  5. Click "Create" to generate your OAuth client ID and secret. Note down these values, as you'll need them in your application.
  1. Navigate to the "OAuth consent screen" tab on the left side of the Google Developer Console.
  2. Choose "External" or "Internal" user type, depending on your app's target audience.
  3. Fill in the required fields, such as "App name," "User support email," "App logo," "Developer contact information," etc.
  4. Under "Scopes," click the "Add or Remove Scopes" button and add the "https://www.googleapis.com/auth/bigquery" scope to request access to the user's BigQuery resources.
  5. Save your changes and submit your consent screen for verification if required.

Step 6: Configure a Custom redirect URI

To enable the connection to your Google BigQuery instance and be compliant with the Google certification, it is required use your own whitelabel auth URIs.

💡 IMPORTANT: Once you have applied one of the options, don't forget to update the "Redirect URI" in your Google BigQuery configuration as described in step 5.

Setup a custom subdomain for Apideck Vault

Add a custom domain name for Apideck Vault. This will allow you to whitelabel the reference to Apideck's Vault.

  1. Create a CNAME record

Sign in to your DNS name server host and navigate to your DNS settings. Add a CNAME record with the value

cname.vercel-dns.com
.

[REPLACE_WITH_DESIRED_SUBDOMAIN] CNAME cname.vercel-dns.com.
  1. Contact Apideck

Get in touch with your Apideck contact or support@apideck.com to let us know about the custom domain you want to use, so we can configure & enable it for Apideck Vault.

  1. Wait for the changes to propagate

Congratulations! You have now pointed your custom domain to Apideck Vault! When DNS changes are made, you can expect a propagation time up to 24 hours (but mostly much less than that). This is because it takes time for the DNS to take effect across the internet. The actual time of propagation may vary in some locations based on your network setup.

  1. Update the "Redirect URI"

Update the "Redirect URI" in your Google BigQuery configuration as described in step 5.

  1. Save your changes and submit your consent screen for verification.

Step 7: Configure your Client ID and Secret in Apideck

Now that you've set up your OAuth app, you can configure the Google BigQuery connector in Apideck using the client ID and secret generated earlier.

Do your first API call to the Google BigQuery API

  • Connect your Google BigQuery account through Vault with a test session.

  • To test the access token, make a call to the

    List projects
    endpoint using the Proxy API.

curl --location --request GET 'https://unify.apideck.com/proxy' \
--header 'x-apideck-consumer-id: test-consumer' \
--header 'x-apideck-app-id: {APIDECK_APP_ID}' \
--header 'x-apideck-service-id: google-bigquery' \
--header 'x-apideck-downstream-url: https://bigquery.googleapis.com/bigquery/v2/projects' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {APIDECK_API_KEY}'

Start building with the Google BigQuery API

Learn what else you can build with the Google BigQuery API.

Interested in a personalized demo? Let us know.