DescribeFaceVerify - Retrieve authentication results

Updated at:

This topic describes how to query the authentication results for an App-based Real-Person Verification by using the DescribeFaceVerify API.

API description

API operation: DescribeFaceVerify

Global endpoint: cloudauth.aliyuncs.com (IPv4) or cloudauth-dualstack.aliyuncs.com (IPv6)

Request method: POST and GET

Transport protocol: HTTPS

Description: After receiving a callback notification, call this API server-side to retrieve its verification status and data.

QPS limit: Each API has a dedicated limit. See Server-side API QPS limits.

Request parameters

Parameter

Type

Required

Description

Example

SceneId

Long

Yes

The authentication scene ID. The console automatically generates this ID after you create an authentication scene.

1000000006

CertifyId

String

Yes

The unique real-person verification ID.

Obtain this value by calling the InitFaceVerify - Initiate an authentication request API.

91707dc296d469ad38e4c5efa6a0****

Response data

Parameter

Type

Description

Example

RequestId

String

The request ID.

130A2C10-B9EE-4D84-88E3-5384FF039795

Code

String

The return code. A value of 200 indicates that the request was successful.

For detailed descriptions of different Code values, see Return codes and messages.

200

Message

String

The response message, which provides a brief description of the Code (return code).

success

ResultObject.Passed

String

The authentication result. Valid values:

  • T: Pass

  • F: Fail

Note

Use the ResultObject.Passed field to determine the authentication result.

T

ResultObject.SubCode

String

A description of the verification result.

For descriptions and troubleshooting suggestions for different status codes, see ResultObject.SubCode error codes.

Note

Use the ResultObject.Passed field to determine the final verification result.

200

ResultObject.IdentityInfo

String

The identity information of the authenticated user. This field is typically empty for standard authentication scenes.

null

ResultObject.DeviceToken

String

The device token.

McozS1ZWRcRZStlERcZZo_QOytx5jcgZoZJEoRLOxxxxxxx

ResultObject.DeviceRisk

String

The device risk tag.

ROOT,VPN,HOOK

Note

Multiple device risk tags are separated by commas (,).

For more information about the tags and their meanings, see device risk tags.

ResultObject.MaterialInfo

String

The response varies for ID_PRO and ID_PLUS. Select a tab to view the details for each plan. For more information, see Attachment information of the face authentication subject.

ID_PRO

  • Predicted age and gender from the face image (faceAge/faceGender). Prediction may fail and return no value.

  • Device risk score predicted by device-level algorithms (guardRiskScore). A higher score indicates higher device risk (range: 0–100).

  • Face liveness verification result and score (faceAttack/faceAttackScore).

  • Face occlusion detection result and quality score (faceOcclusion/qualityScore), plus detailed quality fields.

  • Matching score between the face photo and the authoritative source photo (verifyScore).

    Note

    verifyScore is the matching score between the liveness face photo and the authoritative source photo.

    Due to authoritative source adjustments, the authority matching score may not be returned or may be unreliable. It is recommended to rely on the final authentication result (SubCode).

  • OSS storage location and URL of the face photo (video optional).

    Fields for face photo materials and verification video materials are returned based on different configuration items, as follows:

    • The fields related to facial photos (ossBucketName, ossObjectName, pictureUrl) are returned based solely on the configuration in the console authentication scenario:

      • In the console Verification scenario, enable Retain verification materials.

      • OSS authorization is configured and enabled in the console.

    • The video authentication fields (verifyVideoUrl and ossVerifyVideoObjectName) are returned only if all the following conditions are met:

      • In the console Verification scenario, enable Retain verification materials.

      • OSS authorization is configured and enabled in the console.

      • The client configures video return in the extParams parameter (for WebSDK, explicitly configure video-return fields in InitFaceVerify).

    Note

    By default, only the best face photo is returned. To return multiple photos, see Add a verification scenario for configuration.

ID_PLUS

  • Predicted age and gender from the face image (faceAge/faceGender). Prediction may fail and return no value.

  • Device risk score predicted by device-level algorithms (guardRiskScore). A higher score indicates higher device risk (range: 0–100).

  • Face liveness verification result and score (faceAttack/faceAttackScore).

  • Face occlusion detection result and quality score (faceOcclusion/qualityScore), plus detailed quality fields.

  • Matching score between the face photo and the authoritative source photo (verifyScore).

    Note

    verifyScore is the matching score between the liveness face photo and the authoritative source photo.

    Due to authoritative source adjustments, the authority matching score may not be returned or may be unreliable. It is recommended to rely on the final authentication result (SubCode).

  • Matching score between the face photo and the ID card photo (idCardVerifyScore).

    Note

    idCardVerifyScore is the matching score between the liveness face photo and the ID card photo.

  • OCR-extracted information and OSS storage location and URL of the ID card photo.

  • OSS storage location and URL of the face photo (video optional).

    Fields for face photo materials and verification video materials are returned based on different configuration items, as follows:

    • The fields related to facial photos (ossBucketName, ossObjectName, pictureUrl) are returned based solely on the configuration in the console authentication scenario:

      • In the console Verification scenario, enable Retain verification materials.

      • OSS authorization is configured and enabled in the console.

    • The video authentication fields (verifyVideoUrl and ossVerifyVideoObjectName) are returned only if all the following conditions are met:

      • In the console Verification scenario, enable Retain verification materials.

      • OSS authorization is configured and enabled in the console.

      • The client configures video return in the extParams parameter (for WebSDK, explicitly configure video-return fields in InitFaceVerify).

    Note

    By default, only the best face photo is returned. To return multiple photos, see Add a verification scenario for configuration.

ID_PRO

{
  "faceAttack": "T",
  "faceOcclusion": "F",
  "faceAge":"20",
  "facialPictureFront": {
    "faceAttackScore": 0.00008597839769208804,
    "qualityScore": 99.93476867675781,
    "qualityBackground": "0",
    "qualityBlur": "0",
    "qualityIllu": "0",
    "qualityOccu": "0",
    "qualityWearHat": "F",
    "Gender":"M",
    "verifyScore": 57.678396649466755,
    "ossBucketName": "cn-shanghai-aliyun-cloudauth-12600*********",
    "ossObjectName": "verify/1260***4779/03a08********.jpeg",
    "pictureUrl": "http://cn-shanghai-aliyun-cloudauth-1260***4779.oss-cn-shanghai.aliyuncs.com/verify/1260***4779/03a081********.jpeg?&security-token=CAISjgJ1q6Ft...",
    "ossVerifyVideoObjectName": "verify/1260***4779/03a081****_verifyvideo_dcb7.mov",
    "verifyVideoUrl": "http://cn-shanghai-aliyun-cloudauth-1260***4779.oss-cn-shanghai.aliyuncs.com/verify/1260***4779/03a08150c57__********.mov?security-token=CAISjgJ1q6Ft...",
    "guardRiskScore":20
  }
}

ID_PLUS

{
  "faceAttack": "T",
  "faceOcclusion": "F",
  "faceAge":"20",
  "facialPictureFront": {
    "faceAttackScore": 0.00008597839769208804,
    "qualityScore": 99.93476867675781,
    "qualityBackground": "0",
    "qualityBlur": "0",
    "qualityIllu": "0",
    "qualityOccu": "0",
    "qualityWearHat": "F",
    "Gender":"M",
    "verifyScore": 57.678396649466755,
    "idCardVerifyScore": 50.99797734769861,
    "ossBucketName": "cn-shanghai-aliyun-cloudauth-12600*********",
    "ossObjectName": "verify/1260051251634779/03a081bd96328aedf83f635f3********.jpeg",
    "pictureUrl": "http://cn-shanghai-aliyun-cloudauth-1260051251634779.oss-cn-shanghai.aliyuncs.com/verify/1260051251634779/03a081bd96328aedf83f635f********.jpeg?&security-token=CAISjgJ1q6Ft...",
    "ossVerifyVideoObjectName": "verify/1260051251634779/03a081bd96328aedf83f635****_verifyvideo_dcb7.mov",
    "verifyVideoUrl": "http://cn-shanghai-aliyun-cloudauth-1260051251634779.oss-cn-shanghai.aliyuncs.com/verify/1260051251634779/03a081bd96328aedf83f635f39a50c57__********.mov?security-token=CAISjgJ1q6Ft..."
  },
  "ocrIdCardInfo": {
    "address": "XXX Province, XX City, XXX District, XX Street, X No.",
    "authority": "XXX Public Security Bureau, XXX Branch",
    "birth": "20010213",
    "certName": "Mr. Zhang",
    "certNo": "4****************X",
    "endDate": "20450523",
    "nationality": "Han",
    "sex": "Male",
    "startDate": "20250523"
  },
  "ocrPictureFront": {
    "ossBucketName": "cn-shanghai-aliyun-cloudauth-12********",
    "ossIdFaceObjectName": "verify/1234567890/f7ed1ef80ad1234fdsd95c********cd_ocridface_b749.jpeg",
    "ossIdFaceUrl": "http://cn-shanghai-aliyun-cloudauth-1234567890.oss-cn-shanghai.aliyuncs.com/verify/1234567890/f7ed1ef80ad1234fdsd95c66d83340cd_ocridface_b749.jpeg?security-token=CAISjdfgeJ1q6F...",
    "ossIdNationalEmblemObjectName": "verify/1234567890/f7ed1ef80ad1234fdsd95c********cd_ocridnationalemblem_a3hf.jpeg",
    "ossIdNationalEmblemUrl": "http://cn-shanghai-aliyun-cloudauth-1234567890.oss-cn-shanghai.aliyuncs.com/verify/1234567890/f7ed1ef80ad1234fdsd95c66d83340cd_ocridnationalemblem_a3hf.jpeg?security-token=CAISjgJ1q6...",
    "guardRiskScore":20
  }
}

If multiple photos are configured to return, the facialPictureFront field also returns the following:

"customFaceObjectNameUrls": [
  "https://cn-shanghai-aliyun-cloudauth-177***150.oss-cn-shanghai.aliyuncs.com/verify/177***150/sha58***Pic1.jpeg?Expires=17***9&OSSAccessKeyId=STS.NZtBj***SFWN&Signature=8%2***IKRZFdgsY%3D&security-token=CAIS2w***A%3D",
  "https://cn-shanghai-aliyun-cloudauth-177***150.oss-cn-shanghai.aliyuncs.com/verify/177***150/sha58***Pic2.jpeg?Expires=17***9&OSSAccessKeyId=STS.NZtBj***SFWN&Signature=8%2***IKRZFdgsY%3D&security-token=CAIS2w***A%3D"
],
"customFaceObjectNames": [
  "verify/177***150/sha589b06***Pic1.jpeg",
  "verify/177***150/sha589b06***Pic2.jpeg"
]

ResultObject.UserInfo

String

The user-entered identity information and its corresponding encoding in rare character mode. The API returns the data as a JSON-formatted string. If the name does not contain any rare characters, an empty string is returned.

  • name: The user-entered name.

  • verifyName: The final name encoding that passed verification. This is relevant when a rare character is transcoded to a common one for verification.

  • number: The user-entered ID number.

{
  "number": "610***********1110",
  "name": "Wang Xiansheng",
  "verifyName": "Wang Xian"
}