Getting the verification result
Register a notification url to be informed when verification status has been changed
If you want to be notified when a verification changes its status you can provide a URL to allow MobbScan to send a notification to update you the status
and id
.
The endpoint must be a post request and it should have the following object request as body input:
{
"verificationId" : "",
"status" : "VERIFIED | NOT_VERIFIED | PENDING"
}
Note: To register your URL for this service you have to get in touch with Mobbeel's team to register it on your mobbscan-agent instance.
Checking if verification process is finished
Sometimes, if your process involves more steps after the document scan (like video conference or some kind of human verification of your data), you may need to get the result of the complete process (not only the scanned data) at the final step.
self.mobbscanAPI.checkVerificationProcessResult(forScanId:scanId, withResultListener: { result, resultData, error in
// your listener code here
})
[self.mobbScanAPI checkVerificationProcessResultForScanId:scanId
withResultListener:^(MobbScanVerificationProcessResult result, MobbScanVerificationProcessResultData * _Nullable resultData, NSError * _Nullable error) {
// your listener code here
}];
This method will return the status immediately with the result VERIFIED
, NOT_VERIFIED
, depending of the verification outcome, PENDING
if verification is still not finished, or ERROR
if something went wrong.
Retrieving evidences of the verification process
Once the verification is done, all evidences of the process (including OCR result, document images, face pictures, video recordings, etc) will be available using the getVerificationProcessResult
call of the REST API:
method | url |
---|---|
GET | https://youragentinstance.yourcompany.com/getVerificationProcessData/{verificationId}.json |
This API is private, so you will need to add Basic HTTP headers with user/password credentials.
Possible responses are:
Success
HTTP Code: 200
Response:
{
"code": "OK",
"description": "GET_VERIFICATION_PROCESS_DATA_SUCCESS",
"scanId": "",
"verificationResult": "PENDING | VERIFIED | NOT_VERIFIED",
"licenseId": "",
"agent": "",
"document": {
"documentType": "",
"personalNumber": "",
"documentNumber": "",
"name": "",
"surname": "",
"firstSurname": "",
"secondSurname": "",
"gender": "",
"nationality": "",
"dateOfBirth": "",
"dateOfExpiry": "",
"address": "",
"city": "",
"region": "",
"cityOfBirth": "",
"regionOfBirth": "",
"stateOfBirthName": "",
"facialMatchingScore": ""
},
"images": [
{
"imageType": "",
"url": ""
}
],
"recordings": [
{
"recordingType": "video_conference",
"url": ""
}
],
"extraParameters": [
{
"parameterName": "",
"parameterValue": ""
}
],
"extraImages": [],
"validations": {
"success": [
""
],
"failed": [
""
],
"notChecked": [
""
]
},
"pdfUrl": "/api/pdf/..."
}
Note: Images and recordings are not directly returned in the response for size reasons, as some of them may contain large files. You can get the actual files by just making a
GET
request to the specific URL for each file.
Failure
"Wrong scanId"
HTTP Code: 200
Response:
{
"code": "ERROR",
"description": "ERROR_SCAN_ID_DOES_NOT_EXIST",
}