Get Started
This guide will help you get started with Scandit ID Validate. The following verifier is available:
AAMVAVizBarcodeComparisonVerifier
: Validates the authenticity of the document by comparing the data from the VIZ and from the barcode on the back.
Integrating ID Validate into your app follows the same general steps as integrating ID Capture, with some minor differences based on the verifier you choose, as detailed in the following sections.
VIZ Barcode Comparison Verifier
This verifier compares the data from the VIZ (the machine-readable zone) and the barcode on the back of the document and requires the front and back scanning mode.
Create the verifier and initialize IdCapture
with the following settings:
DataCaptureContext context = DataCaptureContext.ForLicenseKey("-- ENTER YOUR SCANDIT LICENSE KEY HERE --");
AamvaVizBarcodeComparisonVerifier verifier = AamvaVizBarcodeComparisonVerifier.Create();
IdCaptureSettings settings = new IdCaptureSettings();
settings.SupportedDocuments = IdDocumentType.DlViz;
settings.SupportedSides = SupportedSides.FrontAndBack;
IdCapture idCapture = IdCapture.Create(context, settings);
Then proceed to capture the front and back sides of a document as usual. After you capture the back side and receive the combined result for both sides, you may run the verifier as follows:
public void OnIdCaptured(IdCapture capture, IdCaptureSession session, IFrameData frameData)
{
CapturedId capturedId = session.NewlyCapturedId;
VizResult viz = captureId.Viz;
if (viz != null && capturedId.Viz.CapturedSides == SupportedSides.FrontAndBack)
{
AamvaVizBarcodeComparisonResult result = verifier.Verify(capturedId);
if (result.ChecksPassed)
{
// Nothing suspicious was detected.
}
else
{
// You may inspect the results of individual checks, if you wish:
if (result.DatesOfBirthMatch.CheckResult == ComparisonCheckResult.Failed)
{
// The holder's date of birth from the front side does not match the one encoded in the barcode.
}
}
}
}
The return value allows you to query both the overall result of the verification and the results of individual checks. See AAMVAVizBarcodeComparisonResult
for details.