# DestinationBigQuery-Input

Load the automation's rows into a BigQuery table.

The table is created on the first run if it does not exist; the **dataset**
is not, and must already exist.

Must be the automation's only destination, and at most one per automation --
see validate_bigquery_automation.

Type: object

Fields typed as another model are documented on that model's page; fetch it before filling the field.

| Field | Type | Required | Description | Allowed values / default / constraints |
| --- | --- | --- | --- | --- |
| `type` | string | yes | Writes the rows into a **BigQuery** table. Must be the only destination. | const: `"bigquery"` |
| `project` | string | yes | GCP project id |  |
| `dataset` | string | yes | Existing BigQuery dataset id. Sheetgo does not create datasets. |  |
| `table` | string | yes | Table id. Created on the first run if it does not exist. |  |
| `write_mode` | [BigQueryWriteMode](https://dev-api.sheetgo.com/rest/reference/models/BigQueryWriteMode.md) | no | `append` adds rows; `truncate` clears the data but keeps the schema and partitioning; `recreate` drops and rebuilds the table from the transferred data. | default: `"append"` |
| `schema_evolution` | boolean | no | Add columns to the destination table when the transferred data has new ones. With the default `false`, extra columns fail the run instead. Only ever adds -- never removes, renames or retypes. | default: `false` |
| `partition` | [BigQueryPartition](https://dev-api.sheetgo.com/rest/reference/models/BigQueryPartition.md), nullable | no | Omit for an unpartitioned table. |  |

## Used by

- [POST /rest/beta/automations/](https://dev-api.sheetgo.com/rest/reference/automations.md#post-rest-beta-automations)
- [PUT /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#put-rest-beta-automations-id)
- [AutomationCreate](https://dev-api.sheetgo.com/rest/reference/models/AutomationCreate.md)
- [AutomationReplace](https://dev-api.sheetgo.com/rest/reference/models/AutomationReplace.md)

---

More: start page https://dev-api.sheetgo.com/rest/reference.md, everything in one file https://dev-api.sheetgo.com/rest/llms-full.txt, OpenAPI https://dev-api.sheetgo.com/rest/openapi.json.
