mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-10-30 18:23:35 +08:00
aliyun: add SVpc.apiRequest() method
This commit is contained in:
@@ -16,7 +16,8 @@ const (
|
||||
|
||||
ALIYUN_DEFAULT_REGION = "cn-hangzhou"
|
||||
|
||||
ALIYUN_API_VERSION = "2014-05-26"
|
||||
ALIYUN_API_VERSION = "2014-05-26"
|
||||
ALIYUN_API_VERSION_VPC = "2016-04-28"
|
||||
|
||||
ALIYUN_BSS_API_VERSION = "2017-12-14"
|
||||
|
||||
|
||||
@@ -45,6 +45,14 @@ type SVpc struct {
|
||||
VpcName string
|
||||
}
|
||||
|
||||
func (self *SVpc) apiRequest(action string, params map[string]string) (jsonutils.JSONObject, error) {
|
||||
client, err := self.region.getSdkClient()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return _jsonRequest(client, "vpc.aliyuncs.com", ALIYUN_API_VERSION_VPC, action, params)
|
||||
}
|
||||
|
||||
func (self *SVpc) GetMetadata() *jsonutils.JSONDict {
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user