BigQuery Data Policy API (bigquerydatapolicy:v2)

2025-10-15

10 new methods | New API

Additions

    Methods
  • bigquerydatapolicy.projects.locations.dataPolicies.create

      Path : v2/{+parent}/dataPolicies

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies

      HTTP Method : POST

      Parameters :

        parent

          Description : Required. Resource name of the project that the data policy will belong to. The format is `projects/{project_number}/locations/{location_id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : parent

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Creates a new data policy under a project with the given `data_policy_id` (used as the display name), and data policy type.

  • bigquerydatapolicy.projects.locations.dataPolicies.addGrantees

      Path : v2/{+dataPolicy}:addGrantees

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}:addGrantees

      HTTP Method : POST

      Parameters :

        dataPolicy

          Description : Required. Resource name of this data policy, in the format of `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : dataPolicy

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Adds new grantees to a data policy. The new grantees will be added to the existing grantees. If the request contains a duplicate grantee, the grantee will be ignored. If the request contains a grantee that already exists, the grantee will be ignored.

  • bigquerydatapolicy.projects.locations.dataPolicies.removeGrantees

      Path : v2/{+dataPolicy}:removeGrantees

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}:removeGrantees

      HTTP Method : POST

      Parameters :

        dataPolicy

          Description : Required. Resource name of this data policy, in the format of `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : dataPolicy

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Removes grantees from a data policy. The grantees will be removed from the existing grantees. If the request contains a grantee that does not exist, the grantee will be ignored.

  • bigquerydatapolicy.projects.locations.dataPolicies.patch

      Path : v2/{+name}

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}

      HTTP Method : PATCH

      Parameters :

        name

          Description : Identifier. Resource name of this data policy, in the format of `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

        updateMask

          Description : Optional. The update mask applies to the resource. For the `FieldMask` definition, see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask If not set, defaults to all of the fields that are allowed to update. Updates to the `name` and `dataPolicyId` fields are not allowed.

          Location : query

          Type : string

          Format : google-fieldmask

        allowMissing

          Description : Optional. If set to true, and the data policy is not found, a new data policy will be created. In this situation, update_mask is ignored.

          Location : query

          Type : boolean

      Parameter Order : name

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Updates the metadata for an existing data policy. The target data policy can be specified by the resource name.

  • bigquerydatapolicy.projects.locations.dataPolicies.delete

      Path : v2/{+name}

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}

      HTTP Method : DELETE

      Parameters :

        name

          Description : Required. Resource name of the data policy to delete. Format is `projects/{project_number}/locations/{location_id}/dataPolicies/{id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : name

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Deletes the data policy specified by its resource name.

  • bigquerydatapolicy.projects.locations.dataPolicies.get

      Path : v2/{+name}

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}

      HTTP Method : GET

      Parameters :

        name

          Description : Required. Resource name of the requested data policy. Format is `projects/{project_number}/locations/{location_id}/dataPolicies/{id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : name

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Gets the data policy specified by its resource name.

  • bigquerydatapolicy.projects.locations.dataPolicies.list

      Path : v2/{+parent}/dataPolicies

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies

      HTTP Method : GET

      Parameters :

        parent

          Description : Required. Resource name of the project for which to list data policies. Format is `projects/{project_number}/locations/{location_id}`.

          Pattern : ^projects/[^/]+/locations/[^/]+$

          Location : path

          Required : Yes

          Type : string

        pageSize

          Description : Optional. The maximum number of data policies to return. Must be a value between 1 and 1000. If not set, defaults to 50.

          Location : query

          Type : integer

          Format : int32

        pageToken

          Description : Optional. The `nextPageToken` value returned from a previous list request, if any. If not set, defaults to an empty string.

          Location : query

          Type : string

        filter

          Description : Optional. Filters the data policies by policy tags that they are associated with. Currently filter only supports "policy_tag" based filtering and OR based predicates. Sample filter can be "policy_tag: projects/1/locations/us/taxonomies/2/policyTags/3". You may also use wildcard such as "policy_tag: projects/1/locations/us/taxonomies/2*". Please note that OR predicates cannot be used with wildcard filters.

          Location : query

          Type : string

      Parameter Order : parent

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : List all of the data policies in the specified parent project.

  • bigquerydatapolicy.projects.locations.dataPolicies.getIamPolicy

      Path : v2/{+resource}:getIamPolicy

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}:getIamPolicy

      HTTP Method : POST

      Parameters :

        resource

          Description : REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : resource

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Gets the IAM policy for the specified data policy.

  • bigquerydatapolicy.projects.locations.dataPolicies.setIamPolicy

      Path : v2/{+resource}:setIamPolicy

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}:setIamPolicy

      HTTP Method : POST

      Parameters :

        resource

          Description : REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : resource

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Sets the IAM policy for the specified data policy.

  • bigquerydatapolicy.projects.locations.dataPolicies.testIamPermissions

      Path : v2/{+resource}:testIamPermissions

      Flat Path : v2/projects/{projectsId}/locations/{locationsId}/dataPolicies/{dataPoliciesId}:testIamPermissions

      HTTP Method : POST

      Parameters :

        resource

          Description : REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

          Pattern : ^projects/[^/]+/locations/[^/]+/dataPolicies/[^/]+$

          Location : path

          Required : Yes

          Type : string

      Parameter Order : resource

      Scopes :

    • https://www.googleapis.com/auth/bigquery
    • https://www.googleapis.com/auth/cloud-platform
    • Description : Returns the caller's permission on the specified data policy resource.