Method: datasets.undelete

Undeletes a dataset which is within time travel window based on datasetId. If a time is specified, the dataset version deleted at that time is undeleted, else the last live version is undeleted.

IAM Permissions

Requires the following IAM permission(s) to use this method:

  • bigquery.datasets.create on the project.
  • bigquery.datasets.get on the dataset.

HTTP request

POST https://bigquery.googleapis.com/bigquery/v2/projects/{projectId}/datasets/{datasetId}:undelete

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
projectId

string

Required. Project ID of the dataset to be undeleted

datasetId

string

Required. Dataset ID of dataset being deleted

Request body

The request body must be empty.

Response body

If successful, the response body contains an instance of Dataset.

Authorization scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/bigquery
  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.