UNPKG

tencentcloud-sdk-nodejs-intl-en

Version:
1,651 lines (1,407 loc) • 199 kB
/* * Copyright (c) 2018 THL A29 Limited, a Tencent company. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ const AbstractModel = require("../../common/abstract_model"); /** * GetLivenessResult response structure. * @class */ class GetLivenessResultResponse extends AbstractModel { constructor(){ super(); /** * The final verification result. * @type {string || null} */ this.Result = null; /** * The description of the final verification result. * @type {string || null} */ this.Description = null; /** * The face screenshot. * @type {FileInfo || null} */ this.BestFrame = null; /** * The video for the detection. * @type {FileInfo || null} */ this.Video = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Result = 'Result' in params ? params.Result : null; this.Description = 'Description' in params ? params.Description : null; if (params.BestFrame) { let obj = new FileInfo(); obj.deserialize(params.BestFrame) this.BestFrame = obj; } if (params.Video) { let obj = new FileInfo(); obj.deserialize(params.Video) this.Video = obj; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * GetFaceIdTokenIntl response structure. * @class */ class GetFaceIdTokenIntlResponse extends AbstractModel { constructor(){ super(); /** * The SDK token, which is used throughout the verification process and to get the verification result. * @type {string || null} */ this.SdkToken = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.SdkToken = 'SdkToken' in params ? params.SdkToken : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * ID cards of Hong Kong (China), Macao (China) and Taiwan (China), and international passport. * @class */ class InternationalIDPassport extends AbstractModel { constructor(){ super(); /** * Passport ID Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LicenseNumber = null; /** * Full name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FullName = null; /** * Last name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Surname = null; /** * First name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.GivenName = null; /** * Birthday Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Birthday = null; /** * Gender (F-Female, M-Male) Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Sex = null; /** * Expiration date Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.DateOfExpiration = null; /** * Issuing country Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.IssuingCountry = null; /** * Nationality code Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.NationalityCode = null; /** * The first line at the bottom, the MRZ Code sequence Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.PassportCodeFirst = null; /** * The second line at the bottom, the MRZ Code sequence Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.PassportCodeSecond = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.LicenseNumber = 'LicenseNumber' in params ? params.LicenseNumber : null; this.FullName = 'FullName' in params ? params.FullName : null; this.Surname = 'Surname' in params ? params.Surname : null; this.GivenName = 'GivenName' in params ? params.GivenName : null; this.Birthday = 'Birthday' in params ? params.Birthday : null; this.Sex = 'Sex' in params ? params.Sex : null; this.DateOfExpiration = 'DateOfExpiration' in params ? params.DateOfExpiration : null; this.IssuingCountry = 'IssuingCountry' in params ? params.IssuingCountry : null; this.NationalityCode = 'NationalityCode' in params ? params.NationalityCode : null; this.PassportCodeFirst = 'PassportCodeFirst' in params ? params.PassportCodeFirst : null; this.PassportCodeSecond = 'PassportCodeSecond' in params ? params.PassportCodeSecond : null; } } /** * Nigeria driving license * @class */ class NigeriaDrivingLicense extends AbstractModel { constructor(){ super(); /** * Last name. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LastName = null; /** * First name. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FirstName = null; /** * License number. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LicenseNumber = null; /** * Age. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Age = null; /** * Birthday. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Birthday = null; /** * Issued country. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.IssuedCountry = null; /** * Expiration date. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ExpirationDate = null; /** * Issued date. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.IssuedDate = null; /** * Gender. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Sex = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.LastName = 'LastName' in params ? params.LastName : null; this.FirstName = 'FirstName' in params ? params.FirstName : null; this.LicenseNumber = 'LicenseNumber' in params ? params.LicenseNumber : null; this.Age = 'Age' in params ? params.Age : null; this.Birthday = 'Birthday' in params ? params.Birthday : null; this.IssuedCountry = 'IssuedCountry' in params ? params.IssuedCountry : null; this.ExpirationDate = 'ExpirationDate' in params ? params.ExpirationDate : null; this.IssuedDate = 'IssuedDate' in params ? params.IssuedDate : null; this.Sex = 'Sex' in params ? params.Sex : null; } } /** * GetSdkVerificationResult response structure. * @class */ class GetSdkVerificationResultResponse extends AbstractModel { constructor(){ super(); /** * The result code of the verification result. * @type {string || null} */ this.Result = null; /** * The verification result description. * @type {string || null} */ this.Description = null; /** * The charge count. * @type {number || null} */ this.ChargeCount = null; /** * The results of multiple OCR processes (in order). The result of the final process is used as the valid result. * @type {Array.<CardVerifyResult> || null} */ this.CardVerifyResults = null; /** * The results of multiple liveness detection processes (in order). The result of the final process is used as the valid result. * @type {Array.<CompareResult> || null} */ this.CompareResults = null; /** * Data passed through in the process of getting the token. * @type {string || null} */ this.Extra = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Result = 'Result' in params ? params.Result : null; this.Description = 'Description' in params ? params.Description : null; this.ChargeCount = 'ChargeCount' in params ? params.ChargeCount : null; if (params.CardVerifyResults) { this.CardVerifyResults = new Array(); for (let z in params.CardVerifyResults) { let obj = new CardVerifyResult(); obj.deserialize(params.CardVerifyResults[z]); this.CardVerifyResults.push(obj); } } if (params.CompareResults) { this.CompareResults = new Array(); for (let z in params.CompareResults) { let obj = new CompareResult(); obj.deserialize(params.CompareResults[z]); this.CompareResults.push(obj); } } this.Extra = 'Extra' in params ? params.Extra : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * GetSdkVerificationResult request structure. * @class */ class GetSdkVerificationResultRequest extends AbstractModel { constructor(){ super(); /** * The token used to identify an SDK-based verification process. * @type {string || null} */ this.SdkToken = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.SdkToken = 'SdkToken' in params ? params.SdkToken : null; } } /** * DetectAIFakeFaces request structure. * @class */ class DetectAIFakeFacesRequest extends AbstractModel { constructor(){ super(); /** * Enter the image or video with a face to be detected, in base64 encoding. Base64 value of the image: The overall image resolution is recommended to be 480x640, and the face size is 100X100 or larger; The image data size after Base64 encoding does not exceed 3M, and only supports jpg and png formats. Please use standard Base64 encoding (use = for padding). Refer to RFC4648 for encoding specifications. Base64 value of the video: The size after Base64 encoding does not exceed 8M, and supports mp4, avi, and flv formats. Please use standard Base64 encoding (use = for padding). Refer to RFC4648 for encoding specifications. The maximum supported video length is 20s, and the recommended length is 2 to 5s. The recommended video resolution is 480x640, and the frame rate is between 25fps and 30fps. * @type {string || null} */ this.FaceInput = null; /** * The type of input is 1- The input type is a picture 2- The input type is a video Others - Return error code InvalidParameter * @type {number || null} */ this.FaceInputType = null; /** * Whether the request information needs to be fully encrypted; Supported encryption algorithms: AES-256-CBC, SM4-GCM; Users with encryption requirements can use this parameter, for details, please click the link on the left. * @type {Encryption || null} */ this.Encryption = null; /** * Encrypted ciphertext; The data format before encryption is as follows:{"FaceInput":"AAAAA","FaceInputType":1} * @type {string || null} */ this.EncryptedBody = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.FaceInput = 'FaceInput' in params ? params.FaceInput : null; this.FaceInputType = 'FaceInputType' in params ? params.FaceInputType : null; if (params.Encryption) { let obj = new Encryption(); obj.deserialize(params.Encryption) this.Encryption = obj; } this.EncryptedBody = 'EncryptedBody' in params ? params.EncryptedBody : null; } } /** * Suspected attack detail * @class */ class AttackRiskDetail extends AbstractModel { constructor(){ super(); /** * Suspected attack trace types SuspectedSpoofingAttack: Suspected spoofing attack SuspectedSynthesisImage: Suspected synthesis image SuspectedSynthesisVideo: Suspected synthesis video SuspectedeAnomalyAttack: Suspected anomaly attack SuspectedAdversarialAttack: Suspected adversarial attack SuspectedBlackIndustry: Suspected batch generation attack SuspectedWatermark: Suspected watermark * @type {string || null} */ this.Type = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Type = 'Type' in params ? params.Type : null; } } /** * * @class */ class ExtraInfo extends AbstractModel { constructor(){ super(); /** * * @type {Array.<RetrievalLivenessExtraInfo> || null} */ this.RetrievalLivenessExtraInfo = null; } /** * @private */ deserialize(params) { if (!params) { return; } if (params.RetrievalLivenessExtraInfo) { this.RetrievalLivenessExtraInfo = new Array(); for (let z in params.RetrievalLivenessExtraInfo) { let obj = new RetrievalLivenessExtraInfo(); obj.deserialize(params.RetrievalLivenessExtraInfo[z]); this.RetrievalLivenessExtraInfo.push(obj); } } } } /** * CreateUploadUrl response structure. * @class */ class CreateUploadUrlResponse extends AbstractModel { constructor(){ super(); /** * The URL for uploading contents with the `HTTP PUT` method. * @type {string || null} */ this.UploadUrl = null; /** * The resource URL obtained after this upload is completed and to be passed in where it is required later. * @type {string || null} */ this.ResourceUrl = null; /** * The point in time when the upload/download link expires, which is a 10-bit Unix timestamp. * @type {number || null} */ this.ExpiredTimestamp = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.UploadUrl = 'UploadUrl' in params ? params.UploadUrl : null; this.ResourceUrl = 'ResourceUrl' in params ? params.ResourceUrl : null; this.ExpiredTimestamp = 'ExpiredTimestamp' in params ? params.ExpiredTimestamp : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * Malaysia ID card. * @class */ class NormalMLIDCard extends AbstractModel { constructor(){ super(); /** * Full Name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FullName = null; /** * License number Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LicenseNumber = null; /** * Gender Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Sex = null; /** * Address Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FormattedAddress = null; /** * Lisence type MyKad ID card MyPR Permanent resident ID card MyTentera Military ID card MyKAS Temporary ID card POLIS Police ID card IKAD Labor ID card MyKid Juvenile ID card Example: MyKad * @type {string || null} */ this.Type = null; /** * Birthday (Currently, this filed only supports IKAD labor ID card and MyKad ID card) Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Birthday = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.FullName = 'FullName' in params ? params.FullName : null; this.LicenseNumber = 'LicenseNumber' in params ? params.LicenseNumber : null; this.Sex = 'Sex' in params ? params.Sex : null; this.FormattedAddress = 'FormattedAddress' in params ? params.FormattedAddress : null; this.Type = 'Type' in params ? params.Type : null; this.Birthday = 'Birthday' in params ? params.Birthday : null; } } /** * ApplyCardVerification response structure. * @class */ class ApplyCardVerificationResponse extends AbstractModel { constructor(){ super(); /** * The token used to identify an verification process. It can be used to get the verification result after the process is completed. * @type {string || null} */ this.CardVerificationToken = null; /** * The maximum number of polls for calling the pull result interface polling. * @type {number || null} */ this.AsyncCardVerificationMaxPollingTimes = null; /** * The interval for polling when calling the pull result interface (in seconds). * @type {number || null} */ this.AsyncCardVerificationPollingWaitTime = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.CardVerificationToken = 'CardVerificationToken' in params ? params.CardVerificationToken : null; this.AsyncCardVerificationMaxPollingTimes = 'AsyncCardVerificationMaxPollingTimes' in params ? params.AsyncCardVerificationMaxPollingTimes : null; this.AsyncCardVerificationPollingWaitTime = 'AsyncCardVerificationPollingWaitTime' in params ? params.AsyncCardVerificationPollingWaitTime : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DetectReflectLivenessAndCompare request structure. * @class */ class DetectReflectLivenessAndCompareRequest extends AbstractModel { constructor(){ super(); /** * URL of the liveness detection data package generated by the SDK * @type {string || null} */ this.LiveDataUrl = null; /** * MD5 hash value (32-bit) of the liveness detection data package generated by the SDK, which is used to verify the LiveData consistency. * @type {string || null} */ this.LiveDataMd5 = null; /** * URL of the target image for comparison * @type {string || null} */ this.ImageUrl = null; /** * MD5 hash value (32-bit) of the target image for comparison, which is used to verify the `Image` consistency. * @type {string || null} */ this.ImageMd5 = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.LiveDataUrl = 'LiveDataUrl' in params ? params.LiveDataUrl : null; this.LiveDataMd5 = 'LiveDataMd5' in params ? params.LiveDataMd5 : null; this.ImageUrl = 'ImageUrl' in params ? params.ImageUrl : null; this.ImageMd5 = 'ImageMd5' in params ? params.ImageMd5 : null; } } /** * GetFaceIdTokenIntl request structure. * @class */ class GetFaceIdTokenIntlRequest extends AbstractModel { constructor(){ super(); /** * The detection mode. Valid values: `liveness`: Liveness detection only. `compare`: Selfie verification. Default value: `liveness`. * @type {string || null} */ this.CheckMode = null; /** * The verification security level. Valid values: `1`: Video-based liveness detection. `2`: Motion-based liveness detection. `3`: Reflection-based liveness detection. `4`: Motion- and reflection-based liveness detection. Default value: `4`. * @type {string || null} */ this.SecureLevel = null; /** * The photo (in Base64) to compare. This parameter is required when the value of `CheckMode` is `compare`. * @type {string || null} */ this.Image = null; /** * The pass-through parameter, which can be omitted if there are no special requirements. * @type {string || null} */ this.Extra = null; /** * This interface is used to control th action sequences. Action types are as follows: "blink" "mouth" "nod" "shake" You can choose 1-2 actions out of the four. Single action example: "blink" Multiple action example: "blink,mouth" The default value is blink. The different action types passed in this parameter take effect only when the SecurityLevel is 2 or 4; otherwise, the interface reports an error. * @type {string || null} */ this.ActionList = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.CheckMode = 'CheckMode' in params ? params.CheckMode : null; this.SecureLevel = 'SecureLevel' in params ? params.SecureLevel : null; this.Image = 'Image' in params ? params.Image : null; this.Extra = 'Extra' in params ? params.Extra : null; this.ActionList = 'ActionList' in params ? params.ActionList : null; } } /** * Japan ID card. * @class */ class JapanIDCard extends AbstractModel { constructor(){ super(); /** * Full name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FullName = null; /** * License number Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LicenseNumber = null; /** * Age Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Age = null; /** * Birthday Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Birthday = null; /** * Expire date Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ExpirationDate = null; /** * Address Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FormattedAddress = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.FullName = 'FullName' in params ? params.FullName : null; this.LicenseNumber = 'LicenseNumber' in params ? params.LicenseNumber : null; this.Age = 'Age' in params ? params.Age : null; this.Birthday = 'Birthday' in params ? params.Birthday : null; this.ExpirationDate = 'ExpirationDate' in params ? params.ExpirationDate : null; this.FormattedAddress = 'FormattedAddress' in params ? params.FormattedAddress : null; } } /** * * @class */ class EditDetail extends AbstractModel { constructor(){ super(); /** * Modified Field Name * @type {string || null} */ this.FieldName = null; /** * Value of the field before modification, the original OCR result * @type {string || null} */ this.OriginalFieldValue = null; /** * Value of the field after modification,the user's manually entered result * @type {string || null} */ this.RevisedFieldValue = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.FieldName = 'FieldName' in params ? params.FieldName : null; this.OriginalFieldValue = 'OriginalFieldValue' in params ? params.OriginalFieldValue : null; this.RevisedFieldValue = 'RevisedFieldValue' in params ? params.RevisedFieldValue : null; } } /** * ApplyWebVerificationToken response structure. * @class */ class ApplyWebVerificationTokenResponse extends AbstractModel { constructor(){ super(); /** * The verification URL to be opened with a browser to start the verification process. * @type {string || null} */ this.VerificationUrl = null; /** * The token used to identify a web-based verification process. It is valid for 7,200s and can be used to get the verification result after the process is completed. * @type {string || null} */ this.BizToken = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.VerificationUrl = 'VerificationUrl' in params ? params.VerificationUrl : null; this.BizToken = 'BizToken' in params ? params.BizToken : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * Hong Kong (China) ID card. * @class */ class NormalHKIDCard extends AbstractModel { constructor(){ super(); /** * Chinese name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ChineseName = null; /** * English name Note: This field may return null, indicating that no valid values can be obtained. Example: SAN, Nan * @type {string || null} */ this.FullName = null; /** * Telex code correspondint to the Chinese name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.RegistrationNumber = null; /** * Gender: "Male-M" or "Female-F" Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Sex = null; /** * Birthday Note: This field may return null, indicating that no valid values can be obtained. Example: 01-01-2001 * @type {string || null} */ this.Birthday = null; /** * Permanent resident ID card: 0-non-permanent; 1-permanent; -1-unknown Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Permanent = null; /** * ID card number Note: This field may return null, indicating that no valid values can be obtained. Example: C000000(E) * @type {string || null} */ this.LicenseNumber = null; /** * Lisence symbol, which is the symbol below Birthday. Example: "***AZ" Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Symbol = null; /** * The first date of issue Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.IssuedDate = null; /** * The current date of issue Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.CurrentIssueDate = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ChineseName = 'ChineseName' in params ? params.ChineseName : null; this.FullName = 'FullName' in params ? params.FullName : null; this.RegistrationNumber = 'RegistrationNumber' in params ? params.RegistrationNumber : null; this.Sex = 'Sex' in params ? params.Sex : null; this.Birthday = 'Birthday' in params ? params.Birthday : null; this.Permanent = 'Permanent' in params ? params.Permanent : null; this.LicenseNumber = 'LicenseNumber' in params ? params.LicenseNumber : null; this.Symbol = 'Symbol' in params ? params.Symbol : null; this.IssuedDate = 'IssuedDate' in params ? params.IssuedDate : null; this.CurrentIssueDate = 'CurrentIssueDate' in params ? params.CurrentIssueDate : null; } } /** * GetWebVerificationResult request structure. * @class */ class GetWebVerificationResultRequest extends AbstractModel { constructor(){ super(); /** * The token for the web-based verification, which is generated with the `ApplyWebVerificationToken` API. * @type {string || null} */ this.BizToken = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.BizToken = 'BizToken' in params ? params.BizToken : null; } } /** * Thailand ID Card * @class */ class ThailandIDCard extends AbstractModel { constructor(){ super(); /** * Last name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LastName = null; /** * First name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FirstName = null; /** * License number Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LicenseNumber = null; /** * Birthday Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.DateOfBirth = null; /** * Date of expiry Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.DateOfExpiry = null; /** * Date of issue Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.DateOfIssue = null; /** * Issuing country Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.IssuedCountry = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.LastName = 'LastName' in params ? params.LastName : null; this.FirstName = 'FirstName' in params ? params.FirstName : null; this.LicenseNumber = 'LicenseNumber' in params ? params.LicenseNumber : null; this.DateOfBirth = 'DateOfBirth' in params ? params.DateOfBirth : null; this.DateOfExpiry = 'DateOfExpiry' in params ? params.DateOfExpiry : null; this.DateOfIssue = 'DateOfIssue' in params ? params.DateOfIssue : null; this.IssuedCountry = 'IssuedCountry' in params ? params.IssuedCountry : null; } } /** * The details of the verification process. * @class */ class VerificationDetail extends AbstractModel { constructor(){ super(); /** * The final result of this verification. `0` indicates that the person is the same as that in the photo. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ErrorCode = null; /** * The description of the final verification result. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ErrorMsg = null; /** * The result of this liveness detection process. `0` indicates success. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.LivenessErrorCode = null; /** * The result description of this liveness detection process. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LivenessErrorMsg = null; /** * The result of this comparison process. `0` indicates that the person in the best face screenshot collected from the video stream is the same as that in the uploaded image for comparison. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.CompareErrorCode = null; /** * The result description of this comparison process. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.CompareErrorMsg = null; /** * The timestamp (ms) of this verification process. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ReqTimestamp = null; /** * The similarity of the best face screenshot collected from the video stream and the uploaded image for comparison in this verification process. Value range: [0.00, 100.00]. By default, the person in the screenshot is determined to be the same person in the image if the similarity is greater than or equal to 70. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.Similarity = null; /** * Unique ID of this verification process. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Seq = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ErrorCode = 'ErrorCode' in params ? params.ErrorCode : null; this.ErrorMsg = 'ErrorMsg' in params ? params.ErrorMsg : null; this.LivenessErrorCode = 'LivenessErrorCode' in params ? params.LivenessErrorCode : null; this.LivenessErrorMsg = 'LivenessErrorMsg' in params ? params.LivenessErrorMsg : null; this.CompareErrorCode = 'CompareErrorCode' in params ? params.CompareErrorCode : null; this.CompareErrorMsg = 'CompareErrorMsg' in params ? params.CompareErrorMsg : null; this.ReqTimestamp = 'ReqTimestamp' in params ? params.ReqTimestamp : null; this.Similarity = 'Similarity' in params ? params.Similarity : null; this.Seq = 'Seq' in params ? params.Seq : null; } } /** * GetWebVerificationResultIntl response structure. * @class */ class GetWebVerificationResultIntlResponse extends AbstractModel { constructor(){ super(); /** * The final result of this verification. `0` indicates that the person is the same as that in the photo. For other error codes, see <a href="https://www.tencentcloud.com/document/product/1061/55390?lang=en&pg=#8a960e1e-39c0-42cb-b181-b3164d77f81e">Selfie Verification (Mobile HTML5) Error Codes</a> Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ErrorCode = null; /** * The description of the final verification result. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ErrorMsg = null; /** * The detailed verification result list of this process. Retries are allowed, so a verification process may have several entries of results. Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<VerificationDetail> || null} */ this.VerificationDetailList = null; /** * The Base64-encoded string of the video collected from the video stream. Retries are allowed, and this field returns only the data collected in the last verification. If no video is collected, null is returned. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.VideoBase64 = null; /** * The Base64-encoded string of the best face screenshot collected from the video stream. Retries are allowed, and this field returns only the data collected in the last verification. If no best face screenshot is collected, null is returned. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.BestFrameBase64 = null; /** * Card recognize result. Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<OCRResult> || null} */ this.OCRResult = null; /** * The passthrough parameter of the business, max 1,000 characters, which will be returned in GetWebVerificationResultIntl. * @type {string || null} */ this.Extra = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ErrorCode = 'ErrorCode' in params ? params.ErrorCode : null; this.ErrorMsg = 'ErrorMsg' in params ? params.ErrorMsg : null; if (params.VerificationDetailList) { this.VerificationDetailList = new Array(); for (let z in params.VerificationDetailList) { let obj = new VerificationDetail(); obj.deserialize(params.VerificationDetailList[z]); this.VerificationDetailList.push(obj); } } this.VideoBase64 = 'VideoBase64' in params ? params.VideoBase64 : null; this.BestFrameBase64 = 'BestFrameBase64' in params ? params.BestFrameBase64 : null; if (params.OCRResult) { this.OCRResult = new Array(); for (let z in params.OCRResult) { let obj = new OCRResult(); obj.deserialize(params.OCRResult[z]); this.OCRResult.push(obj); } } this.Extra = 'Extra' in params ? params.Extra : null; this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * The description of a file, including a download URL and the MD5 checksum and size of the file. * @class */ class FileInfo extends AbstractModel { constructor(){ super(); /** * The URL for downloading the file * @type {string || null} */ this.Url = null; /** * The 32-bit MD5 checksum of the file * @type {string || null} */ this.MD5 = null; /** * The file size * @type {number || null} */ this.Size = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Url = 'Url' in params ? params.Url : null; this.MD5 = 'MD5' in params ? params.MD5 : null; this.Size = 'Size' in params ? params.Size : null; } } /** * Hong Kong (China) ID card. * @class */ class HKIDCard extends AbstractModel { constructor(){ super(); /** * Chinese name Note: This field may return null, indicating that no valid values can be obtained. Example: SAN, Nan * @type {string || null} */ this.CnName = null; /** * English name Note: This field may return null, indicating that no valid values can be obtained. Example: SAN, Nan * @type {string || null} */ this.EnName = null; /** * Telex code correspondint to the Chinese name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TelexCode = null; /** * Gender: "Male-M" or "Female-F" Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Sex = null; /** * Birthday Note: This field may return null, indicating that no valid values can be obtained. Example: 01-01-2001 * @type {string || null} */ this.Birthday = null; /** * Permanent resident ID card: 0-non-permanent; 1-permanent; -1-unknown Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Permanent = null; /** * ID card number Note: This field may return null, indicating that no valid values can be obtained. Example: C000000(E) * @type {string || null} */ this.IdNum = null; /** * Lisence symbol, which is the symbol below Birthday. Example: "***AZ" Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Symbol = null; /** * The first date of issue Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FirstIssueDate = null; /** * The current date of issue Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.CurrentIssueDate = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.CnName = 'CnName' in params ? params.CnName : null; this.EnName = 'EnName' in params ? params.EnName : null; this.TelexCode = 'TelexCode' in params ? params.TelexCode : null; this.Sex = 'Sex' in params ? params.Sex : null; this.Birthday = 'Birthday' in params ? params.Birthday : null; this.Permanent = 'Permanent' in params ? params.Permanent : null; this.IdNum = 'IdNum' in params ? params.IdNum : null; this.Symbol = 'Symbol' in params ? params.Symbol : null; this.FirstIssueDate = 'FirstIssueDate' in params ? params.FirstIssueDate : null; this.CurrentIssueDate = 'CurrentIssueDate' in params ? params.CurrentIssueDate : null; } } /** * Singapore ID Card * @class */ class SingaporeIDCard extends AbstractModel { constructor(){ super(); /** * Chinese name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ChName = null; /** * Chinese name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ChineseName = null; /** * English name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.EnName = null; /** * English name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.FullName = null; /** * License number Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ID = null; /** * License number Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.LicenseNumber = null; /** * Gender Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Sex = null; /** * Country of birth Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.CountryOfBirth = null; /** * Nationality Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Nationality = null; /** * Birthday Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Birthday = null; /** * Address (on the back) Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Address = null; /** * Race (on the back) Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Race = null; /** * NRIC number (on the back) Note: This field may return null, indicating that no valid values can be obtained