# frozen_string_literal: true
# Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
#
# 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.
require 'json'
module TencentCloud
module Teo
module V20220901
class Client < TencentCloud::Common::AbstractClient
def initialize(credential, region, profile = nil)
api_version = '2022-09-01'
api_endpoint = 'teo.tencentcloudapi.com'
sdk_version = 'TEO_' + File.read(File.expand_path('../VERSION', __dir__)).strip
super(credential, region, api_version, api_endpoint, sdk_version, profile)
end
# 操作安全策略模板,支持将域名绑定或换绑到指定的策略模板,或者从指定的策略模板解绑。
# @param request: Request instance for BindSecurityTemplateToEntity.
# @type request: :class:`Tencentcloud::teo::V20220901::BindSecurityTemplateToEntityRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::BindSecurityTemplateToEntityResponse`
def BindSecurityTemplateToEntity(request)
body = send_request('BindSecurityTemplateToEntity', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = BindSecurityTemplateToEntityResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于加速域名绑定或解绑共享 CNAME,该功能白名单内测中。
# @param request: Request instance for BindSharedCNAME.
# @type request: :class:`Tencentcloud::teo::V20220901::BindSharedCNAMERequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::BindSharedCNAMEResponse`
def BindSharedCNAME(request)
body = send_request('BindSharedCNAME', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = BindSharedCNAMEResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 将未绑定套餐的站点绑定到已有套餐
# @param request: Request instance for BindZoneToPlan.
# @type request: :class:`Tencentcloud::teo::V20220901::BindZoneToPlanRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::BindZoneToPlanResponse`
def BindZoneToPlan(request)
body = send_request('BindZoneToPlan', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = BindZoneToPlanResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 校验域名 CNAME 状态
# @param request: Request instance for CheckCnameStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::CheckCnameStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CheckCnameStatusResponse`
def CheckCnameStatus(request)
body = send_request('CheckCnameStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CheckCnameStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在创建完站点之后,您可以通过本接口创建加速域名。
# CNAME 模式接入时,若您未完成站点归属权校验,本接口将为您返回域名归属权验证信息,您可以单独对域名进行归属权验证,详情参考 [站点/域名归属权验证](https://cloud.tencent.com/document/product/1552/70789)。
# @param request: Request instance for CreateAccelerationDomain.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateAccelerationDomainRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateAccelerationDomainResponse`
def CreateAccelerationDomain(request)
body = send_request('CreateAccelerationDomain', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateAccelerationDomainResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建别称域名。
# @param request: Request instance for CreateAliasDomain.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateAliasDomainRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateAliasDomainResponse`
def CreateAliasDomain(request)
body = send_request('CreateAliasDomain', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateAliasDomainResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版 [创建四层代理实例](https://cloud.tencent.com/document/product/1552/103417) 。
# @param request: Request instance for CreateApplicationProxy.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateApplicationProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateApplicationProxyResponse`
def CreateApplicationProxy(request)
body = send_request('CreateApplicationProxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateApplicationProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [创建四层代理转发规则
# ](https://cloud.tencent.com/document/product/1552/103416) 。
# @param request: Request instance for CreateApplicationProxyRule.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateApplicationProxyRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateApplicationProxyRuleResponse`
def CreateApplicationProxyRule(request)
body = send_request('CreateApplicationProxyRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateApplicationProxyRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 针对指定实时日志投递任务(task-id),在对应的腾讯云 CLS 日志主题中创建投递日志字段对应的键值索引。如果您在腾讯云 CLS 已经创建索引,本接口将采用合并的方式追加索引。
# @param request: Request instance for CreateCLSIndex.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateCLSIndexRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateCLSIndexResponse`
def CreateCLSIndex(request)
body = send_request('CreateCLSIndex', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateCLSIndexResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在版本管理模式下,用于创建指定配置组的新版本。版本管理功能内测中,当前仅白名单开放。
# @param request: Request instance for CreateConfigGroupVersion.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateConfigGroupVersionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateConfigGroupVersionResponse`
def CreateConfigGroupVersion(request)
body = send_request('CreateConfigGroupVersion', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateConfigGroupVersionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建自定义错误页面。
# @param request: Request instance for CreateCustomizeErrorPage.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateCustomizeErrorPageRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateCustomizeErrorPageResponse`
def CreateCustomizeErrorPage(request)
body = send_request('CreateCustomizeErrorPage', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateCustomizeErrorPageResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建并部署边缘函数至 EdgeOne 的边缘节点。
# @param request: Request instance for CreateFunction.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateFunctionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateFunctionResponse`
def CreateFunction(request)
body = send_request('CreateFunction', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateFunctionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建边缘函数的触发规则。
# @param request: Request instance for CreateFunctionRule.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateFunctionRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateFunctionRuleResponse`
def CreateFunctionRule(request)
body = send_request('CreateFunctionRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateFunctionRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于创建四层代理实例。
# @param request: Request instance for CreateL4Proxy.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateL4ProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateL4ProxyResponse`
def CreateL4Proxy(request)
body = send_request('CreateL4Proxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateL4ProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于创建四层代理实例规则,支持单条或者批量创建。
# @param request: Request instance for CreateL4ProxyRules.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateL4ProxyRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateL4ProxyRulesResponse`
def CreateL4ProxyRules(request)
body = send_request('CreateL4ProxyRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateL4ProxyRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建负载均衡实例。详情请参考 [快速创建负载均衡实例](https://cloud.tencent.com/document/product/1552/104223)。负载均衡功能内测中,如您需要使用请 [联系我们](https://cloud.tencent.com/online-service)。
# @param request: Request instance for CreateLoadBalancer.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateLoadBalancerRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateLoadBalancerResponse`
def CreateLoadBalancer(request)
body = send_request('CreateLoadBalancer', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateLoadBalancerResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建源站组,以源站组的方式管理业务源站。此处配置的源站组可于**添加加速域名**和**四层代理**等功能中引用。
# @param request: Request instance for CreateOriginGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateOriginGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateOriginGroupResponse`
def CreateOriginGroup(request)
body = send_request('CreateOriginGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateOriginGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 若您需要使用 Edgeone 产品,您需要通过此接口创建计费套餐。
# > 创建套餐后,您需要通过 [CreateZone](https://cloud.tencent.com/document/product/1552/80719) 完成创建站点,绑定套餐的流程,Edgeone 才能正常提供服务。
# @param request: Request instance for CreatePlan.
# @type request: :class:`Tencentcloud::teo::V20220901::CreatePlanRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreatePlanResponse`
def CreatePlan(request)
body = send_request('CreatePlan', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreatePlanResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 为未购买套餐的站点购买套餐
# @param request: Request instance for CreatePlanForZone.
# @type request: :class:`Tencentcloud::teo::V20220901::CreatePlanForZoneRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreatePlanForZoneResponse`
def CreatePlanForZone(request)
body = send_request('CreatePlanForZone', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreatePlanForZoneResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建预热任务
# @param request: Request instance for CreatePrefetchTask.
# @type request: :class:`Tencentcloud::teo::V20220901::CreatePrefetchTaskRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreatePrefetchTaskResponse`
def CreatePrefetchTask(request)
body = send_request('CreatePrefetchTask', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreatePrefetchTaskResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 当源站资源更新,但节点缓存 TTL 未过期时,用户仍会访问到旧的资源,此时可以通过该接口实现节点资源更新。触发更新的方法有以下两种:
直接删除:不做任何校验,直接删除节点缓存,用户请求时触发回源拉取;标记过期:将节点资源置为过期,用户请求时触发回源校验,即发送带有 If-None-Match 和 If-Modified-Since 头部的 HTTP 条件请求。若源站响应 200,则节点会回源拉取新的资源并更新缓存;若源站响应 304,则节点不会更新缓存;
# 清除缓存任务详情请查看[清除缓存](https://cloud.tencent.com/document/product/1552/70759)。
# @param request: Request instance for CreatePurgeTask.
# @type request: :class:`Tencentcloud::teo::V20220901::CreatePurgeTaskRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreatePurgeTaskResponse`
def CreatePurgeTask(request)
body = send_request('CreatePurgeTask', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreatePurgeTaskResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 通过本接口创建实时日志投递任务。本接口有如下限制:
# 同一个实体(七层域名或者四层代理实例)在同种数据投递类型(LogType)和数据投递区域(Area)的组合下,只能被添加到一个实时日志投递任务中。建议先通过 [DescribeRealtimeLogDeliveryTasks](https://cloud.tencent.com/document/product/1552/104110) 接口根据实体查询实时日志投递任务列表,检查实体是否已经被添加到另一实时日志投递任务中。
# @param request: Request instance for CreateRealtimeLogDeliveryTask.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateRealtimeLogDeliveryTaskRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateRealtimeLogDeliveryTaskResponse`
def CreateRealtimeLogDeliveryTask(request)
body = send_request('CreateRealtimeLogDeliveryTask', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateRealtimeLogDeliveryTaskResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 规则引擎创建规则。
# @param request: Request instance for CreateRule.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateRuleResponse`
def CreateRule(request)
body = send_request('CreateRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 创建安全 IP 组
# @param request: Request instance for CreateSecurityIPGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateSecurityIPGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateSecurityIPGroupResponse`
def CreateSecurityIPGroup(request)
body = send_request('CreateSecurityIPGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateSecurityIPGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于创建共享 CNAME,该功能白名单内测中。
# @param request: Request instance for CreateSharedCNAME.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateSharedCNAMERequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateSharedCNAMEResponse`
def CreateSharedCNAME(request)
body = send_request('CreateSharedCNAME', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateSharedCNAMEResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# EdgeOne 为您提供 CNAME、NS 和无域名接入三种接入方式,您需要先通过此接口完成站点创建。CNAME 和 NS 接入站点的场景可参考 [从零开始快速接入 EdgeOne](https://cloud.tencent.com/document/product/1552/87601); 无域名接入的场景可参考 [快速启用四层代理服务](https://cloud.tencent.com/document/product/1552/96051)。
# > 建议您在账号下已存在套餐时调用本接口创建站点,请在入参时传入 PlanId ,直接将站点绑定至该套餐;不传入 PlanId 时,创建出来的站点会处于未激活状态,无法正常服务,您需要通过 [BindZoneToPlan](https://cloud.tencent.com/document/product/1552/83042) 完成套餐绑定之后,站点才可正常提供服务 。若您当前没有可绑定的套餐时,请前往控制台购买套餐完成站点创建。
# @param request: Request instance for CreateZone.
# @type request: :class:`Tencentcloud::teo::V20220901::CreateZoneRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::CreateZoneResponse`
def CreateZone(request)
body = send_request('CreateZone', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = CreateZoneResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 批量删除加速域名
# @param request: Request instance for DeleteAccelerationDomains.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteAccelerationDomainsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteAccelerationDomainsResponse`
def DeleteAccelerationDomains(request)
body = send_request('DeleteAccelerationDomains', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteAccelerationDomainsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除别称域名。
# @param request: Request instance for DeleteAliasDomain.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteAliasDomainRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteAliasDomainResponse`
def DeleteAliasDomain(request)
body = send_request('DeleteAliasDomain', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteAliasDomainResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [删除四层代理实例
# ](https://cloud.tencent.com/document/product/1552/103415) 。
# @param request: Request instance for DeleteApplicationProxy.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteApplicationProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteApplicationProxyResponse`
def DeleteApplicationProxy(request)
body = send_request('DeleteApplicationProxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteApplicationProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [删除四层代理转发规则](https://cloud.tencent.com/document/product/1552/103414) 。
# @param request: Request instance for DeleteApplicationProxyRule.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteApplicationProxyRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteApplicationProxyRuleResponse`
def DeleteApplicationProxyRule(request)
body = send_request('DeleteApplicationProxyRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteApplicationProxyRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除自定义错误页面。
# @param request: Request instance for DeleteCustomErrorPage.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteCustomErrorPageRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteCustomErrorPageResponse`
def DeleteCustomErrorPage(request)
body = send_request('DeleteCustomErrorPage', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteCustomErrorPageResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除边缘函数,删除后函数无法恢复,关联的触发规则会一并删除。
# @param request: Request instance for DeleteFunction.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteFunctionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteFunctionResponse`
def DeleteFunction(request)
body = send_request('DeleteFunction', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteFunctionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除边缘函数触发规则。
# @param request: Request instance for DeleteFunctionRules.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteFunctionRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteFunctionRulesResponse`
def DeleteFunctionRules(request)
body = send_request('DeleteFunctionRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteFunctionRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于删除四层代理实例。
# @param request: Request instance for DeleteL4Proxy.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteL4ProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteL4ProxyResponse`
def DeleteL4Proxy(request)
body = send_request('DeleteL4Proxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteL4ProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于删除四层代理转发规则,支持单条或者批量操作。
# @param request: Request instance for DeleteL4ProxyRules.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteL4ProxyRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteL4ProxyRulesResponse`
def DeleteL4ProxyRules(request)
body = send_request('DeleteL4ProxyRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteL4ProxyRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除负载均衡实例,若负载均衡示例被其他服务(例如:四层代理等)引用的时候,示例无法被删除,需要先解除引用关系。负载均衡功能内测中,如您需要使用请 [联系我们](https://cloud.tencent.com/online-service)。
# @param request: Request instance for DeleteLoadBalancer.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteLoadBalancerRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteLoadBalancerResponse`
def DeleteLoadBalancer(request)
body = send_request('DeleteLoadBalancer', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteLoadBalancerResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除源站组,若源站组仍然被服务(例如:四层代理,域名服务,负载均衡,规则引起)引用,将不允许删除。
# @param request: Request instance for DeleteOriginGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteOriginGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteOriginGroupResponse`
def DeleteOriginGroup(request)
body = send_request('DeleteOriginGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteOriginGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 通过本接口删除实时日志投递任务。
# @param request: Request instance for DeleteRealtimeLogDeliveryTask.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteRealtimeLogDeliveryTaskRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteRealtimeLogDeliveryTaskResponse`
def DeleteRealtimeLogDeliveryTask(request)
body = send_request('DeleteRealtimeLogDeliveryTask', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteRealtimeLogDeliveryTaskResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 批量删除规则引擎规则。
# @param request: Request instance for DeleteRules.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteRulesResponse`
def DeleteRules(request)
body = send_request('DeleteRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除指定 IP 组,如果有规则引用了 IP 组情况,则不允许删除。
# @param request: Request instance for DeleteSecurityIPGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteSecurityIPGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteSecurityIPGroupResponse`
def DeleteSecurityIPGroup(request)
body = send_request('DeleteSecurityIPGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteSecurityIPGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于删除共享 CNAME,该功能白名单内测中。
# @param request: Request instance for DeleteSharedCNAME.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteSharedCNAMERequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteSharedCNAMEResponse`
def DeleteSharedCNAME(request)
body = send_request('DeleteSharedCNAME', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteSharedCNAMEResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 删除站点。
# @param request: Request instance for DeleteZone.
# @type request: :class:`Tencentcloud::teo::V20220901::DeleteZoneRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeleteZoneResponse`
def DeleteZone(request)
body = send_request('DeleteZone', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeleteZoneResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在版本管理模式下,用于版本发布,可通过 EnvId 将版本发布至测试环境或生产环境。版本管理功能内测中,当前仅白名单开放。
# @param request: Request instance for DeployConfigGroupVersion.
# @type request: :class:`Tencentcloud::teo::V20220901::DeployConfigGroupVersionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DeployConfigGroupVersionResponse`
def DeployConfigGroupVersion(request)
body = send_request('DeployConfigGroupVersion', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DeployConfigGroupVersionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 您可以通过本接口查看站点下的域名信息,包括加速域名、源站以及域名状态等信息。您可以查看站点下全部域名的信息,也可以指定过滤条件查询对应的域名信息。
# @param request: Request instance for DescribeAccelerationDomains.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeAccelerationDomainsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeAccelerationDomainsResponse`
def DescribeAccelerationDomains(request)
body = send_request('DescribeAccelerationDomains', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeAccelerationDomainsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询别称域名信息列表。
# @param request: Request instance for DescribeAliasDomains.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeAliasDomainsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeAliasDomainsResponse`
def DescribeAliasDomains(request)
body = send_request('DescribeAliasDomains', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeAliasDomainsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,新版接口中将四层代理实例列表的查询和四层转发规则的查询拆分成两个接口,详情请参考 [查询四层代理实例列表](https://cloud.tencent.com/document/product/1552/103413) 和 [查询四层代理转发规则列表](https://cloud.tencent.com/document/product/1552/103412)。
# @param request: Request instance for DescribeApplicationProxies.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeApplicationProxiesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeApplicationProxiesResponse`
def DescribeApplicationProxies(request)
body = send_request('DescribeApplicationProxies', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeApplicationProxiesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询当前账户可用套餐信息列表
# @param request: Request instance for DescribeAvailablePlans.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeAvailablePlansRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeAvailablePlansResponse`
def DescribeAvailablePlans(request)
body = send_request('DescribeAvailablePlans', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeAvailablePlansResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 通过本接口查询计费数据。
# @param request: Request instance for DescribeBillingData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeBillingDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeBillingDataResponse`
def DescribeBillingData(request)
body = send_request('DescribeBillingData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeBillingDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在版本管理模式下,用于获取版本的详细信息,包括版本 ID、描述、状态、创建时间、所属配置组信息以及版本配置文件的内容。版本管理功能内测中,当前仅白名单开放。
# @param request: Request instance for DescribeConfigGroupVersionDetail.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeConfigGroupVersionDetailRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeConfigGroupVersionDetailResponse`
def DescribeConfigGroupVersionDetail(request)
body = send_request('DescribeConfigGroupVersionDetail', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeConfigGroupVersionDetailResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在版本管理模式下,用于查询指定配置组的版本列表。版本管理功能内测中,当前仅白名单开放。
# @param request: Request instance for DescribeConfigGroupVersions.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeConfigGroupVersionsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeConfigGroupVersionsResponse`
def DescribeConfigGroupVersions(request)
body = send_request('DescribeConfigGroupVersions', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeConfigGroupVersionsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询内容管理接口配额
# @param request: Request instance for DescribeContentQuota.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeContentQuotaRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeContentQuotaResponse`
def DescribeContentQuota(request)
body = send_request('DescribeContentQuota', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeContentQuotaResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询自定义错误页列表。
# @param request: Request instance for DescribeCustomErrorPages.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeCustomErrorPagesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeCustomErrorPagesResponse`
def DescribeCustomErrorPages(request)
body = send_request('DescribeCustomErrorPages', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeCustomErrorPagesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DescribeDDoSAttackData)用于查询DDoS攻击时序数据。
# @param request: Request instance for DescribeDDoSAttackData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeDDoSAttackDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeDDoSAttackDataResponse`
def DescribeDDoSAttackData(request)
body = send_request('DescribeDDoSAttackData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeDDoSAttackDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DescribeDDoSAttackEvent)用于查询DDoS攻击事件列表。
# @param request: Request instance for DescribeDDoSAttackEvent.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeDDoSAttackEventRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeDDoSAttackEventResponse`
def DescribeDDoSAttackEvent(request)
body = send_request('DescribeDDoSAttackEvent', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeDDoSAttackEventResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DescribeDDoSAttackTopData)用于查询DDoS攻击Top数据。
# @param request: Request instance for DescribeDDoSAttackTopData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeDDoSAttackTopDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeDDoSAttackTopDataResponse`
def DescribeDDoSAttackTopData(request)
body = send_request('DescribeDDoSAttackTopData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeDDoSAttackTopDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询默认证书列表
# @param request: Request instance for DescribeDefaultCertificates.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeDefaultCertificatesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeDefaultCertificatesResponse`
def DescribeDefaultCertificates(request)
body = send_request('DescribeDefaultCertificates', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeDefaultCertificatesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在版本管理模式下,用于查询生产/测试环境的版本发布历史。版本管理功能内测中,当前仅白名单开放。
# @param request: Request instance for DescribeDeployHistory.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeDeployHistoryRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeDeployHistoryResponse`
def DescribeDeployHistory(request)
body = send_request('DescribeDeployHistory', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeDeployHistoryResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在版本管理模式下,用于查询环境信息,可获取环境 ID、类型、当前生效版本等。版本管理功能内测中,当前仅白名单开放。
# @param request: Request instance for DescribeEnvironments.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeEnvironmentsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeEnvironmentsResponse`
def DescribeEnvironments(request)
body = send_request('DescribeEnvironments', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeEnvironmentsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询边缘函数触发规则列表,支持按照规则 ID、函数 ID、规则描述等条件进行过滤。
# @param request: Request instance for DescribeFunctionRules.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeFunctionRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeFunctionRulesResponse`
def DescribeFunctionRules(request)
body = send_request('DescribeFunctionRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeFunctionRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询边缘函数运行环境,包括环境变量。
# @param request: Request instance for DescribeFunctionRuntimeEnvironment.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeFunctionRuntimeEnvironmentRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeFunctionRuntimeEnvironmentResponse`
def DescribeFunctionRuntimeEnvironment(request)
body = send_request('DescribeFunctionRuntimeEnvironment', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeFunctionRuntimeEnvironmentResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询边缘函数列表,支持函数 ID、函数名称、描述等条件的过滤。
# @param request: Request instance for DescribeFunctions.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeFunctionsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeFunctionsResponse`
def DescribeFunctions(request)
body = send_request('DescribeFunctions', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeFunctionsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于查询域名配置信息
# @param request: Request instance for DescribeHostsSetting.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeHostsSettingRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeHostsSettingResponse`
def DescribeHostsSetting(request)
body = send_request('DescribeHostsSetting', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeHostsSettingResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 该接口可用于查询 IP 是否为 EdgeOne IP。
# @param request: Request instance for DescribeIPRegion.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeIPRegionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeIPRegionResponse`
def DescribeIPRegion(request)
body = send_request('DescribeIPRegion', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeIPRegionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询站点的验证信息。
# @param request: Request instance for DescribeIdentifications.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeIdentificationsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeIdentificationsResponse`
def DescribeIdentifications(request)
body = send_request('DescribeIdentifications', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeIdentificationsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于查询四层代理实例列表。
# @param request: Request instance for DescribeL4Proxy.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeL4ProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeL4ProxyResponse`
def DescribeL4Proxy(request)
body = send_request('DescribeL4Proxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeL4ProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询四层代理实例下的转发规则列表。
# @param request: Request instance for DescribeL4ProxyRules.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeL4ProxyRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeL4ProxyRulesResponse`
def DescribeL4ProxyRules(request)
body = send_request('DescribeL4ProxyRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeL4ProxyRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询负载均衡实例列表。负载均衡功能内测中,如您需要使用请 [联系我们](https://cloud.tencent.com/online-service)。
# @param request: Request instance for DescribeLoadBalancerList.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeLoadBalancerListRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeLoadBalancerListResponse`
def DescribeLoadBalancerList(request)
body = send_request('DescribeLoadBalancerList', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeLoadBalancerListResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 获取源站组列表
# @param request: Request instance for DescribeOriginGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeOriginGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeOriginGroupResponse`
def DescribeOriginGroup(request)
body = send_request('DescribeOriginGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeOriginGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询负载均衡实例下源站组健康状态。负载均衡功能内测中,如您需要使用请 [联系我们](https://cloud.tencent.com/online-service)。
# @param request: Request instance for DescribeOriginGroupHealthStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeOriginGroupHealthStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeOriginGroupHealthStatusResponse`
def DescribeOriginGroupHealthStatus(request)
body = send_request('DescribeOriginGroupHealthStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeOriginGroupHealthStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询源站防护信息
# @param request: Request instance for DescribeOriginProtection.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeOriginProtectionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeOriginProtectionResponse`
def DescribeOriginProtection(request)
body = send_request('DescribeOriginProtection', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeOriginProtectionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DescribeOverviewL7Data)用于查询七层监控类时序流量数据。此接口待废弃,请使用 DescribeTimingL7AnalysisData 接口。
# @param request: Request instance for DescribeOverviewL7Data.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeOverviewL7DataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeOverviewL7DataResponse`
def DescribeOverviewL7Data(request)
body = send_request('DescribeOverviewL7Data', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeOverviewL7DataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# DescribePrefetchTasks 用于查询预热任务提交历史记录及执行进度,通过 CreatePrefetchTasks 接口提交的任务可通过此接口进行查询。
# @param request: Request instance for DescribePrefetchTasks.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribePrefetchTasksRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribePrefetchTasksResponse`
def DescribePrefetchTasks(request)
body = send_request('DescribePrefetchTasks', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribePrefetchTasksResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# DescribePurgeTasks 用于查询提交的 URL 刷新、目录刷新记录及执行进度,通过 CreatePurgeTasks 接口提交的任务均可通过此接口进行查询。
# @param request: Request instance for DescribePurgeTasks.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribePurgeTasksRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribePurgeTasksResponse`
def DescribePurgeTasks(request)
body = send_request('DescribePurgeTasks', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribePurgeTasksResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 通过本接口查询实时日志投递任务列表。
# @param request: Request instance for DescribeRealtimeLogDeliveryTasks.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeRealtimeLogDeliveryTasksRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeRealtimeLogDeliveryTasksResponse`
def DescribeRealtimeLogDeliveryTasks(request)
body = send_request('DescribeRealtimeLogDeliveryTasks', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeRealtimeLogDeliveryTasksResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询规则引擎规则。
# @param request: Request instance for DescribeRules.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeRulesResponse`
def DescribeRules(request)
body = send_request('DescribeRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 返回规则引擎可应用匹配请求的设置列表及其详细建议配置信息
# @param request: Request instance for DescribeRulesSetting.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeRulesSettingRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeRulesSettingResponse`
def DescribeRulesSetting(request)
body = send_request('DescribeRulesSetting', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeRulesSettingResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询安全 IP 组的配置信息,包括安全 IP 组的 ID、名称和内容。
# @param request: Request instance for DescribeSecurityIPGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeSecurityIPGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeSecurityIPGroupResponse`
def DescribeSecurityIPGroup(request)
body = send_request('DescribeSecurityIPGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeSecurityIPGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 接口已废弃,将于 2024 年 6 月 30 日停止服务。请使用 [查询安全 IP 组
# ](https://cloud.tencent.com/document/product/1552/105866) 接口。
# 查询 IP 组的配置信息,包括 IP 组名称、 IP 组内容、 IP 组归属站点。
# @param request: Request instance for DescribeSecurityIPGroupInfo.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeSecurityIPGroupInfoRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeSecurityIPGroupInfoResponse`
def DescribeSecurityIPGroupInfo(request)
body = send_request('DescribeSecurityIPGroupInfo', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeSecurityIPGroupInfoResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 查询指定策略模板的绑定关系列表。
# @param request: Request instance for DescribeSecurityTemplateBindings.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeSecurityTemplateBindingsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeSecurityTemplateBindingsResponse`
def DescribeSecurityTemplateBindings(request)
body = send_request('DescribeSecurityTemplateBindings', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeSecurityTemplateBindingsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DescribeTimingL4Data)用于查询四层时序流量数据列表。
# @param request: Request instance for DescribeTimingL4Data.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeTimingL4DataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeTimingL4DataResponse`
def DescribeTimingL4Data(request)
body = send_request('DescribeTimingL4Data', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeTimingL4DataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口查询七层域名业务的时序数据。请注意本接口查询数据有 10 分钟左右延迟,建议拉取当前时间 10 分钟以前的数据。
# @param request: Request instance for DescribeTimingL7AnalysisData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeTimingL7AnalysisDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeTimingL7AnalysisDataResponse`
def DescribeTimingL7AnalysisData(request)
body = send_request('DescribeTimingL7AnalysisData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeTimingL7AnalysisDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口用于查询七层缓存分析时序类流量数据。此接口待废弃,请使用 DescribeTimingL7AnalysisData 接口。
# @param request: Request instance for DescribeTimingL7CacheData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeTimingL7CacheDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeTimingL7CacheDataResponse`
def DescribeTimingL7CacheData(request)
body = send_request('DescribeTimingL7CacheData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeTimingL7CacheDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口用于查询七层域名业务按照指定维度的 topN 数据。请注意本接口查询数据有 10 分钟左右延迟,建议拉取当前时间 10 分钟以前的数据。
# @param request: Request instance for DescribeTopL7AnalysisData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeTopL7AnalysisDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeTopL7AnalysisDataResponse`
def DescribeTopL7AnalysisData(request)
body = send_request('DescribeTopL7AnalysisData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeTopL7AnalysisDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口用于查询七层缓存分析 topN 数据。此接口待废弃,请使用 DescribeTopL7AnalysisData 接口。
# @param request: Request instance for DescribeTopL7CacheData.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeTopL7CacheDataRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeTopL7CacheDataResponse`
def DescribeTopL7CacheData(request)
body = send_request('DescribeTopL7CacheData', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeTopL7CacheDataResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于查询站点的所有配置信息。
# @param request: Request instance for DescribeZoneSetting.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeZoneSettingRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeZoneSettingResponse`
def DescribeZoneSetting(request)
body = send_request('DescribeZoneSetting', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeZoneSettingResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 该接口用于查询您有权限的站点信息。可根据不同查询条件筛选站点。
# @param request: Request instance for DescribeZones.
# @type request: :class:`Tencentcloud::teo::V20220901::DescribeZonesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DescribeZonesResponse`
def DescribeZones(request)
body = send_request('DescribeZones', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DescribeZonesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 当您需要停止 Edgeone 套餐的计费,可以通过该接口销毁计费套餐。
# > 销毁计费套餐需要满足以下条件:
# 1.套餐已过期(企业版套餐除外);
# 2.套餐下所有站点均已关闭或删除。
# > 站点状态可以通过 [查询站点列表](https://cloud.tencent.com/document/product/1552/80713) 接口进行查询
# 停用站点可以通过 [切换站点状态](https://cloud.tencent.com/document/product/1552/80707) 接口将站点切换至关闭状态
# 删除站点可以通过 [删除站点](https://cloud.tencent.com/document/product/1552/80717) 接口将站点删除
# @param request: Request instance for DestroyPlan.
# @type request: :class:`Tencentcloud::teo::V20220901::DestroyPlanRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DestroyPlanResponse`
def DestroyPlan(request)
body = send_request('DestroyPlan', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DestroyPlanResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DownloadL4Logs)用于下载四层离线日志。
# @param request: Request instance for DownloadL4Logs.
# @type request: :class:`Tencentcloud::teo::V20220901::DownloadL4LogsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DownloadL4LogsResponse`
def DownloadL4Logs(request)
body = send_request('DownloadL4Logs', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DownloadL4LogsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口(DownloadL7Logs)下载七层离线日志。
# @param request: Request instance for DownloadL7Logs.
# @type request: :class:`Tencentcloud::teo::V20220901::DownloadL7LogsRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::DownloadL7LogsResponse`
def DownloadL7Logs(request)
body = send_request('DownloadL7Logs', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = DownloadL7LogsResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 操作边缘函数运行环境,支持环境变量的相关设置。
# 设置环境变量后,可在函数代码中使用,具体参考 [边缘函数引入环境变量](https://cloud.tencent.com/document/product/1552/109151#0151fd9a-8b0e-407b-ae37-54553a60ded6)。
# @param request: Request instance for HandleFunctionRuntimeEnvironment.
# @type request: :class:`Tencentcloud::teo::V20220901::HandleFunctionRuntimeEnvironmentRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::HandleFunctionRuntimeEnvironmentResponse`
def HandleFunctionRuntimeEnvironment(request)
body = send_request('HandleFunctionRuntimeEnvironment', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = HandleFunctionRuntimeEnvironmentResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于验证站点所有权。
# @param request: Request instance for IdentifyZone.
# @type request: :class:`Tencentcloud::teo::V20220901::IdentifyZoneRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::IdentifyZoneResponse`
def IdentifyZone(request)
body = send_request('IdentifyZone', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = IdentifyZoneResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 当您的套餐绑定的站点数,或配置的 Web 防护 - 自定义规则 - 精准匹配策略的规则数,或 Web 防护 - 速率限制 - 精准速率限制模块的规则数达到套餐允许的配额上限,可以通过该接口增购对应配额。
# > 该接口该仅支持企业版套餐。
# @param request: Request instance for IncreasePlanQuota.
# @type request: :class:`Tencentcloud::teo::V20220901::IncreasePlanQuotaRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::IncreasePlanQuotaResponse`
def IncreasePlanQuota(request)
body = send_request('IncreasePlanQuota', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = IncreasePlanQuotaResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改加速域名信息
# @param request: Request instance for ModifyAccelerationDomain.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyAccelerationDomainRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyAccelerationDomainResponse`
def ModifyAccelerationDomain(request)
body = send_request('ModifyAccelerationDomain', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyAccelerationDomainResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 批量修改加速域名状态
# @param request: Request instance for ModifyAccelerationDomainStatuses.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyAccelerationDomainStatusesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyAccelerationDomainStatusesResponse`
def ModifyAccelerationDomainStatuses(request)
body = send_request('ModifyAccelerationDomainStatuses', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyAccelerationDomainStatusesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改别称域名。
# @param request: Request instance for ModifyAliasDomain.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyAliasDomainRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyAliasDomainResponse`
def ModifyAliasDomain(request)
body = send_request('ModifyAliasDomain', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyAliasDomainResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改别称域名状态。
# @param request: Request instance for ModifyAliasDomainStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyAliasDomainStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyAliasDomainStatusResponse`
def ModifyAliasDomainStatus(request)
body = send_request('ModifyAliasDomainStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyAliasDomainStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [修改四层代理实例
# ](https://cloud.tencent.com/document/product/1552/103411) 。
# @param request: Request instance for ModifyApplicationProxy.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyResponse`
def ModifyApplicationProxy(request)
body = send_request('ModifyApplicationProxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyApplicationProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [修改四层代理转发规则
# ](https://cloud.tencent.com/document/product/1552/103410) 。
# @param request: Request instance for ModifyApplicationProxyRule.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyRuleResponse`
def ModifyApplicationProxyRule(request)
body = send_request('ModifyApplicationProxyRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyApplicationProxyRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [修改四层代理转发规则状态
# ](https://cloud.tencent.com/document/product/1552/103409) 。
# @param request: Request instance for ModifyApplicationProxyRuleStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyRuleStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyRuleStatusResponse`
def ModifyApplicationProxyRuleStatus(request)
body = send_request('ModifyApplicationProxyRuleStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyApplicationProxyRuleStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 本接口为旧版,如需调用请尽快迁移至新版,详情请参考 [修改四层代理实例状态](https://cloud.tencent.com/document/product/1552/103408) 。
# @param request: Request instance for ModifyApplicationProxyStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyApplicationProxyStatusResponse`
def ModifyApplicationProxyStatus(request)
body = send_request('ModifyApplicationProxyStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyApplicationProxyStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改自定义错误页面。
# @param request: Request instance for ModifyCustomErrorPage.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyCustomErrorPageRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyCustomErrorPageResponse`
def ModifyCustomErrorPage(request)
body = send_request('ModifyCustomErrorPage', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyCustomErrorPageResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改边缘函数,支持修改函数的内容及描述信息,修改且重新部署后,函数立刻生效。
# @param request: Request instance for ModifyFunction.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyFunctionRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyFunctionResponse`
def ModifyFunction(request)
body = send_request('ModifyFunction', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyFunctionResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改边缘函数触发规则,支持修改规则条件、执行函数以及描述信息。
# @param request: Request instance for ModifyFunctionRule.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyFunctionRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyFunctionRuleResponse`
def ModifyFunctionRule(request)
body = send_request('ModifyFunctionRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyFunctionRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改边缘函数触发规则的优先级。
# @param request: Request instance for ModifyFunctionRulePriority.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyFunctionRulePriorityRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyFunctionRulePriorityResponse`
def ModifyFunctionRulePriority(request)
body = send_request('ModifyFunctionRulePriority', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyFunctionRulePriorityResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 完成域名创建之后,您可以为域名配置自有证书,也可以使用 EdgeOne 为您提供的 [免费证书](https://cloud.tencent.com/document/product/1552/90437)。
# 如果您需要配置自有证书,请先将证书上传至 [SSL证书控制台](https://console.cloud.tencent.com/certoverview),然后在本接口中传入对应的证书 ID。详情参考 [部署自有证书至 EdgeOne 域名
# ](https://cloud.tencent.com/document/product/1552/88874)。
# @param request: Request instance for ModifyHostsCertificate.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyHostsCertificateRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyHostsCertificateResponse`
def ModifyHostsCertificate(request)
body = send_request('ModifyHostsCertificate', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyHostsCertificateResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于修改四层代理实例的配置。
# @param request: Request instance for ModifyL4Proxy.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyResponse`
def ModifyL4Proxy(request)
body = send_request('ModifyL4Proxy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyL4ProxyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于修改四层代理转发规则,支持单条或者批量修改。
# @param request: Request instance for ModifyL4ProxyRules.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyRulesRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyRulesResponse`
def ModifyL4ProxyRules(request)
body = send_request('ModifyL4ProxyRules', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyL4ProxyRulesResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于启用/停用四层代理转发规则状态,支持单条或者批量操作。
# @param request: Request instance for ModifyL4ProxyRulesStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyRulesStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyRulesStatusResponse`
def ModifyL4ProxyRulesStatus(request)
body = send_request('ModifyL4ProxyRulesStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyL4ProxyRulesStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于启用/停用四层代理实例。
# @param request: Request instance for ModifyL4ProxyStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyL4ProxyStatusResponse`
def ModifyL4ProxyStatus(request)
body = send_request('ModifyL4ProxyStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyL4ProxyStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改负载均衡实例配置。负载均衡功能内测中,如您需要使用请 [联系我们](https://cloud.tencent.com/online-service)。
# @param request: Request instance for ModifyLoadBalancer.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyLoadBalancerRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyLoadBalancerResponse`
def ModifyLoadBalancer(request)
body = send_request('ModifyLoadBalancer', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyLoadBalancerResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改源站组配置,新提交的源站记录将会覆盖原有源站组中的源站记录。
# @param request: Request instance for ModifyOriginGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyOriginGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyOriginGroupResponse`
def ModifyOriginGroup(request)
body = send_request('ModifyOriginGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyOriginGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改套餐配置。目前仅支持修改预付费套餐的自动续费开关。
# @param request: Request instance for ModifyPlan.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyPlanRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyPlanResponse`
def ModifyPlan(request)
body = send_request('ModifyPlan', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyPlanResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 通过本接口修改实时日志投递任务配置。本接口有如下限制:不支持修改实时日志投递任务目的地类型(TaskType);不支持修改数据投递类型(LogType)不支持修改数据投递区域(Area)当原实时日志投递任务的目的地为腾讯云 CLS 时,不支持修改目的地详细配置,如日志集、日志主题。
# @param request: Request instance for ModifyRealtimeLogDeliveryTask.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyRealtimeLogDeliveryTaskRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyRealtimeLogDeliveryTaskResponse`
def ModifyRealtimeLogDeliveryTask(request)
body = send_request('ModifyRealtimeLogDeliveryTask', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyRealtimeLogDeliveryTaskResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改规则引擎规则。
# @param request: Request instance for ModifyRule.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyRuleRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyRuleResponse`
def ModifyRule(request)
body = send_request('ModifyRule', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyRuleResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改安全 IP 组。
# @param request: Request instance for ModifySecurityIPGroup.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifySecurityIPGroupRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifySecurityIPGroupResponse`
def ModifySecurityIPGroup(request)
body = send_request('ModifySecurityIPGroup', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifySecurityIPGroupResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改Web&Bot安全配置。
# @param request: Request instance for ModifySecurityPolicy.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifySecurityPolicyRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifySecurityPolicyResponse`
def ModifySecurityPolicy(request)
body = send_request('ModifySecurityPolicy', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifySecurityPolicyResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 修改站点信息。
# @param request: Request instance for ModifyZone.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyZoneRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyZoneResponse`
def ModifyZone(request)
body = send_request('ModifyZone', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyZoneResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于修改站点配置
# @param request: Request instance for ModifyZoneSetting.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyZoneSettingRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyZoneSettingResponse`
def ModifyZoneSetting(request)
body = send_request('ModifyZoneSetting', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyZoneSettingResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 用于开启,关闭站点。
# @param request: Request instance for ModifyZoneStatus.
# @type request: :class:`Tencentcloud::teo::V20220901::ModifyZoneStatusRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::ModifyZoneStatusResponse`
def ModifyZoneStatus(request)
body = send_request('ModifyZoneStatus', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = ModifyZoneStatusResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 当您的套餐需要延长有效期,可以通过该接口进行续费。套餐续费仅支持个人版,基础版,标准版套餐。
# > 费用详情可参考 [套餐费用](https://cloud.tencent.com/document/product/1552/94158)
# @param request: Request instance for RenewPlan.
# @type request: :class:`Tencentcloud::teo::V20220901::RenewPlanRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::RenewPlanResponse`
def RenewPlan(request)
body = send_request('RenewPlan', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = RenewPlanResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 当您需要使用高等级套餐才拥有的功能,可以通过本接口升级套餐,仅支持个人版,基础版套餐进行升级。
# > 不同类型 Edgeone 计费套餐区别参考 [Edgeone计费套餐选型对比](https://cloud.tencent.com/document/product/1552/94165)
# 计费套餐升级规则以及资费详情参考 [Edgeone计费套餐升配说明](https://cloud.tencent.com/document/product/1552/95291)
# 如果需要将套餐升级至企业版,请 [联系我们](https://cloud.tencent.com/online-service)
# @param request: Request instance for UpgradePlan.
# @type request: :class:`Tencentcloud::teo::V20220901::UpgradePlanRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::UpgradePlanResponse`
def UpgradePlan(request)
body = send_request('UpgradePlan', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = UpgradePlanResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
# 在 CNAME 接入模式下,您需要对站点或者域名的归属权进行验证,可以通过本接口触发验证。若站点通过归属权验证后,后续添加域名无需再验证。详情参考 [站点/域名归属权验证](https://cloud.tencent.com/document/product/1552/70789)。
# 在 NS 接入模式下,您也可以通过本接口来查询 NS 服务器是否切换成功,详情参考 [修改 DNS 服务器](https://cloud.tencent.com/document/product/1552/90452)。
# @param request: Request instance for VerifyOwnership.
# @type request: :class:`Tencentcloud::teo::V20220901::VerifyOwnershipRequest`
# @rtype: :class:`Tencentcloud::teo::V20220901::VerifyOwnershipResponse`
def VerifyOwnership(request)
body = send_request('VerifyOwnership', request.serialize)
response = JSON.parse(body)
if response['Response'].key?('Error') == false
model = VerifyOwnershipResponse.new
model.deserialize(response['Response'])
model
else
code = response['Response']['Error']['Code']
message = response['Response']['Error']['Message']
reqid = response['Response']['RequestId']
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
end
rescue TencentCloud::Common::TencentCloudSDKException => e
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
end
end
end
end