github.com/morlay/goqcloud@v0.0.0-20181123023149-b00e0b0b9afc/clients/vpc/create_customer_gateway.go (about) 1 package vpc 2 3 import ( 4 github_com_morlay_goqcloud "github.com/morlay/goqcloud" 5 ) 6 7 // 创建对端网关 8 // https://cloud.tencent.com/document/api/215/17523 9 10 type CreateCustomerGatewayRequest struct { 11 // 对端网关名称,可任意命名,但不得超过60个字符。 12 CustomerGatewayName string `name:"CustomerGatewayName"` 13 // 对端网关公网IP。 14 IpAddress string `name:"IpAddress"` 15 // 区域 16 Region string `name:"Region"` 17 } 18 19 func (req *CreateCustomerGatewayRequest) Invoke(client github_com_morlay_goqcloud.Client) (*CreateCustomerGatewayResponse, error) { 20 resp := &CreateCustomerGatewayResponse{} 21 err := client.Request("vpc", "CreateCustomerGateway", "2017-03-12").Do(req, resp) 22 return resp, err 23 } 24 25 type CreateCustomerGatewayResponse struct { 26 github_com_morlay_goqcloud.TencentCloudBaseResponse 27 // 对端网关对象 28 CustomerGateway CustomerGateway `json:"CustomerGateway"` 29 }