接口请求域名: faceid.intl.tencentcloudapi.com 。
完成Sdk核验流程后,用核验令牌(Token)调用本接口查询对应核验结果信息。Token申请后三天内有效,可多次调用。
默认接口请求频率限制:20次/秒。
以下请求参数列表仅列出了接口请求参数和部分公共参数,完整公共参数列表见 公共请求参数。
| 参数名称 | 必选 | 类型 | 描述 |
|---|---|---|---|
| Action | 是 | String | 公共参数,本接口取值:GetSdkVerificationResult。 |
| Version | 是 | String | 公共参数,本接口取值:2018-03-01。 |
| Region | 是 | String | 公共参数,详见产品支持的 地域列表。 |
| SdkToken | 是 | String | 标识一次Sdk核验流程的令牌。 |
| 参数名称 | 类型 | 描述 |
|---|---|---|
| Result | String | 此次核验结果的结果码。 |
| Description | String | 核验结果描述。 |
| ChargeCount | Integer | 计费次数。 |
| CardVerifyResults | Array of CardVerifyResult | 多次证照识别的结果(有序),取最终一次结果为有效结果。 |
| CompareResults | Array of CompareResult | 多次活体认证的结果信息(有序),取最终一次结果为有效结果。 |
| Extra | String | 获取token时传入的透传数据。 |
| DeviceInfoLevel | String | 描述当前请求所在设备的风险等级,共4级。 详情如下: 1 - 安全。 2 - 低风险。 3 - 中风险。 4 - 高危。 空 - 未获取到风险等级。 仅增强版返回,默认为空。 |
| RequestId | String | 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。 |
获取结果
POST / HTTP/1.1
Host: faceid.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: GetSdkVerificationResult
<公共请求参数>
{
"SdkToken": "D2B55F0C-FB5D-4FB6-8765-3E931EBBFC79"
}
{
"Response": {
"CardVerifyResults": [
{
"IsPass": true,
"CardVideo": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "682e24b207acf1825286c1fceef5631c",
"Size": 9430792
},
"CardImage": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "667c2448b10b09ee9ec14ab2b0d36608",
"Size": 232267
},
"CardInfoOcrJson": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "0ae50935bb50cd70e6e34f81ff2e3fbd",
"Size": 224
},
"RequestId": "8e510d65-c26e-4de7-991d-e07ef0ad953d"
}
],
"CompareResults": [
{
"ErrorCode": "1001",
"ErrorMsg": "Failed to call the liveness engine",
"LiveData": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "f624d26bfb45e149b293097037819feb",
"Size": 719585
},
"LiveVideo": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "e87070d8eb95f64bc01b12e03cc8f533",
"Size": 887224
},
"ActionVideo": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "e87070d8eb95f64bc01b12e03cc8f533",
"Size": 887224
},
"LiveErrorCode": "1001",
"LiveErrorMsg": "Failed to call the liveness engine",
"CompareErrorCode": "",
"CompareErrorMsg": "",
"BestFrame": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "c4f217871aaeb0180e40152f61658835",
"Size": 122984
},
"ProfileImage": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "d51df99b25d87785ea5e2dfb0d6e920f",
"Size": 23091
},
"Sim": 0,
"IsNeedCharge": true,
"CardInfoInputJson": {
"Url": "https://intl-reflect-h5-1257237511.cos.ap-guangzhou.myqcloud.com",
"MD5": "02497f445dc72a330b468fa24529315b",
"Size": 219
},
"RequestId": "6e498069-4d51-4032-82a8-9adb53cda85b"
}
],
"ChargeCount": 4,
"Description": "Failed to call the liveness engine",
"Extra": "",
"RequestId": "b8cb2269-08b2-426c-8be8-c7142c7e64e4",
"Result": "1001"
}
}
云 API 3.0 提供了配套的开发工具集(SDK),支持多种编程语言,能更方便的调用 API。
该接口暂无业务逻辑相关的错误码,其他错误码详见 公共错误码。
文档反馈