github.com/morlay/goqcloud@v0.0.0-20181123023149-b00e0b0b9afc/clients/postgres/describe_db_instances.go (about) 1 package postgres 2 3 import ( 4 github_com_morlay_goqcloud "github.com/morlay/goqcloud" 5 ) 6 7 // 查询实例列表 8 // https://cloud.tencent.com/document/api/409/16773 9 10 type DescribeDbInstancesRequest struct { 11 // 过滤条件,目前支持:db-instance-id、db-instance-name两种。 12 Filters []*Filter `name:"Filters,omitempty"` 13 // 每页显示数量,默认返回10条。 14 Limit *int64 `name:"Limit,omitempty"` 15 // 分页序号,从0开始。 16 Offset *int64 `name:"Offset,omitempty"` 17 // 区域 18 Region string `name:"Region"` 19 } 20 21 func (req *DescribeDbInstancesRequest) Invoke(client github_com_morlay_goqcloud.Client) (*DescribeDbInstancesResponse, error) { 22 resp := &DescribeDbInstancesResponse{} 23 err := client.Request("postgres", "DescribeDBInstances", "2017-03-12").Do(req, resp) 24 return resp, err 25 } 26 27 type DescribeDbInstancesResponse struct { 28 github_com_morlay_goqcloud.TencentCloudBaseResponse 29 // 实例详细信息集合。 30 DBInstanceSet []*DBInstance `json:"DBInstanceSet"` 31 // 查询到的实例数量。 32 TotalCount int64 `json:"TotalCount"` 33 }