Lists the valid Google Cloud Platform (GCP) resource locations for the specified Project (including a FirebaseProject
).
One of these locations can be selected as the Project's default GCP resource location, which is the geographical location where the Project's resources, such as Cloud Firestore, will be provisioned by default. However, if the default GCP resource location has already been set for the Project, then this setting cannot be changed.
This call checks for any possible location restrictions for the specified Project and, thus, might return a subset of all possible GCP resource locations. To list all GCP resource locations (regardless of any restrictions), call the endpoint without specifying a unique project identifier (that is, /v1beta1/{parent=projects/-}/listAvailableLocations
).
To call availableLocations.list
with a specified project, a member must be at minimum a Viewer of the Project. Calls without a specified project do not require any specific project permissions.
HTTP request
GET https://firebase.googleapis.com/v1beta1/{parent=projects/*}/availableLocations
The URL uses gRPC Transcoding syntax.
Path parameters
Parameters | |
---|---|
parent |
The
Refer to the If no unique project identifier is specified (that is, |
Query parameters
Parameters | |
---|---|
pageToken |
Token returned from a previous call to |
pageSize |
The maximum number of locations to return in the response. The server may return fewer than this value at its discretion. If no value is specified (or too large a value is specified), then the server will impose its own limit. This value cannot be negative. |
Request body
The request body must be empty.
Response body
If successful, the response body contains data with the following structure:
JSON representation |
---|
{
"locations": [
{
object ( |
Fields | |
---|---|
locations[] |
One page of results from a call to |
nextPageToken |
If the result list is too large to fit in a single response, then a token is returned. If the string is empty, then this response is the last page of results and all available locations have been listed. This token can be used in a subsequent call to Page tokens are short-lived and should not be persisted. |
Authorization Scopes
Requires one of the following OAuth scopes:
https://www.googleapis.com/auth/cloud-platform
https://www.googleapis.com/auth/cloud-platform.read-only
https://www.googleapis.com/auth/firebase
https://www.googleapis.com/auth/firebase.readonly
For more information, see the Authentication Overview.
Location
A GCP resource location that can be selected for a FirebaseProject
.
JSON representation |
---|
{ "locationId": string, "type": enum ( |
Fields | |
---|---|
locationId |
The ID of the GCP resource location. It will be one of the available GCP resource locations. |
type |
Indicates whether the GCP resource location is a regional or multi-regional location for data replication. |
features[] |
Products and services that are available in the GCP resource location. |
LocationType
Specifies how data is replicated within the GCP resource location. Learn more about the types of GCP resource locations.
Enums | |
---|---|
LOCATION_TYPE_UNSPECIFIED |
Used internally for distinguishing unset values and is not intended for external use. |
REGIONAL |
The location is a regional location. Data in a regional location is replicated in multiple zones within a region. |
MULTI_REGIONAL |
The location is a multi-regional location. Data in a multi-region location is replicated in multiple regions. Within each region, data is replicated in multiple zones. |
LocationFeature
Products and services that are available in the GCP resource location.
Enums | |
---|---|
LOCATION_FEATURE_UNSPECIFIED |
Used internally for distinguishing unset values and is not intended for external use. |
FIRESTORE |
This location supports Cloud Firestore database instances. App Engine is available in this location, so it can be a Project's default GCP resource location. |
DEFAULT_STORAGE |
This location supports default Cloud Storage buckets. App Engine is available in this location, so it can be a Project's default GCP resource location. |
FUNCTIONS |
Cloud Functions for Firebase is available in this location. |