lib/v20190529/client.rb in tencentcloud-sdk-tiia-1.0.332 vs lib/v20190529/client.rb in tencentcloud-sdk-tiia-1.0.333
- old
+ new
@@ -263,9 +263,36 @@
raise e
rescue StandardError => e
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
end
+ # 文件封识别可检测图片中是否包含符合文件封(即文件、单据、资料等的袋状包装)特征的物品,覆盖顺丰快递文件封、文件袋、档案袋等多种文件封类型,可应用于物流行业对文件快递的包装审核等场景。
+
+ # >?
+ # - 公共参数中的签名方式必须指定为V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。
+
+ # @param request: Request instance for DetectEnvelope.
+ # @type request: :class:`Tencentcloud::tiia::V20190529::DetectEnvelopeRequest`
+ # @rtype: :class:`Tencentcloud::tiia::V20190529::DetectEnvelopeResponse`
+ def DetectEnvelope(request)
+ body = send_request('DetectEnvelope', request.serialize)
+ response = JSON.parse(body)
+ if response['Response'].key?('Error') == false
+ model = DetectEnvelopeResponse.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/865/75196)。**
# - **与本接口相比,[通用图像标签](https://cloud.tencent.com/document/product/865/75196)新版接口提供更高精度的图像标签识别服务,覆盖更广泛的物体与场景类型,效果和通用性更优。**
# 图像标签利用深度学习技术,可以对图片进行智能分类、物体识别等。
\ No newline at end of file