github.com/morlay/goqcloud@v0.0.0-20181123023149-b00e0b0b9afc/clients/iotcloud/describe_products.go (about)

     1  package iotcloud
     2  
     3  import (
     4  	github_com_morlay_goqcloud "github.com/morlay/goqcloud"
     5  )
     6  
     7  // 获取产品列表
     8  // https://cloud.tencent.com/document/api/634/19477
     9  
    10  type DescribeProductsRequest struct {
    11  	// 过滤条件
    12  	Filters []*Filter `name:"Filters,omitempty"`
    13  	// 分页大小,当前页面中显示的最大数量,值范围 10-250。
    14  	Limit int64 `name:"Limit"`
    15  	// 分页偏移,Offset从0开始
    16  	Offset int64 `name:"Offset"`
    17  	// 区域
    18  	Region string `name:"Region"`
    19  }
    20  
    21  func (req *DescribeProductsRequest) Invoke(client github_com_morlay_goqcloud.Client) (*DescribeProductsResponse, error) {
    22  	resp := &DescribeProductsResponse{}
    23  	err := client.Request("iotcloud", "DescribeProducts", "2018-06-14").Do(req, resp)
    24  	return resp, err
    25  }
    26  
    27  type DescribeProductsResponse struct {
    28  	github_com_morlay_goqcloud.TencentCloudBaseResponse
    29  	// 产品详细信息列表
    30  	Products []*ProductInfo `json:"Products"`
    31  	// 产品总数
    32  	TotalCount int64 `json:"TotalCount"`
    33  }