diff --git a/ChangeLog.txt b/ChangeLog.txt index 037d122aa8..af4e5121e3 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,3 +1,7 @@ +2023-12-05 Version: v1.62.621 +- Generated 2016-06-15 for `Oms`. +- Add DeleteMeasureData + 2023-12-04 Version: v1.62.620 - Generated 2014-08-28 for `Ess`. - ScalingConfiguration support StorageSet. diff --git a/services/oms/check_ready_flag.go b/services/oms/check_ready_flag.go new file mode 100644 index 0000000000..d408a420d4 --- /dev/null +++ b/services/oms/check_ready_flag.go @@ -0,0 +1,105 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// CheckReadyFlag invokes the oms.CheckReadyFlag API synchronously +func (client *Client) CheckReadyFlag(request *CheckReadyFlagRequest) (response *CheckReadyFlagResponse, err error) { + response = CreateCheckReadyFlagResponse() + err = client.DoAction(request, response) + return +} + +// CheckReadyFlagWithChan invokes the oms.CheckReadyFlag API asynchronously +func (client *Client) CheckReadyFlagWithChan(request *CheckReadyFlagRequest) (<-chan *CheckReadyFlagResponse, <-chan error) { + responseChan := make(chan *CheckReadyFlagResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.CheckReadyFlag(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// CheckReadyFlagWithCallback invokes the oms.CheckReadyFlag API asynchronously +func (client *Client) CheckReadyFlagWithCallback(request *CheckReadyFlagRequest, callback func(response *CheckReadyFlagResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *CheckReadyFlagResponse + var err error + defer close(result) + response, err = client.CheckReadyFlag(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// CheckReadyFlagRequest is the request struct for api CheckReadyFlag +type CheckReadyFlagRequest struct { + *requests.RpcRequest + Period string `position:"Query" name:"Period"` + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + EndTime requests.Integer `position:"Query" name:"EndTime"` + Cycles requests.Integer `position:"Query" name:"Cycles"` + StartTime requests.Integer `position:"Query" name:"StartTime"` +} + +// CheckReadyFlagResponse is the response struct for api CheckReadyFlag +type CheckReadyFlagResponse struct { + *responses.BaseResponse + Data string `json:"Data" xml:"Data"` + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateCheckReadyFlagRequest creates a request to invoke CheckReadyFlag API +func CreateCheckReadyFlagRequest() (request *CheckReadyFlagRequest) { + request = &CheckReadyFlagRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "CheckReadyFlag", "", "") + request.Method = requests.POST + return +} + +// CreateCheckReadyFlagResponse creates a response to parse from CheckReadyFlag response +func CreateCheckReadyFlagResponse() (response *CheckReadyFlagResponse) { + response = &CheckReadyFlagResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/delete_domain_part.go b/services/oms/delete_domain_part.go new file mode 100644 index 0000000000..c270bbbc9a --- /dev/null +++ b/services/oms/delete_domain_part.go @@ -0,0 +1,103 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DeleteDomainPart invokes the oms.DeleteDomainPart API synchronously +func (client *Client) DeleteDomainPart(request *DeleteDomainPartRequest) (response *DeleteDomainPartResponse, err error) { + response = CreateDeleteDomainPartResponse() + err = client.DoAction(request, response) + return +} + +// DeleteDomainPartWithChan invokes the oms.DeleteDomainPart API asynchronously +func (client *Client) DeleteDomainPartWithChan(request *DeleteDomainPartRequest) (<-chan *DeleteDomainPartResponse, <-chan error) { + responseChan := make(chan *DeleteDomainPartResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteDomainPart(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteDomainPartWithCallback invokes the oms.DeleteDomainPart API asynchronously +func (client *Client) DeleteDomainPartWithCallback(request *DeleteDomainPartRequest, callback func(response *DeleteDomainPartResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteDomainPartResponse + var err error + defer close(result) + response, err = client.DeleteDomainPart(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteDomainPartRequest is the request struct for api DeleteDomainPart +type DeleteDomainPartRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + Part string `position:"Query" name:"Part"` +} + +// DeleteDomainPartResponse is the response struct for api DeleteDomainPart +type DeleteDomainPartResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreateDeleteDomainPartRequest creates a request to invoke DeleteDomainPart API +func CreateDeleteDomainPartRequest() (request *DeleteDomainPartRequest) { + request = &DeleteDomainPartRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "DeleteDomainPart", "", "") + request.Method = requests.POST + return +} + +// CreateDeleteDomainPartResponse creates a response to parse from DeleteDomainPart response +func CreateDeleteDomainPartResponse() (response *DeleteDomainPartResponse) { + response = &DeleteDomainPartResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/delete_domain_part_by_proxy.go b/services/oms/delete_domain_part_by_proxy.go new file mode 100644 index 0000000000..eccd817d3d --- /dev/null +++ b/services/oms/delete_domain_part_by_proxy.go @@ -0,0 +1,103 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DeleteDomainPartByProxy invokes the oms.DeleteDomainPartByProxy API synchronously +func (client *Client) DeleteDomainPartByProxy(request *DeleteDomainPartByProxyRequest) (response *DeleteDomainPartByProxyResponse, err error) { + response = CreateDeleteDomainPartByProxyResponse() + err = client.DoAction(request, response) + return +} + +// DeleteDomainPartByProxyWithChan invokes the oms.DeleteDomainPartByProxy API asynchronously +func (client *Client) DeleteDomainPartByProxyWithChan(request *DeleteDomainPartByProxyRequest) (<-chan *DeleteDomainPartByProxyResponse, <-chan error) { + responseChan := make(chan *DeleteDomainPartByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteDomainPartByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteDomainPartByProxyWithCallback invokes the oms.DeleteDomainPartByProxy API asynchronously +func (client *Client) DeleteDomainPartByProxyWithCallback(request *DeleteDomainPartByProxyRequest, callback func(response *DeleteDomainPartByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteDomainPartByProxyResponse + var err error + defer close(result) + response, err = client.DeleteDomainPartByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteDomainPartByProxyRequest is the request struct for api DeleteDomainPartByProxy +type DeleteDomainPartByProxyRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + Part string `position:"Query" name:"Part"` +} + +// DeleteDomainPartByProxyResponse is the response struct for api DeleteDomainPartByProxy +type DeleteDomainPartByProxyResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreateDeleteDomainPartByProxyRequest creates a request to invoke DeleteDomainPartByProxy API +func CreateDeleteDomainPartByProxyRequest() (request *DeleteDomainPartByProxyRequest) { + request = &DeleteDomainPartByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "DeleteDomainPartByProxy", "", "") + request.Method = requests.POST + return +} + +// CreateDeleteDomainPartByProxyResponse creates a response to parse from DeleteDomainPartByProxy response +func CreateDeleteDomainPartByProxyResponse() (response *DeleteDomainPartByProxyResponse) { + response = &DeleteDomainPartByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/delete_measure_data.go b/services/oms/delete_measure_data.go new file mode 100644 index 0000000000..d4e91d86b0 --- /dev/null +++ b/services/oms/delete_measure_data.go @@ -0,0 +1,108 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// DeleteMeasureData invokes the oms.DeleteMeasureData API synchronously +func (client *Client) DeleteMeasureData(request *DeleteMeasureDataRequest) (response *DeleteMeasureDataResponse, err error) { + response = CreateDeleteMeasureDataResponse() + err = client.DoAction(request, response) + return +} + +// DeleteMeasureDataWithChan invokes the oms.DeleteMeasureData API asynchronously +func (client *Client) DeleteMeasureDataWithChan(request *DeleteMeasureDataRequest) (<-chan *DeleteMeasureDataResponse, <-chan error) { + responseChan := make(chan *DeleteMeasureDataResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.DeleteMeasureData(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// DeleteMeasureDataWithCallback invokes the oms.DeleteMeasureData API asynchronously +func (client *Client) DeleteMeasureDataWithCallback(request *DeleteMeasureDataRequest, callback func(response *DeleteMeasureDataResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *DeleteMeasureDataResponse + var err error + defer close(result) + response, err = client.DeleteMeasureData(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// DeleteMeasureDataRequest is the request struct for api DeleteMeasureData +type DeleteMeasureDataRequest struct { + *requests.RpcRequest + Filter string `position:"Query" name:"Filter"` + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` + ApiType string `position:"Query" name:"ApiType"` +} + +// DeleteMeasureDataResponse is the response struct for api DeleteMeasureData +type DeleteMeasureDataResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + DataType string `json:"DataType" xml:"DataType"` + ApiType string `json:"ApiType" xml:"ApiType"` + Total int64 `json:"Total" xml:"Total"` +} + +// CreateDeleteMeasureDataRequest creates a request to invoke DeleteMeasureData API +func CreateDeleteMeasureDataRequest() (request *DeleteMeasureDataRequest) { + request = &DeleteMeasureDataRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "DeleteMeasureData", "", "") + request.Method = requests.POST + return +} + +// CreateDeleteMeasureDataResponse creates a response to parse from DeleteMeasureData response +func CreateDeleteMeasureDataResponse() (response *DeleteMeasureDataResponse) { + response = &DeleteMeasureDataResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_access_policy_config.go b/services/oms/get_access_policy_config.go new file mode 100644 index 0000000000..9de95ef448 --- /dev/null +++ b/services/oms/get_access_policy_config.go @@ -0,0 +1,103 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetAccessPolicyConfig invokes the oms.GetAccessPolicyConfig API synchronously +func (client *Client) GetAccessPolicyConfig(request *GetAccessPolicyConfigRequest) (response *GetAccessPolicyConfigResponse, err error) { + response = CreateGetAccessPolicyConfigResponse() + err = client.DoAction(request, response) + return +} + +// GetAccessPolicyConfigWithChan invokes the oms.GetAccessPolicyConfig API asynchronously +func (client *Client) GetAccessPolicyConfigWithChan(request *GetAccessPolicyConfigRequest) (<-chan *GetAccessPolicyConfigResponse, <-chan error) { + responseChan := make(chan *GetAccessPolicyConfigResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetAccessPolicyConfig(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetAccessPolicyConfigWithCallback invokes the oms.GetAccessPolicyConfig API asynchronously +func (client *Client) GetAccessPolicyConfigWithCallback(request *GetAccessPolicyConfigRequest, callback func(response *GetAccessPolicyConfigResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetAccessPolicyConfigResponse + var err error + defer close(result) + response, err = client.GetAccessPolicyConfig(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetAccessPolicyConfigRequest is the request struct for api GetAccessPolicyConfig +type GetAccessPolicyConfigRequest struct { + *requests.RpcRequest + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + AliUid string `position:"Query" name:"AliUid"` +} + +// GetAccessPolicyConfigResponse is the response struct for api GetAccessPolicyConfig +type GetAccessPolicyConfigResponse struct { + *responses.BaseResponse + Compressed bool `json:"Compressed" xml:"Compressed"` + AliUid string `json:"AliUid" xml:"AliUid"` + Data string `json:"Data" xml:"Data"` + RequestId string `json:"RequestId" xml:"RequestId"` +} + +// CreateGetAccessPolicyConfigRequest creates a request to invoke GetAccessPolicyConfig API +func CreateGetAccessPolicyConfigRequest() (request *GetAccessPolicyConfigRequest) { + request = &GetAccessPolicyConfigRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetAccessPolicyConfig", "", "") + request.Method = requests.GET + return +} + +// CreateGetAccessPolicyConfigResponse creates a response to parse from GetAccessPolicyConfig response +func CreateGetAccessPolicyConfigResponse() (response *GetAccessPolicyConfigResponse) { + response = &GetAccessPolicyConfigResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_domain_fields.go b/services/oms/get_domain_config.go similarity index 52% rename from services/oms/get_domain_fields.go rename to services/oms/get_domain_config.go index 362cde2e99..de17937514 100644 --- a/services/oms/get_domain_fields.go +++ b/services/oms/get_domain_config.go @@ -20,21 +20,21 @@ import ( "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" ) -// GetDomainFields invokes the oms.GetDomainFields API synchronously -func (client *Client) GetDomainFields(request *GetDomainFieldsRequest) (response *GetDomainFieldsResponse, err error) { - response = CreateGetDomainFieldsResponse() +// GetDomainConfig invokes the oms.GetDomainConfig API synchronously +func (client *Client) GetDomainConfig(request *GetDomainConfigRequest) (response *GetDomainConfigResponse, err error) { + response = CreateGetDomainConfigResponse() err = client.DoAction(request, response) return } -// GetDomainFieldsWithChan invokes the oms.GetDomainFields API asynchronously -func (client *Client) GetDomainFieldsWithChan(request *GetDomainFieldsRequest) (<-chan *GetDomainFieldsResponse, <-chan error) { - responseChan := make(chan *GetDomainFieldsResponse, 1) +// GetDomainConfigWithChan invokes the oms.GetDomainConfig API asynchronously +func (client *Client) GetDomainConfigWithChan(request *GetDomainConfigRequest) (<-chan *GetDomainConfigResponse, <-chan error) { + responseChan := make(chan *GetDomainConfigResponse, 1) errChan := make(chan error, 1) err := client.AddAsyncTask(func() { defer close(responseChan) defer close(errChan) - response, err := client.GetDomainFields(request) + response, err := client.GetDomainConfig(request) if err != nil { errChan <- err } else { @@ -49,14 +49,14 @@ func (client *Client) GetDomainFieldsWithChan(request *GetDomainFieldsRequest) ( return responseChan, errChan } -// GetDomainFieldsWithCallback invokes the oms.GetDomainFields API asynchronously -func (client *Client) GetDomainFieldsWithCallback(request *GetDomainFieldsRequest, callback func(response *GetDomainFieldsResponse, err error)) <-chan int { +// GetDomainConfigWithCallback invokes the oms.GetDomainConfig API asynchronously +func (client *Client) GetDomainConfigWithCallback(request *GetDomainConfigRequest, callback func(response *GetDomainConfigResponse, err error)) <-chan int { result := make(chan int, 1) err := client.AddAsyncTask(func() { - var response *GetDomainFieldsResponse + var response *GetDomainConfigResponse var err error defer close(result) - response, err = client.GetDomainFields(request) + response, err = client.GetDomainConfig(request) callback(response, err) result <- 1 }) @@ -68,34 +68,35 @@ func (client *Client) GetDomainFieldsWithCallback(request *GetDomainFieldsReques return result } -// GetDomainFieldsRequest is the request struct for api GetDomainFields -type GetDomainFieldsRequest struct { +// GetDomainConfigRequest is the request struct for api GetDomainConfig +type GetDomainConfigRequest struct { *requests.RpcRequest - DomainCode string `position:"Query" name:"DomainCode"` - UseCache requests.Boolean `position:"Query" name:"UseCache"` + DomainCode string `position:"Query" name:"DomainCode"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` } -// GetDomainFieldsResponse is the response struct for api GetDomainFields -type GetDomainFieldsResponse struct { +// GetDomainConfigResponse is the response struct for api GetDomainConfig +type GetDomainConfigResponse struct { *responses.BaseResponse + Compressed bool `json:"Compressed" xml:"Compressed"` Data string `json:"Data" xml:"Data"` RequestId string `json:"RequestId" xml:"RequestId"` DomainCode string `json:"DomainCode" xml:"DomainCode"` } -// CreateGetDomainFieldsRequest creates a request to invoke GetDomainFields API -func CreateGetDomainFieldsRequest() (request *GetDomainFieldsRequest) { - request = &GetDomainFieldsRequest{ +// CreateGetDomainConfigRequest creates a request to invoke GetDomainConfig API +func CreateGetDomainConfigRequest() (request *GetDomainConfigRequest) { + request = &GetDomainConfigRequest{ RpcRequest: &requests.RpcRequest{}, } - request.InitWithApiInfo("Oms", "2019-05-27", "GetDomainFields", "", "") + request.InitWithApiInfo("Oms", "2016-06-15", "GetDomainConfig", "", "") request.Method = requests.GET return } -// CreateGetDomainFieldsResponse creates a response to parse from GetDomainFields response -func CreateGetDomainFieldsResponse() (response *GetDomainFieldsResponse) { - response = &GetDomainFieldsResponse{ +// CreateGetDomainConfigResponse creates a response to parse from GetDomainConfig response +func CreateGetDomainConfigResponse() (response *GetDomainConfigResponse) { + response = &GetDomainConfigResponse{ BaseResponse: &responses.BaseResponse{}, } return diff --git a/services/oms/get_domain_part.go b/services/oms/get_domain_part.go new file mode 100644 index 0000000000..082ddffe1f --- /dev/null +++ b/services/oms/get_domain_part.go @@ -0,0 +1,106 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetDomainPart invokes the oms.GetDomainPart API synchronously +func (client *Client) GetDomainPart(request *GetDomainPartRequest) (response *GetDomainPartResponse, err error) { + response = CreateGetDomainPartResponse() + err = client.DoAction(request, response) + return +} + +// GetDomainPartWithChan invokes the oms.GetDomainPart API asynchronously +func (client *Client) GetDomainPartWithChan(request *GetDomainPartRequest) (<-chan *GetDomainPartResponse, <-chan error) { + responseChan := make(chan *GetDomainPartResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetDomainPart(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetDomainPartWithCallback invokes the oms.GetDomainPart API asynchronously +func (client *Client) GetDomainPartWithCallback(request *GetDomainPartRequest, callback func(response *GetDomainPartResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetDomainPartResponse + var err error + defer close(result) + response, err = client.GetDomainPart(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetDomainPartRequest is the request struct for api GetDomainPart +type GetDomainPartRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + Part string `position:"Query" name:"Part"` +} + +// GetDomainPartResponse is the response struct for api GetDomainPart +type GetDomainPartResponse struct { + *responses.BaseResponse + Compressed bool `json:"Compressed" xml:"Compressed"` + Data string `json:"Data" xml:"Data"` + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreateGetDomainPartRequest creates a request to invoke GetDomainPart API +func CreateGetDomainPartRequest() (request *GetDomainPartRequest) { + request = &GetDomainPartRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetDomainPart", "", "") + request.Method = requests.GET + return +} + +// CreateGetDomainPartResponse creates a response to parse from GetDomainPart response +func CreateGetDomainPartResponse() (response *GetDomainPartResponse) { + response = &GetDomainPartResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_domain_part_by_proxy.go b/services/oms/get_domain_part_by_proxy.go new file mode 100644 index 0000000000..1d6946ee49 --- /dev/null +++ b/services/oms/get_domain_part_by_proxy.go @@ -0,0 +1,106 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetDomainPartByProxy invokes the oms.GetDomainPartByProxy API synchronously +func (client *Client) GetDomainPartByProxy(request *GetDomainPartByProxyRequest) (response *GetDomainPartByProxyResponse, err error) { + response = CreateGetDomainPartByProxyResponse() + err = client.DoAction(request, response) + return +} + +// GetDomainPartByProxyWithChan invokes the oms.GetDomainPartByProxy API asynchronously +func (client *Client) GetDomainPartByProxyWithChan(request *GetDomainPartByProxyRequest) (<-chan *GetDomainPartByProxyResponse, <-chan error) { + responseChan := make(chan *GetDomainPartByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetDomainPartByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetDomainPartByProxyWithCallback invokes the oms.GetDomainPartByProxy API asynchronously +func (client *Client) GetDomainPartByProxyWithCallback(request *GetDomainPartByProxyRequest, callback func(response *GetDomainPartByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetDomainPartByProxyResponse + var err error + defer close(result) + response, err = client.GetDomainPartByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetDomainPartByProxyRequest is the request struct for api GetDomainPartByProxy +type GetDomainPartByProxyRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + Part string `position:"Query" name:"Part"` +} + +// GetDomainPartByProxyResponse is the response struct for api GetDomainPartByProxy +type GetDomainPartByProxyResponse struct { + *responses.BaseResponse + Compressed bool `json:"Compressed" xml:"Compressed"` + Data string `json:"Data" xml:"Data"` + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreateGetDomainPartByProxyRequest creates a request to invoke GetDomainPartByProxy API +func CreateGetDomainPartByProxyRequest() (request *GetDomainPartByProxyRequest) { + request = &GetDomainPartByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetDomainPartByProxy", "", "") + request.Method = requests.POST + return +} + +// CreateGetDomainPartByProxyResponse creates a response to parse from GetDomainPartByProxy response +func CreateGetDomainPartByProxyResponse() (response *GetDomainPartByProxyResponse) { + response = &GetDomainPartByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_domain_part_config.go b/services/oms/get_domain_part_config.go new file mode 100644 index 0000000000..6fdcb1d7c2 --- /dev/null +++ b/services/oms/get_domain_part_config.go @@ -0,0 +1,106 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetDomainPartConfig invokes the oms.GetDomainPartConfig API synchronously +func (client *Client) GetDomainPartConfig(request *GetDomainPartConfigRequest) (response *GetDomainPartConfigResponse, err error) { + response = CreateGetDomainPartConfigResponse() + err = client.DoAction(request, response) + return +} + +// GetDomainPartConfigWithChan invokes the oms.GetDomainPartConfig API asynchronously +func (client *Client) GetDomainPartConfigWithChan(request *GetDomainPartConfigRequest) (<-chan *GetDomainPartConfigResponse, <-chan error) { + responseChan := make(chan *GetDomainPartConfigResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetDomainPartConfig(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetDomainPartConfigWithCallback invokes the oms.GetDomainPartConfig API asynchronously +func (client *Client) GetDomainPartConfigWithCallback(request *GetDomainPartConfigRequest, callback func(response *GetDomainPartConfigResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetDomainPartConfigResponse + var err error + defer close(result) + response, err = client.GetDomainPartConfig(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetDomainPartConfigRequest is the request struct for api GetDomainPartConfig +type GetDomainPartConfigRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + Part string `position:"Query" name:"Part"` +} + +// GetDomainPartConfigResponse is the response struct for api GetDomainPartConfig +type GetDomainPartConfigResponse struct { + *responses.BaseResponse + Compressed bool `json:"Compressed" xml:"Compressed"` + Data string `json:"Data" xml:"Data"` + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreateGetDomainPartConfigRequest creates a request to invoke GetDomainPartConfig API +func CreateGetDomainPartConfigRequest() (request *GetDomainPartConfigRequest) { + request = &GetDomainPartConfigRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetDomainPartConfig", "", "") + request.Method = requests.GET + return +} + +// CreateGetDomainPartConfigResponse creates a response to parse from GetDomainPartConfig response +func CreateGetDomainPartConfigResponse() (response *GetDomainPartConfigResponse) { + response = &GetDomainPartConfigResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_file_config.go b/services/oms/get_file_config.go new file mode 100644 index 0000000000..a8f5fe4fc0 --- /dev/null +++ b/services/oms/get_file_config.go @@ -0,0 +1,104 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetFileConfig invokes the oms.GetFileConfig API synchronously +func (client *Client) GetFileConfig(request *GetFileConfigRequest) (response *GetFileConfigResponse, err error) { + response = CreateGetFileConfigResponse() + err = client.DoAction(request, response) + return +} + +// GetFileConfigWithChan invokes the oms.GetFileConfig API asynchronously +func (client *Client) GetFileConfigWithChan(request *GetFileConfigRequest) (<-chan *GetFileConfigResponse, <-chan error) { + responseChan := make(chan *GetFileConfigResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetFileConfig(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetFileConfigWithCallback invokes the oms.GetFileConfig API asynchronously +func (client *Client) GetFileConfigWithCallback(request *GetFileConfigRequest, callback func(response *GetFileConfigResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetFileConfigResponse + var err error + defer close(result) + response, err = client.GetFileConfig(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetFileConfigRequest is the request struct for api GetFileConfig +type GetFileConfigRequest struct { + *requests.RpcRequest + DimensionType string `position:"Query" name:"DimensionType"` + DomainCode string `position:"Query" name:"DomainCode"` +} + +// GetFileConfigResponse is the response struct for api GetFileConfig +type GetFileConfigResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + Data string `json:"Data" xml:"Data"` + Success bool `json:"Success" xml:"Success"` + ErrorCode string `json:"ErrorCode" xml:"ErrorCode"` + ErrorMessage string `json:"ErrorMessage" xml:"ErrorMessage"` +} + +// CreateGetFileConfigRequest creates a request to invoke GetFileConfig API +func CreateGetFileConfigRequest() (request *GetFileConfigRequest) { + request = &GetFileConfigRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetFileConfig", "", "") + request.Method = requests.GET + return +} + +// CreateGetFileConfigResponse creates a response to parse from GetFileConfig response +func CreateGetFileConfigResponse() (response *GetFileConfigResponse) { + response = &GetFileConfigResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_increment_measure_data_by_proxy.go b/services/oms/get_increment_measure_data_by_proxy.go new file mode 100644 index 0000000000..cc13c7f04f --- /dev/null +++ b/services/oms/get_increment_measure_data_by_proxy.go @@ -0,0 +1,108 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetIncrementMeasureDataByProxy invokes the oms.GetIncrementMeasureDataByProxy API synchronously +func (client *Client) GetIncrementMeasureDataByProxy(request *GetIncrementMeasureDataByProxyRequest) (response *GetIncrementMeasureDataByProxyResponse, err error) { + response = CreateGetIncrementMeasureDataByProxyResponse() + err = client.DoAction(request, response) + return +} + +// GetIncrementMeasureDataByProxyWithChan invokes the oms.GetIncrementMeasureDataByProxy API asynchronously +func (client *Client) GetIncrementMeasureDataByProxyWithChan(request *GetIncrementMeasureDataByProxyRequest) (<-chan *GetIncrementMeasureDataByProxyResponse, <-chan error) { + responseChan := make(chan *GetIncrementMeasureDataByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetIncrementMeasureDataByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetIncrementMeasureDataByProxyWithCallback invokes the oms.GetIncrementMeasureDataByProxy API asynchronously +func (client *Client) GetIncrementMeasureDataByProxyWithCallback(request *GetIncrementMeasureDataByProxyRequest, callback func(response *GetIncrementMeasureDataByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetIncrementMeasureDataByProxyResponse + var err error + defer close(result) + response, err = client.GetIncrementMeasureDataByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetIncrementMeasureDataByProxyRequest is the request struct for api GetIncrementMeasureDataByProxy +type GetIncrementMeasureDataByProxyRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + ModifyEndTime requests.Integer `position:"Query" name:"ModifyEndTime"` + DataType string `position:"Query" name:"DataType"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + RowKeyMapStr string `position:"Query" name:"RowKeyMapStr"` + ModifyStartTime requests.Integer `position:"Query" name:"ModifyStartTime"` +} + +// GetIncrementMeasureDataByProxyResponse is the response struct for api GetIncrementMeasureDataByProxy +type GetIncrementMeasureDataByProxyResponse struct { + *responses.BaseResponse + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + DataType string `json:"DataType" xml:"DataType"` + Data string `json:"Data" xml:"Data"` + Compressed string `json:"Compressed" xml:"Compressed"` +} + +// CreateGetIncrementMeasureDataByProxyRequest creates a request to invoke GetIncrementMeasureDataByProxy API +func CreateGetIncrementMeasureDataByProxyRequest() (request *GetIncrementMeasureDataByProxyRequest) { + request = &GetIncrementMeasureDataByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetIncrementMeasureDataByProxy", "", "") + request.Method = requests.GET + return +} + +// CreateGetIncrementMeasureDataByProxyResponse creates a response to parse from GetIncrementMeasureDataByProxy response +func CreateGetIncrementMeasureDataByProxyResponse() (response *GetIncrementMeasureDataByProxyResponse) { + response = &GetIncrementMeasureDataByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_measure_data.go b/services/oms/get_measure_data.go new file mode 100644 index 0000000000..09d7d4c327 --- /dev/null +++ b/services/oms/get_measure_data.go @@ -0,0 +1,112 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetMeasureData invokes the oms.GetMeasureData API synchronously +func (client *Client) GetMeasureData(request *GetMeasureDataRequest) (response *GetMeasureDataResponse, err error) { + response = CreateGetMeasureDataResponse() + err = client.DoAction(request, response) + return +} + +// GetMeasureDataWithChan invokes the oms.GetMeasureData API asynchronously +func (client *Client) GetMeasureDataWithChan(request *GetMeasureDataRequest) (<-chan *GetMeasureDataResponse, <-chan error) { + responseChan := make(chan *GetMeasureDataResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetMeasureData(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetMeasureDataWithCallback invokes the oms.GetMeasureData API asynchronously +func (client *Client) GetMeasureDataWithCallback(request *GetMeasureDataRequest, callback func(response *GetMeasureDataResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetMeasureDataResponse + var err error + defer close(result) + response, err = client.GetMeasureData(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetMeasureDataRequest is the request struct for api GetMeasureData +type GetMeasureDataRequest struct { + *requests.RpcRequest + Filter string `position:"Query" name:"Filter"` + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + QueryField string `position:"Query" name:"QueryField"` + NextToken string `position:"Query" name:"NextToken"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + ApiType string `position:"Query" name:"ApiType"` + MaxResult requests.Integer `position:"Query" name:"MaxResult"` +} + +// GetMeasureDataResponse is the response struct for api GetMeasureData +type GetMeasureDataResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + NextToken string `json:"NextToken" xml:"NextToken"` + Data string `json:"Data" xml:"Data"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` + Compressed bool `json:"Compressed" xml:"Compressed"` +} + +// CreateGetMeasureDataRequest creates a request to invoke GetMeasureData API +func CreateGetMeasureDataRequest() (request *GetMeasureDataRequest) { + request = &GetMeasureDataRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetMeasureData", "", "") + request.Method = requests.POST + return +} + +// CreateGetMeasureDataResponse creates a response to parse from GetMeasureData response +func CreateGetMeasureDataResponse() (response *GetMeasureDataResponse) { + response = &GetMeasureDataResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_open_api_config.go b/services/oms/get_open_api_config.go new file mode 100644 index 0000000000..caf4dcf602 --- /dev/null +++ b/services/oms/get_open_api_config.go @@ -0,0 +1,109 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetOpenApiConfig invokes the oms.GetOpenApiConfig API synchronously +func (client *Client) GetOpenApiConfig(request *GetOpenApiConfigRequest) (response *GetOpenApiConfigResponse, err error) { + response = CreateGetOpenApiConfigResponse() + err = client.DoAction(request, response) + return +} + +// GetOpenApiConfigWithChan invokes the oms.GetOpenApiConfig API asynchronously +func (client *Client) GetOpenApiConfigWithChan(request *GetOpenApiConfigRequest) (<-chan *GetOpenApiConfigResponse, <-chan error) { + responseChan := make(chan *GetOpenApiConfigResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetOpenApiConfig(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetOpenApiConfigWithCallback invokes the oms.GetOpenApiConfig API asynchronously +func (client *Client) GetOpenApiConfigWithCallback(request *GetOpenApiConfigRequest, callback func(response *GetOpenApiConfigResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetOpenApiConfigResponse + var err error + defer close(result) + response, err = client.GetOpenApiConfig(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetOpenApiConfigRequest is the request struct for api GetOpenApiConfig +type GetOpenApiConfigRequest struct { + *requests.RpcRequest + DataType string `position:"Query" name:"DataType"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + ProductName string `position:"Query" name:"ProductName"` + TableName string `position:"Query" name:"TableName"` + SiteBid string `position:"Query" name:"siteBid"` +} + +// GetOpenApiConfigResponse is the response struct for api GetOpenApiConfig +type GetOpenApiConfigResponse struct { + *responses.BaseResponse + TableName string `json:"TableName" xml:"TableName"` + DataType string `json:"DataType" xml:"DataType"` + Data string `json:"Data" xml:"Data"` + RequestId string `json:"RequestId" xml:"RequestId"` + ProductName string `json:"ProductName" xml:"ProductName"` + Compressed bool `json:"Compressed" xml:"Compressed"` + SiteBid string `json:"SiteBid" xml:"SiteBid"` +} + +// CreateGetOpenApiConfigRequest creates a request to invoke GetOpenApiConfig API +func CreateGetOpenApiConfigRequest() (request *GetOpenApiConfigRequest) { + request = &GetOpenApiConfigRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetOpenApiConfig", "", "") + request.Method = requests.GET + return +} + +// CreateGetOpenApiConfigResponse creates a response to parse from GetOpenApiConfig response +func CreateGetOpenApiConfigResponse() (response *GetOpenApiConfigResponse) { + response = &GetOpenApiConfigResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_ready_flag.go b/services/oms/get_ready_flag.go new file mode 100644 index 0000000000..6f45ec4c68 --- /dev/null +++ b/services/oms/get_ready_flag.go @@ -0,0 +1,111 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetReadyFlag invokes the oms.GetReadyFlag API synchronously +func (client *Client) GetReadyFlag(request *GetReadyFlagRequest) (response *GetReadyFlagResponse, err error) { + response = CreateGetReadyFlagResponse() + err = client.DoAction(request, response) + return +} + +// GetReadyFlagWithChan invokes the oms.GetReadyFlag API asynchronously +func (client *Client) GetReadyFlagWithChan(request *GetReadyFlagRequest) (<-chan *GetReadyFlagResponse, <-chan error) { + responseChan := make(chan *GetReadyFlagResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetReadyFlag(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetReadyFlagWithCallback invokes the oms.GetReadyFlag API asynchronously +func (client *Client) GetReadyFlagWithCallback(request *GetReadyFlagRequest, callback func(response *GetReadyFlagResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetReadyFlagResponse + var err error + defer close(result) + response, err = client.GetReadyFlag(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetReadyFlagRequest is the request struct for api GetReadyFlag +type GetReadyFlagRequest struct { + *requests.RpcRequest + Filter string `position:"Query" name:"Filter"` + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + NextToken string `position:"Query" name:"NextToken"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + ApiType string `position:"Query" name:"ApiType"` + MaxResult requests.Integer `position:"Query" name:"MaxResult"` +} + +// GetReadyFlagResponse is the response struct for api GetReadyFlag +type GetReadyFlagResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + NextToken string `json:"NextToken" xml:"NextToken"` + Data string `json:"Data" xml:"Data"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` + Compressed bool `json:"Compressed" xml:"Compressed"` +} + +// CreateGetReadyFlagRequest creates a request to invoke GetReadyFlag API +func CreateGetReadyFlagRequest() (request *GetReadyFlagRequest) { + request = &GetReadyFlagRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetReadyFlag", "", "") + request.Method = requests.GET + return +} + +// CreateGetReadyFlagResponse creates a response to parse from GetReadyFlag response +func CreateGetReadyFlagResponse() (response *GetReadyFlagResponse) { + response = &GetReadyFlagResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_ready_flag_alert_config.go b/services/oms/get_ready_flag_alert_config.go new file mode 100644 index 0000000000..599fb21f98 --- /dev/null +++ b/services/oms/get_ready_flag_alert_config.go @@ -0,0 +1,105 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetReadyFlagAlertConfig invokes the oms.GetReadyFlagAlertConfig API synchronously +func (client *Client) GetReadyFlagAlertConfig(request *GetReadyFlagAlertConfigRequest) (response *GetReadyFlagAlertConfigResponse, err error) { + response = CreateGetReadyFlagAlertConfigResponse() + err = client.DoAction(request, response) + return +} + +// GetReadyFlagAlertConfigWithChan invokes the oms.GetReadyFlagAlertConfig API asynchronously +func (client *Client) GetReadyFlagAlertConfigWithChan(request *GetReadyFlagAlertConfigRequest) (<-chan *GetReadyFlagAlertConfigResponse, <-chan error) { + responseChan := make(chan *GetReadyFlagAlertConfigResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetReadyFlagAlertConfig(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetReadyFlagAlertConfigWithCallback invokes the oms.GetReadyFlagAlertConfig API asynchronously +func (client *Client) GetReadyFlagAlertConfigWithCallback(request *GetReadyFlagAlertConfigRequest, callback func(response *GetReadyFlagAlertConfigResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetReadyFlagAlertConfigResponse + var err error + defer close(result) + response, err = client.GetReadyFlagAlertConfig(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetReadyFlagAlertConfigRequest is the request struct for api GetReadyFlagAlertConfig +type GetReadyFlagAlertConfigRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` +} + +// GetReadyFlagAlertConfigResponse is the response struct for api GetReadyFlagAlertConfig +type GetReadyFlagAlertConfigResponse struct { + *responses.BaseResponse + Compressed bool `json:"Compressed" xml:"Compressed"` + Data string `json:"Data" xml:"Data"` + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreateGetReadyFlagAlertConfigRequest creates a request to invoke GetReadyFlagAlertConfig API +func CreateGetReadyFlagAlertConfigRequest() (request *GetReadyFlagAlertConfigRequest) { + request = &GetReadyFlagAlertConfigRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetReadyFlagAlertConfig", "", "") + request.Method = requests.GET + return +} + +// CreateGetReadyFlagAlertConfigResponse creates a response to parse from GetReadyFlagAlertConfig response +func CreateGetReadyFlagAlertConfigResponse() (response *GetReadyFlagAlertConfigResponse) { + response = &GetReadyFlagAlertConfigResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/get_ready_flag_by_proxy.go b/services/oms/get_ready_flag_by_proxy.go new file mode 100644 index 0000000000..426115614a --- /dev/null +++ b/services/oms/get_ready_flag_by_proxy.go @@ -0,0 +1,111 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// GetReadyFlagByProxy invokes the oms.GetReadyFlagByProxy API synchronously +func (client *Client) GetReadyFlagByProxy(request *GetReadyFlagByProxyRequest) (response *GetReadyFlagByProxyResponse, err error) { + response = CreateGetReadyFlagByProxyResponse() + err = client.DoAction(request, response) + return +} + +// GetReadyFlagByProxyWithChan invokes the oms.GetReadyFlagByProxy API asynchronously +func (client *Client) GetReadyFlagByProxyWithChan(request *GetReadyFlagByProxyRequest) (<-chan *GetReadyFlagByProxyResponse, <-chan error) { + responseChan := make(chan *GetReadyFlagByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.GetReadyFlagByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// GetReadyFlagByProxyWithCallback invokes the oms.GetReadyFlagByProxy API asynchronously +func (client *Client) GetReadyFlagByProxyWithCallback(request *GetReadyFlagByProxyRequest, callback func(response *GetReadyFlagByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *GetReadyFlagByProxyResponse + var err error + defer close(result) + response, err = client.GetReadyFlagByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// GetReadyFlagByProxyRequest is the request struct for api GetReadyFlagByProxy +type GetReadyFlagByProxyRequest struct { + *requests.RpcRequest + Filter string `position:"Query" name:"Filter"` + DomainCode string `position:"Query" name:"DomainCode"` + DataType string `position:"Query" name:"DataType"` + NextToken string `position:"Query" name:"NextToken"` + CompressEnable requests.Boolean `position:"Query" name:"CompressEnable"` + ApiType string `position:"Query" name:"ApiType"` + MaxResult requests.Integer `position:"Query" name:"MaxResult"` +} + +// GetReadyFlagByProxyResponse is the response struct for api GetReadyFlagByProxy +type GetReadyFlagByProxyResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + NextToken string `json:"NextToken" xml:"NextToken"` + Data string `json:"Data" xml:"Data"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` + Compressed bool `json:"Compressed" xml:"Compressed"` +} + +// CreateGetReadyFlagByProxyRequest creates a request to invoke GetReadyFlagByProxy API +func CreateGetReadyFlagByProxyRequest() (request *GetReadyFlagByProxyRequest) { + request = &GetReadyFlagByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "GetReadyFlagByProxy", "", "") + request.Method = requests.POST + return +} + +// CreateGetReadyFlagByProxyResponse creates a response to parse from GetReadyFlagByProxy response +func CreateGetReadyFlagByProxyResponse() (response *GetReadyFlagByProxyResponse) { + response = &GetReadyFlagByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/put_domain_part.go b/services/oms/put_domain_part.go new file mode 100644 index 0000000000..a1d880c12b --- /dev/null +++ b/services/oms/put_domain_part.go @@ -0,0 +1,104 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// PutDomainPart invokes the oms.PutDomainPart API synchronously +func (client *Client) PutDomainPart(request *PutDomainPartRequest) (response *PutDomainPartResponse, err error) { + response = CreatePutDomainPartResponse() + err = client.DoAction(request, response) + return +} + +// PutDomainPartWithChan invokes the oms.PutDomainPart API asynchronously +func (client *Client) PutDomainPartWithChan(request *PutDomainPartRequest) (<-chan *PutDomainPartResponse, <-chan error) { + responseChan := make(chan *PutDomainPartResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.PutDomainPart(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// PutDomainPartWithCallback invokes the oms.PutDomainPart API asynchronously +func (client *Client) PutDomainPartWithCallback(request *PutDomainPartRequest, callback func(response *PutDomainPartResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *PutDomainPartResponse + var err error + defer close(result) + response, err = client.PutDomainPart(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// PutDomainPartRequest is the request struct for api PutDomainPart +type PutDomainPartRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` +} + +// PutDomainPartResponse is the response struct for api PutDomainPart +type PutDomainPartResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreatePutDomainPartRequest creates a request to invoke PutDomainPart API +func CreatePutDomainPartRequest() (request *PutDomainPartRequest) { + request = &PutDomainPartRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "PutDomainPart", "", "") + request.Method = requests.POST + return +} + +// CreatePutDomainPartResponse creates a response to parse from PutDomainPart response +func CreatePutDomainPartResponse() (response *PutDomainPartResponse) { + response = &PutDomainPartResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/put_domain_part_by_proxy.go b/services/oms/put_domain_part_by_proxy.go new file mode 100644 index 0000000000..1873da5ea3 --- /dev/null +++ b/services/oms/put_domain_part_by_proxy.go @@ -0,0 +1,104 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// PutDomainPartByProxy invokes the oms.PutDomainPartByProxy API synchronously +func (client *Client) PutDomainPartByProxy(request *PutDomainPartByProxyRequest) (response *PutDomainPartByProxyResponse, err error) { + response = CreatePutDomainPartByProxyResponse() + err = client.DoAction(request, response) + return +} + +// PutDomainPartByProxyWithChan invokes the oms.PutDomainPartByProxy API asynchronously +func (client *Client) PutDomainPartByProxyWithChan(request *PutDomainPartByProxyRequest) (<-chan *PutDomainPartByProxyResponse, <-chan error) { + responseChan := make(chan *PutDomainPartByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.PutDomainPartByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// PutDomainPartByProxyWithCallback invokes the oms.PutDomainPartByProxy API asynchronously +func (client *Client) PutDomainPartByProxyWithCallback(request *PutDomainPartByProxyRequest, callback func(response *PutDomainPartByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *PutDomainPartByProxyResponse + var err error + defer close(result) + response, err = client.PutDomainPartByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// PutDomainPartByProxyRequest is the request struct for api PutDomainPartByProxy +type PutDomainPartByProxyRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` +} + +// PutDomainPartByProxyResponse is the response struct for api PutDomainPartByProxy +type PutDomainPartByProxyResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` +} + +// CreatePutDomainPartByProxyRequest creates a request to invoke PutDomainPartByProxy API +func CreatePutDomainPartByProxyRequest() (request *PutDomainPartByProxyRequest) { + request = &PutDomainPartByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "PutDomainPartByProxy", "", "") + request.Method = requests.POST + return +} + +// CreatePutDomainPartByProxyResponse creates a response to parse from PutDomainPartByProxy response +func CreatePutDomainPartByProxyResponse() (response *PutDomainPartByProxyResponse) { + response = &PutDomainPartByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/put_measure_data.go b/services/oms/put_measure_data.go new file mode 100644 index 0000000000..27e9e1d9ea --- /dev/null +++ b/services/oms/put_measure_data.go @@ -0,0 +1,109 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// PutMeasureData invokes the oms.PutMeasureData API synchronously +func (client *Client) PutMeasureData(request *PutMeasureDataRequest) (response *PutMeasureDataResponse, err error) { + response = CreatePutMeasureDataResponse() + err = client.DoAction(request, response) + return +} + +// PutMeasureDataWithChan invokes the oms.PutMeasureData API asynchronously +func (client *Client) PutMeasureDataWithChan(request *PutMeasureDataRequest) (<-chan *PutMeasureDataResponse, <-chan error) { + responseChan := make(chan *PutMeasureDataResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.PutMeasureData(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// PutMeasureDataWithCallback invokes the oms.PutMeasureData API asynchronously +func (client *Client) PutMeasureDataWithCallback(request *PutMeasureDataRequest, callback func(response *PutMeasureDataResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *PutMeasureDataResponse + var err error + defer close(result) + response, err = client.PutMeasureData(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// PutMeasureDataRequest is the request struct for api PutMeasureData +type PutMeasureDataRequest struct { + *requests.RpcRequest + Filter string `position:"Query" name:"Filter"` + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` + ApiType string `position:"Query" name:"ApiType"` + SourceRequestId string `position:"Query" name:"SourceRequestId"` +} + +// PutMeasureDataResponse is the response struct for api PutMeasureData +type PutMeasureDataResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` + SourceRequestId string `json:"SourceRequestId" xml:"SourceRequestId"` +} + +// CreatePutMeasureDataRequest creates a request to invoke PutMeasureData API +func CreatePutMeasureDataRequest() (request *PutMeasureDataRequest) { + request = &PutMeasureDataRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "PutMeasureData", "", "") + request.Method = requests.POST + return +} + +// CreatePutMeasureDataResponse creates a response to parse from PutMeasureData response +func CreatePutMeasureDataResponse() (response *PutMeasureDataResponse) { + response = &PutMeasureDataResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/put_measure_data_by_proxy.go b/services/oms/put_measure_data_by_proxy.go new file mode 100644 index 0000000000..49b2e9af4a --- /dev/null +++ b/services/oms/put_measure_data_by_proxy.go @@ -0,0 +1,107 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// PutMeasureDataByProxy invokes the oms.PutMeasureDataByProxy API synchronously +func (client *Client) PutMeasureDataByProxy(request *PutMeasureDataByProxyRequest) (response *PutMeasureDataByProxyResponse, err error) { + response = CreatePutMeasureDataByProxyResponse() + err = client.DoAction(request, response) + return +} + +// PutMeasureDataByProxyWithChan invokes the oms.PutMeasureDataByProxy API asynchronously +func (client *Client) PutMeasureDataByProxyWithChan(request *PutMeasureDataByProxyRequest) (<-chan *PutMeasureDataByProxyResponse, <-chan error) { + responseChan := make(chan *PutMeasureDataByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.PutMeasureDataByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// PutMeasureDataByProxyWithCallback invokes the oms.PutMeasureDataByProxy API asynchronously +func (client *Client) PutMeasureDataByProxyWithCallback(request *PutMeasureDataByProxyRequest, callback func(response *PutMeasureDataByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *PutMeasureDataByProxyResponse + var err error + defer close(result) + response, err = client.PutMeasureDataByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// PutMeasureDataByProxyRequest is the request struct for api PutMeasureDataByProxy +type PutMeasureDataByProxyRequest struct { + *requests.RpcRequest + Filter string `position:"Query" name:"Filter"` + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` + ApiType string `position:"Query" name:"ApiType"` +} + +// PutMeasureDataByProxyResponse is the response struct for api PutMeasureDataByProxy +type PutMeasureDataByProxyResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` +} + +// CreatePutMeasureDataByProxyRequest creates a request to invoke PutMeasureDataByProxy API +func CreatePutMeasureDataByProxyRequest() (request *PutMeasureDataByProxyRequest) { + request = &PutMeasureDataByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "PutMeasureDataByProxy", "", "") + request.Method = requests.POST + return +} + +// CreatePutMeasureDataByProxyResponse creates a response to parse from PutMeasureDataByProxy response +func CreatePutMeasureDataByProxyResponse() (response *PutMeasureDataByProxyResponse) { + response = &PutMeasureDataByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/put_ready_flag.go b/services/oms/put_ready_flag.go new file mode 100644 index 0000000000..be4af5073b --- /dev/null +++ b/services/oms/put_ready_flag.go @@ -0,0 +1,108 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// PutReadyFlag invokes the oms.PutReadyFlag API synchronously +func (client *Client) PutReadyFlag(request *PutReadyFlagRequest) (response *PutReadyFlagResponse, err error) { + response = CreatePutReadyFlagResponse() + err = client.DoAction(request, response) + return +} + +// PutReadyFlagWithChan invokes the oms.PutReadyFlag API asynchronously +func (client *Client) PutReadyFlagWithChan(request *PutReadyFlagRequest) (<-chan *PutReadyFlagResponse, <-chan error) { + responseChan := make(chan *PutReadyFlagResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.PutReadyFlag(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// PutReadyFlagWithCallback invokes the oms.PutReadyFlag API asynchronously +func (client *Client) PutReadyFlagWithCallback(request *PutReadyFlagRequest, callback func(response *PutReadyFlagResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *PutReadyFlagResponse + var err error + defer close(result) + response, err = client.PutReadyFlag(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// PutReadyFlagRequest is the request struct for api PutReadyFlag +type PutReadyFlagRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` + ApiType string `position:"Query" name:"ApiType"` + SourceRequestId string `position:"Query" name:"SourceRequestId"` +} + +// PutReadyFlagResponse is the response struct for api PutReadyFlag +type PutReadyFlagResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` + SourceRequestId string `json:"SourceRequestId" xml:"SourceRequestId"` +} + +// CreatePutReadyFlagRequest creates a request to invoke PutReadyFlag API +func CreatePutReadyFlagRequest() (request *PutReadyFlagRequest) { + request = &PutReadyFlagRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "PutReadyFlag", "", "") + request.Method = requests.POST + return +} + +// CreatePutReadyFlagResponse creates a response to parse from PutReadyFlag response +func CreatePutReadyFlagResponse() (response *PutReadyFlagResponse) { + response = &PutReadyFlagResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +} diff --git a/services/oms/put_ready_flag_by_proxy.go b/services/oms/put_ready_flag_by_proxy.go new file mode 100644 index 0000000000..70025e46c9 --- /dev/null +++ b/services/oms/put_ready_flag_by_proxy.go @@ -0,0 +1,106 @@ +package oms + +//Licensed under the Apache License, Version 2.0 (the "License"); +//you may not use this file except in compliance with the License. +//You may obtain a copy of the License at +// +//http://www.apache.org/licenses/LICENSE-2.0 +// +//Unless required by applicable law or agreed to in writing, software +//distributed under the License is distributed on an "AS IS" BASIS, +//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +//See the License for the specific language governing permissions and +//limitations under the License. +// +// Code generated by Alibaba Cloud SDK Code Generator. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +import ( + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests" + "github.com/aliyun/alibaba-cloud-sdk-go/sdk/responses" +) + +// PutReadyFlagByProxy invokes the oms.PutReadyFlagByProxy API synchronously +func (client *Client) PutReadyFlagByProxy(request *PutReadyFlagByProxyRequest) (response *PutReadyFlagByProxyResponse, err error) { + response = CreatePutReadyFlagByProxyResponse() + err = client.DoAction(request, response) + return +} + +// PutReadyFlagByProxyWithChan invokes the oms.PutReadyFlagByProxy API asynchronously +func (client *Client) PutReadyFlagByProxyWithChan(request *PutReadyFlagByProxyRequest) (<-chan *PutReadyFlagByProxyResponse, <-chan error) { + responseChan := make(chan *PutReadyFlagByProxyResponse, 1) + errChan := make(chan error, 1) + err := client.AddAsyncTask(func() { + defer close(responseChan) + defer close(errChan) + response, err := client.PutReadyFlagByProxy(request) + if err != nil { + errChan <- err + } else { + responseChan <- response + } + }) + if err != nil { + errChan <- err + close(responseChan) + close(errChan) + } + return responseChan, errChan +} + +// PutReadyFlagByProxyWithCallback invokes the oms.PutReadyFlagByProxy API asynchronously +func (client *Client) PutReadyFlagByProxyWithCallback(request *PutReadyFlagByProxyRequest, callback func(response *PutReadyFlagByProxyResponse, err error)) <-chan int { + result := make(chan int, 1) + err := client.AddAsyncTask(func() { + var response *PutReadyFlagByProxyResponse + var err error + defer close(result) + response, err = client.PutReadyFlagByProxy(request) + callback(response, err) + result <- 1 + }) + if err != nil { + defer close(result) + callback(nil, err) + result <- 0 + } + return result +} + +// PutReadyFlagByProxyRequest is the request struct for api PutReadyFlagByProxy +type PutReadyFlagByProxyRequest struct { + *requests.RpcRequest + DomainCode string `position:"Query" name:"DomainCode"` + Data string `position:"Query" name:"Data"` + DataType string `position:"Query" name:"DataType"` + Compressed requests.Boolean `position:"Query" name:"Compressed"` + ApiType string `position:"Query" name:"ApiType"` +} + +// PutReadyFlagByProxyResponse is the response struct for api PutReadyFlagByProxy +type PutReadyFlagByProxyResponse struct { + *responses.BaseResponse + DataType string `json:"DataType" xml:"DataType"` + RequestId string `json:"RequestId" xml:"RequestId"` + DomainCode string `json:"DomainCode" xml:"DomainCode"` + ApiType string `json:"ApiType" xml:"ApiType"` +} + +// CreatePutReadyFlagByProxyRequest creates a request to invoke PutReadyFlagByProxy API +func CreatePutReadyFlagByProxyRequest() (request *PutReadyFlagByProxyRequest) { + request = &PutReadyFlagByProxyRequest{ + RpcRequest: &requests.RpcRequest{}, + } + request.InitWithApiInfo("Oms", "2016-06-15", "PutReadyFlagByProxy", "", "") + request.Method = requests.POST + return +} + +// CreatePutReadyFlagByProxyResponse creates a response to parse from PutReadyFlagByProxy response +func CreatePutReadyFlagByProxyResponse() (response *PutReadyFlagByProxyResponse) { + response = &PutReadyFlagByProxyResponse{ + BaseResponse: &responses.BaseResponse{}, + } + return +}