Method: instances.list

Lists instances under a given project.

HTTP request

GET https://www.googleapis.com/sql/v1beta4/projects/{project}/instances

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
project

string

Project ID of the project for which to list Cloud SQL instances.

Query parameters

Parameters
filter

string

An expression for filtering the results of the request, such as by name or label.

maxResults

integer (uint32 format)

The maximum number of results to return per response.

pageToken

string

A previously-returned page token representing part of the larger set of results to view.

Request body

The request body must be empty.

Response body

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

Database instances list response.

JSON representation
{
  "kind": string,
  "warnings": [
    {
      object (ApiWarning)
    }
  ],
  "items": [
    {
      object (DatabaseInstance)
    }
  ],
  "nextPageToken": string
}
Fields
kind

string

This is always

sql#instancesList

.

warnings[]

object (ApiWarning)

backupRuns.list of warnings that ocurred while handling the request.

items[]

object (DatabaseInstance)

backupRuns.list of database instance resources.

nextPageToken

string

The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results.

Authorization Scopes

Requires one of the following OAuth scopes:

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

For more information, see the Authentication Overview.

ApiWarning

An Admin API warning message.

JSON representation
{
  "code": enum (SqlApiWarningCode),
  "message": string
}
Fields
code

enum (SqlApiWarningCode)

Code to uniquely identify the warning type.

message

string

The warning message.

SqlApiWarningCode

Enums
SQL_API_WARNING_CODE_UNSPECIFIED An unknown or unset warning type from Cloud SQL API.
REGION_UNREACHABLE Warning when one or more regions are not reachable. The returned result set may be incomplete.
Was this page helpful? Let us know how we did:

Send feedback about...

Cloud SQL for MySQL
Need help? Visit our support page.