lib/v20180724/client.rb in tencentcloud-sdk-monitor-1.0.233 vs lib/v20180724/client.rb in tencentcloud-sdk-monitor-1.0.234
- old
+ new
@@ -51,9 +51,33 @@
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
+ # 策略绑定标签
+
+ # @param request: Request instance for BindingPolicyTag.
+ # @type request: :class:`Tencentcloud::monitor::V20180724::BindingPolicyTagRequest`
+ # @rtype: :class:`Tencentcloud::monitor::V20180724::BindingPolicyTagResponse`
+ def BindingPolicyTag(request)
+ body = send_request('BindingPolicyTag', request.serialize)
+ response = JSON.parse(body)
+ if response['Response'].key?('Error') == false
+ model = BindingPolicyTagResponse.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 CreateAlarmNotice.
# @type request: :class:`Tencentcloud::monitor::V20180724::CreateAlarmNoticeRequest`
# @rtype: :class:`Tencentcloud::monitor::V20180724::CreateAlarmNoticeResponse`
\ No newline at end of file