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

     1  package sqlserver
     2  
     3  import (
     4  	github_com_morlay_goqcloud "github.com/morlay/goqcloud"
     5  	time "time"
     6  )
     7  
     8  // 查询备份列表
     9  // https://cloud.tencent.com/document/api/238/19943
    10  
    11  type DescribeBackupsRequest struct {
    12  	// 结束时间(yyyy-MM-dd HH:mm:ss)
    13  	EndTime time.Time `name:"EndTime"`
    14  	// 实例ID,形如mssql-njj2mtpl
    15  	InstanceId string `name:"InstanceId"`
    16  	// 分页返回,每页返回数量,默认为20,最大值为 100
    17  	Limit *int64 `name:"Limit,omitempty"`
    18  	// 偏移量,默认为 0
    19  	Offset *int64 `name:"Offset,omitempty"`
    20  	// 区域
    21  	Region string `name:"Region"`
    22  	// 开始时间(yyyy-MM-dd HH:mm:ss)
    23  	StartTime time.Time `name:"StartTime"`
    24  }
    25  
    26  func (req *DescribeBackupsRequest) Invoke(client github_com_morlay_goqcloud.Client) (*DescribeBackupsResponse, error) {
    27  	resp := &DescribeBackupsResponse{}
    28  	err := client.Request("sqlserver", "DescribeBackups", "2018-03-28").Do(req, resp)
    29  	return resp, err
    30  }
    31  
    32  type DescribeBackupsResponse struct {
    33  	github_com_morlay_goqcloud.TencentCloudBaseResponse
    34  	// 备份列表详情
    35  	Backups []*Backup `json:"Backups"`
    36  	// 备份总数量
    37  	TotalCount int64 `json:"TotalCount"`
    38  }