tencentcloud-sdk-faceid 3.0.788 → 3.0.790
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/VERSION +1 -1
- data/lib/v20180301/client.rb +48 -0
- data/lib/v20180301/models.rb +109 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9b04f61d0be80afbbf639690012f32701d416ee4
|
4
|
+
data.tar.gz: 3b164b73ca769b0da3f76b7c812e55b64bc87017
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ddbcf60015bb0830189ea040ecead3d93510409afdd034bb712d723cf4d3ba1603229173dd784b1132d6381e472756b2d68deb3fa602515140b4872712845860
|
7
|
+
data.tar.gz: 2d4e8d3285489521431333a6a21ddc5448d685ee74e037aa37905bc76b72b8447952e0e3904c2e56ce659a71fd0ba8e5979ca0bd0260208a0c5a5ac2c150bc89
|
data/lib/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.0.
|
1
|
+
3.0.790
|
data/lib/v20180301/client.rb
CHANGED
@@ -437,6 +437,30 @@ module TencentCloud
|
|
437
437
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
438
438
|
end
|
439
439
|
|
440
|
+
# 完成验证后,用FaceIdToken调用本接口获取设备风险相关信息,FaceIdToken生成后三天内(3\*24\*3,600秒)可多次拉取。
|
441
|
+
|
442
|
+
# @param request: Request instance for GetFaceIdRiskInfo.
|
443
|
+
# @type request: :class:`Tencentcloud::faceid::V20180301::GetFaceIdRiskInfoRequest`
|
444
|
+
# @rtype: :class:`Tencentcloud::faceid::V20180301::GetFaceIdRiskInfoResponse`
|
445
|
+
def GetFaceIdRiskInfo(request)
|
446
|
+
body = send_request('GetFaceIdRiskInfo', request.serialize)
|
447
|
+
response = JSON.parse(body)
|
448
|
+
if response['Response'].key?('Error') == false
|
449
|
+
model = GetFaceIdRiskInfoResponse.new
|
450
|
+
model.deserialize(response['Response'])
|
451
|
+
model
|
452
|
+
else
|
453
|
+
code = response['Response']['Error']['Code']
|
454
|
+
message = response['Response']['Error']['Message']
|
455
|
+
reqid = response['Response']['RequestId']
|
456
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
457
|
+
end
|
458
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
459
|
+
raise e
|
460
|
+
rescue StandardError => e
|
461
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
462
|
+
end
|
463
|
+
|
440
464
|
# 每次调用人脸核身SDK服务前,需先调用本接口获取SDKToken,用来串联核身流程,在验证完成后,用于获取验证结果信息,该token仅能核身一次。
|
441
465
|
|
442
466
|
# @param request: Request instance for GetFaceIdToken.
|
@@ -461,6 +485,30 @@ module TencentCloud
|
|
461
485
|
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
462
486
|
end
|
463
487
|
|
488
|
+
# 每次调用人脸核身SDK服务前,需先调用本接口获取SDKToken,用来串联核身流程,在验证完成后,用于获取风险结果信息,该Token仅能核身一次。
|
489
|
+
|
490
|
+
# @param request: Request instance for GetFaceidRiskInfoToken.
|
491
|
+
# @type request: :class:`Tencentcloud::faceid::V20180301::GetFaceidRiskInfoTokenRequest`
|
492
|
+
# @rtype: :class:`Tencentcloud::faceid::V20180301::GetFaceidRiskInfoTokenResponse`
|
493
|
+
def GetFaceidRiskInfoToken(request)
|
494
|
+
body = send_request('GetFaceidRiskInfoToken', request.serialize)
|
495
|
+
response = JSON.parse(body)
|
496
|
+
if response['Response'].key?('Error') == false
|
497
|
+
model = GetFaceidRiskInfoTokenResponse.new
|
498
|
+
model.deserialize(response['Response'])
|
499
|
+
model
|
500
|
+
else
|
501
|
+
code = response['Response']['Error']['Code']
|
502
|
+
message = response['Response']['Error']['Message']
|
503
|
+
reqid = response['Response']['RequestId']
|
504
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
|
505
|
+
end
|
506
|
+
rescue TencentCloud::Common::TencentCloudSDKException => e
|
507
|
+
raise e
|
508
|
+
rescue StandardError => e
|
509
|
+
raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
|
510
|
+
end
|
511
|
+
|
464
512
|
# 使用数字活体检测模式前,需调用本接口获取数字验证码。
|
465
513
|
|
466
514
|
# @param request: Request instance for GetLiveCode.
|
data/lib/v20180301/models.rb
CHANGED
@@ -1798,10 +1798,12 @@ module TencentCloud
|
|
1798
1798
|
# @type IntentionRecognition: Boolean
|
1799
1799
|
# @param IsSupportHMTResidentPermitOCR: 是否支持港澳台居住证识别
|
1800
1800
|
# @type IsSupportHMTResidentPermitOCR: Boolean
|
1801
|
+
# @param MouthOpenRecognition: 用户语音回答过程中是否开启张嘴识别检测,默认不开启,仅在意愿核身问答模式中使用。
|
1802
|
+
# @type MouthOpenRecognition: Boolean
|
1801
1803
|
|
1802
|
-
attr_accessor :InputType, :UseIntentionVerify, :IntentionMode, :IntentionVerifyText, :IntentionQuestions, :IntentionActions, :IntentionRecognition, :IsSupportHMTResidentPermitOCR
|
1804
|
+
attr_accessor :InputType, :UseIntentionVerify, :IntentionMode, :IntentionVerifyText, :IntentionQuestions, :IntentionActions, :IntentionRecognition, :IsSupportHMTResidentPermitOCR, :MouthOpenRecognition
|
1803
1805
|
|
1804
|
-
def initialize(inputtype=nil, useintentionverify=nil, intentionmode=nil, intentionverifytext=nil, intentionquestions=nil, intentionactions=nil, intentionrecognition=nil, issupporthmtresidentpermitocr=nil)
|
1806
|
+
def initialize(inputtype=nil, useintentionverify=nil, intentionmode=nil, intentionverifytext=nil, intentionquestions=nil, intentionactions=nil, intentionrecognition=nil, issupporthmtresidentpermitocr=nil, mouthopenrecognition=nil)
|
1805
1807
|
@InputType = inputtype
|
1806
1808
|
@UseIntentionVerify = useintentionverify
|
1807
1809
|
@IntentionMode = intentionmode
|
@@ -1810,6 +1812,7 @@ module TencentCloud
|
|
1810
1812
|
@IntentionActions = intentionactions
|
1811
1813
|
@IntentionRecognition = intentionrecognition
|
1812
1814
|
@IsSupportHMTResidentPermitOCR = issupporthmtresidentpermitocr
|
1815
|
+
@MouthOpenRecognition = mouthopenrecognition
|
1813
1816
|
end
|
1814
1817
|
|
1815
1818
|
def deserialize(params)
|
@@ -1835,6 +1838,7 @@ module TencentCloud
|
|
1835
1838
|
end
|
1836
1839
|
@IntentionRecognition = params['IntentionRecognition']
|
1837
1840
|
@IsSupportHMTResidentPermitOCR = params['IsSupportHMTResidentPermitOCR']
|
1841
|
+
@MouthOpenRecognition = params['MouthOpenRecognition']
|
1838
1842
|
end
|
1839
1843
|
end
|
1840
1844
|
|
@@ -2002,6 +2006,68 @@ module TencentCloud
|
|
2002
2006
|
end
|
2003
2007
|
end
|
2004
2008
|
|
2009
|
+
# GetFaceIdRiskInfo请求参数结构体
|
2010
|
+
class GetFaceIdRiskInfoRequest < TencentCloud::Common::AbstractModel
|
2011
|
+
# @param FaceIdToken: SDK人脸核身流程的标识,调用GetFaceidRiskInfoToken接口时生成。
|
2012
|
+
# @type FaceIdToken: String
|
2013
|
+
|
2014
|
+
attr_accessor :FaceIdToken
|
2015
|
+
|
2016
|
+
def initialize(faceidtoken=nil)
|
2017
|
+
@FaceIdToken = faceidtoken
|
2018
|
+
end
|
2019
|
+
|
2020
|
+
def deserialize(params)
|
2021
|
+
@FaceIdToken = params['FaceIdToken']
|
2022
|
+
end
|
2023
|
+
end
|
2024
|
+
|
2025
|
+
# GetFaceIdRiskInfo返回参数结构体
|
2026
|
+
class GetFaceIdRiskInfoResponse < TencentCloud::Common::AbstractModel
|
2027
|
+
# @param DeviceInfoTag: 描述当前请求所在设备的风险标签,详情如下: 01-设备疑似被Root/设备疑似越狱 02-设备疑似被注入 03-设备疑似为模拟器 04-设备疑似存在风险操作 05-摄像头疑似被劫持 06-疑似黑产设备
|
2028
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
2029
|
+
# @type DeviceInfoTag: String
|
2030
|
+
# @param DeviceInfoLevel: 描述当前请求所在设备的风险等级,共4级,详情如下: 1 - 安全 2 - 低风险 3 - 中风险 4 - 高危 ,-1表示未获取到风险等级
|
2031
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
2032
|
+
# @type DeviceInfoLevel: Integer
|
2033
|
+
# @param OpenId: 设备id标识
|
2034
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
2035
|
+
# @type OpenId: String
|
2036
|
+
# @param CameraInfoLevel: 描述当前请求所在设备的相机指纹风险等级,共4级,详情如下: 1 - 安全 2 - 低风险 3 - 中风险 4 - 高危 ,-1表示未获取到风险等级
|
2037
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
2038
|
+
# @type CameraInfoLevel: Integer
|
2039
|
+
# @param CameraInfoTag: 描述当前请求所在设备的相机指纹风险标签,详情如下: 01-设备疑似被Root/设备疑似越狱 02-设备疑似被注入 03-设备疑似为模拟器 04-设备疑似存在风险操作 05-摄像头疑似被劫持 06-疑似黑产设备,空表示没有相机指纹风险
|
2040
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
2041
|
+
# @type CameraInfoTag: String
|
2042
|
+
# @param Extra: 获取token时透传的信息
|
2043
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
2044
|
+
# @type Extra: String
|
2045
|
+
# @param RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
2046
|
+
# @type RequestId: String
|
2047
|
+
|
2048
|
+
attr_accessor :DeviceInfoTag, :DeviceInfoLevel, :OpenId, :CameraInfoLevel, :CameraInfoTag, :Extra, :RequestId
|
2049
|
+
|
2050
|
+
def initialize(deviceinfotag=nil, deviceinfolevel=nil, openid=nil, camerainfolevel=nil, camerainfotag=nil, extra=nil, requestid=nil)
|
2051
|
+
@DeviceInfoTag = deviceinfotag
|
2052
|
+
@DeviceInfoLevel = deviceinfolevel
|
2053
|
+
@OpenId = openid
|
2054
|
+
@CameraInfoLevel = camerainfolevel
|
2055
|
+
@CameraInfoTag = camerainfotag
|
2056
|
+
@Extra = extra
|
2057
|
+
@RequestId = requestid
|
2058
|
+
end
|
2059
|
+
|
2060
|
+
def deserialize(params)
|
2061
|
+
@DeviceInfoTag = params['DeviceInfoTag']
|
2062
|
+
@DeviceInfoLevel = params['DeviceInfoLevel']
|
2063
|
+
@OpenId = params['OpenId']
|
2064
|
+
@CameraInfoLevel = params['CameraInfoLevel']
|
2065
|
+
@CameraInfoTag = params['CameraInfoTag']
|
2066
|
+
@Extra = params['Extra']
|
2067
|
+
@RequestId = params['RequestId']
|
2068
|
+
end
|
2069
|
+
end
|
2070
|
+
|
2005
2071
|
# GetFaceIdToken请求参数结构体
|
2006
2072
|
class GetFaceIdTokenRequest < TencentCloud::Common::AbstractModel
|
2007
2073
|
# @param CompareLib: 本地上传照片(LOCAL)、商业库(BUSINESS)
|
@@ -2071,6 +2137,46 @@ module TencentCloud
|
|
2071
2137
|
end
|
2072
2138
|
end
|
2073
2139
|
|
2140
|
+
# GetFaceidRiskInfoToken请求参数结构体
|
2141
|
+
class GetFaceidRiskInfoTokenRequest < TencentCloud::Common::AbstractModel
|
2142
|
+
# @param Meta: SDK中生成的Meta字符串
|
2143
|
+
# @type Meta: String
|
2144
|
+
# @param Extra: 透传参数 1000长度字符串
|
2145
|
+
# @type Extra: String
|
2146
|
+
|
2147
|
+
attr_accessor :Meta, :Extra
|
2148
|
+
|
2149
|
+
def initialize(meta=nil, extra=nil)
|
2150
|
+
@Meta = meta
|
2151
|
+
@Extra = extra
|
2152
|
+
end
|
2153
|
+
|
2154
|
+
def deserialize(params)
|
2155
|
+
@Meta = params['Meta']
|
2156
|
+
@Extra = params['Extra']
|
2157
|
+
end
|
2158
|
+
end
|
2159
|
+
|
2160
|
+
# GetFaceidRiskInfoToken返回参数结构体
|
2161
|
+
class GetFaceidRiskInfoTokenResponse < TencentCloud::Common::AbstractModel
|
2162
|
+
# @param FaceIdToken: 有效期 10分钟。只能完成1次核身。
|
2163
|
+
# @type FaceIdToken: String
|
2164
|
+
# @param RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
2165
|
+
# @type RequestId: String
|
2166
|
+
|
2167
|
+
attr_accessor :FaceIdToken, :RequestId
|
2168
|
+
|
2169
|
+
def initialize(faceidtoken=nil, requestid=nil)
|
2170
|
+
@FaceIdToken = faceidtoken
|
2171
|
+
@RequestId = requestid
|
2172
|
+
end
|
2173
|
+
|
2174
|
+
def deserialize(params)
|
2175
|
+
@FaceIdToken = params['FaceIdToken']
|
2176
|
+
@RequestId = params['RequestId']
|
2177
|
+
end
|
2178
|
+
end
|
2179
|
+
|
2074
2180
|
# GetLiveCode请求参数结构体
|
2075
2181
|
class GetLiveCodeRequest < TencentCloud::Common::AbstractModel
|
2076
2182
|
|
@@ -2584,6 +2690,7 @@ module TencentCloud
|
|
2584
2690
|
# -201: "人脸比对相似度低"
|
2585
2691
|
# -202: "人脸比对失败"
|
2586
2692
|
# -301: "意愿核验不通过"
|
2693
|
+
# -302: "用户回答阶段未检测到张嘴动作"
|
2587
2694
|
# -800: "前端不兼容错误"
|
2588
2695
|
# -801: "用户未授权摄像头和麦克风权限"
|
2589
2696
|
# -802: "核验流程异常中断,请勿切屏或进行其他操作"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tencentcloud-sdk-faceid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.790
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tencent Cloud
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-03-
|
11
|
+
date: 2024-03-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: tencentcloud-sdk-common
|