class TencentCloud::Ticm::V20181127::Client

def DescribeVideoTask(request)

Parameters:
  • request: () -- Request instance for DescribeVideoTask.
def DescribeVideoTask(request)
  body = send_request('DescribeVideoTask', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = DescribeVideoTaskResponse.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

def ImageModeration(request)

Parameters:
  • request: () -- Request instance for ImageModeration.
def ImageModeration(request)
  body = send_request('ImageModeration', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = ImageModerationResponse.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

def VideoModeration(request)

Parameters:
  • request: () -- Request instance for VideoModeration.
def VideoModeration(request)
  body = send_request('VideoModeration', request.serialize)
  response = JSON.parse(body)
  if response['Response'].key?('Error') == false
    model = VideoModerationResponse.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

def initialize(credential, region, profile = nil)

def initialize(credential, region, profile = nil)
    api_version = '2018-11-27'
    api_endpoint = 'ticm.tencentcloudapi.com'
    sdk_version = 'TICM_' + File.read(File.expand_path('../VERSION', __dir__)).strip
    super(credential, region, api_version, api_endpoint, sdk_version, profile)
end