Package google.cloud.location

索引

适用地区

一个抽象接口,提供服务的位置信息。服务专属元数据是通过 Location.metadata 字段提供的。

GetLocation

rpc GetLocation(GetLocationRequest) returns (Location)

获取位置相关信息。

授权范围

需要以下 OAuth 范围之一:

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

如需了解详情,请参阅身份验证概览

ListLocations

rpc ListLocations(ListLocationsRequest) returns (ListLocationsResponse)

列出有关此服务所支持位置的信息。

授权范围

需要以下 OAuth 范围之一:

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

如需了解详情,请参阅身份验证概览

GetLocationRequest

Locations.GetLocation 的请求消息。

字段
name

string

位置对应的资源名称。

ListLocationsRequest

Locations.ListLocations 的请求消息。

字段
name

string

包含位置信息集合的资源(如果适用)。

filter

string

用于将结果范围缩小到首选子集的过滤条件。过滤语言接受 "displayName=tokyo" 等字符串,如需了解详情,请参阅 AIP-160

page_size

int32

返回的结果数上限。如果未设置,该服务会选择默认值。

page_token

string

从响应的 next_page_token 字段收到的页面令牌。发送该页面令牌以接收后续页面。

ListLocationsResponse

Locations.ListLocations 的响应消息。

字段
locations[]

Location

与请求中指定的过滤条件匹配的位置列表。

next_page_token

string

标准列表下一页令牌。

位置

表示 Google Cloud 位置的资源。

字段
name

string

位置对应的资源名称,可能因实现方式而异。例如 "projects/example-project/locations/us-east1"

location_id

string

此位置的规范 ID。例如:"us-east1"

display_name

string

此位置的易记名称,通常是附近城市的名称。例如,“Tokyo”。

labels

map<string, string>

此位置的跨服务属性。例如,

{"cloud.googleapis.com/region": "us-east1"}
metadata

Any

服务专属元数据。例如,指定位置的可用容量。