Previous Next JavaScript must be enabled to correctly display this content

## 6.4.2 Driving License Validation

This topic provides the information about the payload details for Driving License validation service.

Driving License Details Validation module extracts information present in the Driving License such as Name, First Name, Last Name, Gender, Address, License No, Date of Birth, Date of Issue and Date of expiry of the license along with the image metadata information like Image DPI, Resolution and Size. Then it calculates similarity scores for each input key value pairs with the extracted details. This module provides support for licenses of various countries listed below:

- UNITED STATES OF AMERICA
- UNITED KINGDOM
- CANADA
- AUSTRALIA
- BANGLADESH

All the details in the license are extracted and validated using "/validateInformation" API.

Brief of Working:

It takes "country", "key value pairs to be searched", "input documents" (including "document type" and "Base64 encoded image") of the passport as input. It internally generates processed text from the passport and extracts details like Name, First Name, Last Name, Gender, DOB, DOI and DOE, PP No. and Issuing Authority if present in the document. Along with the document details, it also gives image metadata information like Image DPI, Resolution and Size, etc. Then it calculates similarity scores for each input key value pairs with the extracted details. The output is represented in JSON format.

Input Request:

"/validateInformation" API -

- Country, Array of key value pairs to be searched, Array of the documents (including Base64 encoded image and Document Type ("license" in this case) for each document).

Sample Input Request:

    {
        "country": "US",
        "search": [
            [
                {
                 "key": "------name of key------"
                "value": "------value of key------"
                }
            ]
        ],
        "docs": [
            {
                 "docType": "license",
                 "docBase64s": "------base64 encoded image string------"
            }
        ]
    }

Output Response:

The output of "/validateInformation" API is the extracted details in the JSON format given below:

Sample Output Response:

    {
        "documentDetails": [
            {
                "country": "US",
                "documents": {
                    "document_1": [
                        [
                            {
                                "extractedValue": "JELANI",
                                "key": "firstnAME",
                                "similarityScore": 75.0,
                                "value": "jelani s"
                            },
                            {
                                "extractedValue": "123 MAIN ST PHOENIX, AZ 85007",
                                "key": "ADDress",
                                "similarityScore": 80.0,
                                "value": "787 Main st, phoenix, AZ 85007"
                            },
                            {
                                "extractedValue": "1/1/1974",
                                "key": "dateOfbirth",
                                "similarityScore": 100.0,
                                "value": "1/1/1974"
                            },
                            {
                                "extractedValue": "1/3/2016",
                                "key": "dateOfissue",
                                "similarityScore": 100.0,
                                "value": "03-01-16"
                            },
                            {
                                "extractedValue": "M",
                                "key": "gender",
                                "similarityScore": 100.0,
                                "value": "M"
                            },
                            {
                                "extractedValue": "1/3/2024",
                                "key": "dateOfexpiry",
                                "similarityScore": 0.0,
                                "value": "03/03/24"
                            }
                        ]
                    ]
                }
            }
        ]
    }

Parent topic: Validate Information API details