> ## Documentation Index
> Fetch the complete documentation index at: https://docs.keephq.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# BigQuery

> BigQuery provider allows interaction with Google BigQuery for querying and managing datasets.

## Authentication

This provider requires authentication.

* **service\_account\_json**: The service account JSON with container.viewer role (required: True, sensitive: True)
* **project\_id**: Google Cloud project ID. If not provided, it will try to fetch it from the environment variable 'GOOGLE\_CLOUD\_PROJECT' (required: False, sensitive: False)

## In workflows

This provider can be used in workflows.

As "step" to query data, example:

```yaml theme={null}
steps:
    - name: Query bigquery
      provider: bigquery
      config: "{{ provider.my_provider_name }}"
      with:
        query: {value}  
```

Check the following workflow examples:

* [bigquery.yml](https://github.com/keephq/keep/blob/main/examples/workflows/bigquery.yml)
* [failed-to-login-workflow.yml](https://github.com/keephq/keep/blob/main/examples/workflows/failed-to-login-workflow.yml)

## Connecting with the Provider

1. Create a Google Cloud project and enable the BigQuery API.
2. Create a service account in your Google Cloud project and download the JSON key file.
3. Share the necessary datasets with the service account.
4. Configure your provider using the `service_account_key`, `project_id`, and `dataset`.
