Validation - gotmoby/moby-api-documentation GitHub Wiki

Preface

In order to validate a license or passport your account must be configured correctly. Please visit configuration if you have not configured the API to your needs.

Postman Documentation

Validating a document

Step 1 - Create Validation object

Create a validation resource. From this point the validation will show in the admin dashboard for your company.

Step 2 - Validate the document

In order to validate a document you have to decide which validation method will work best for you.

When uploading the images please note that the maximum supported size for all the images in the validation is currently 4 MB. That is to say the sum of the sizes of all of the images used cannot be over that size.

The response from the submission will give you a status indicating the overall result of the document. These status codes are meant for the customer. For example if you want the customer to always see a successful result then you can configure that using the configuration.

Customer status codes are returned from the validation requests.

Customer Status Codes

  • 0: Error
  • 1: Successfully validated. This does not mean they passed validation but that the OCR was able to read the document and make a decision
  • 2: Inconclusive. If the user has failed the validation passed the max attempts. max attempts is currently unlimited and will be configurable in the future
  • 3: Unreadable. The OCR could not read the required attributes off the front and back of the drivers license. This is constant improvement to reduce blurry results due to real world conditions.

Admin status codes can be retrieved by submitting a get request for a specific validation.

Admin Status Codes 1-5

  • 1: The driver's license was validated and no issues were found
  • 2: One attribute of the driver's license did not match. this can happen from a misread and should be checked by a human
  • 3: The driver's license failed validation. Multiple attributes on the driver's license did not match
  • 4: The owner of the driver's license has not attempted to validate his/her driver's license yet. This is the default status code when a validation is created.
  • 5: The picture of the driver's license was too blurry and could not be read.

Step 3 - Review the validation

Now you can review the validation. A review process ensures that a human has looked at the validation results and confirms the validation was correct. Since the validation uses ocr to recognize values it can sometimes be wrong and should be reviewed by a person.

You have 2 ways to review a validation
  1. You can review a validation in the dashboard by clicking on the validation and then clicking on mark as reviewed.
  2. You can also review the validation pro-grammatically.The dashboard is just calling this route when mark as reviewed is clicked.

Step 4 - Delete the validation

After you are satisfied with your results and want to remove the validation from the admin dashboard then you can delete the validation

Validation notifications

If you pass postBackUrl when creating the validation then the api will make a post request to that url with the validation's information when the document is validated or reviewed. You can configure how the API authenticates with your API using these configuration attributes. Please see the configuration section

  • eventBroadcastAuthentication
  • eventBroadcastHmacPrivateKey
  • eventBroadcastHmacPublicKey