Method: projects.list

RPC to list projects to which the user has been granted any project role.

Users of this method are encouraged to consider the Resource Manager API, which provides the underlying data for this method and has more capabilities.

HTTP request

GET https://bigquery.googleapis.com/bigquery/v2/projects

The URL uses gRPC Transcoding syntax.

Query parameters

Parameters
maxResults

number

Maximum number of results to read. A wrapper is used here because behavior for maxResults 0 differs from the behavior for maxResults unset.

pageToken

string

Page token, returned by a previous call, to request the next page of results.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

Response object of projects.list

JSON representation
{
  "kind": string,
  "etag": string,
  "nextPageToken": string,
  "projects": [
    {
      "kind": string,
      "id": string,
      "numericId": string,
      "projectReference": {
        object (ProjectReference)
      },
      "friendlyName": string
    }
  ],
  "totalItems": number
}
Fields
kind

string

The resource type of the response.

etag

string

A hash of the page of results.

nextPageToken

string

A token to request the next page of results.

projects[]

object

Projects to which the user has at least READ access.

projects[].kind

string

The resource type.

projects[].id

string

An opaque ID of this project.

projects[].numericId

string (int64 format)

The numeric ID of this project.

projects[].projectReference

object (ProjectReference)

A unique reference to this project.

projects[].friendlyName

string

A descriptive name for this project. A wrapper is used here because friendlyName can be set to the empty string.

totalItems

number

The total number of projects in the list. A wrapper is used here because the field should still be in the response when the value is 0.

Authorization Scopes

Requires one of the following OAuth scopes:

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

For more information, see the Authentication Overview.

Try it!

¿Te ha resultado útil esta página? Enviar comentarios:

Enviar comentarios sobre...