Skip to main content
Skip table of contents

Barcode and QR Code Inspection

Barcode & QR Code Inspection

📌 API Reference: https://verify-automation.globalvision.co/reference/createbarcodejob

This feature will identify and grade all barcodes and QR codes in the reference document.

Supported Barcode and QR Code Types

The following 1D barcodes are decoded:

  • Codabar

  • Code 11

  • Code 39

  • Code 128

  • GS1- 128

  • Interleaved 2 of 5

  • MSI

  • Pharma Code (Rotated 0 and 180 degrees decode values)

  • RSS/ GS1 Databar

  • RSS/ GS1 Databar Stacked

  • RSS/ GS1 Databar Limited

  • RSS/ GS1 Databar Expanded

  • RSS/ GS1 Databar Expanded Stacked

  • TelePen

  • EAN (13 Digits)

  • EAN (8 Digits)

  • UPC-A

  • UPC-E

The following 2D barcodes are decoded:

  • Data Matrix

  • GS1 DataMatrix

  • QR

  • Micro QR

Inspection Features (API Input)

You can leverage any of the features below to prepare your inspection:

Feature

API Parameter Example

Document ID (required)

  • Leverage this parameter to inform the ID of the file you want to inspect.

NONE
{
  "documentId": "your_doc_ID"
}

Raster DPI

  • Default value: 300

  • Sets the DPI resolution used when converting documents to images for barcode detection. Higher DPI values improve detection accuracy for small or low-quality barcodes, but may require more processing resources.

CODE
"rasterDpi": 300

Re-Raster DPI

  • Default value: 600

  • Sets the DPI resolution used to regenerate detected barcode images for quality grading.

CODE
"barcodeReRasterDpi": 600

Passing Grade

  • Sets the minimum acceptable grade for barcodes to pass inspection. Barcodes that meet or exceed this grade are marked as passed; those that do not are marked as failed.

  • If this value is not set, all barcodes will be treated as passed by default.

CODE
"passingGrade": "A"

Layers Visibility

  • Configures which layers in a document are visible during the inspection process. This is especially relevant for files that contain multiple or complex layers, such as PDF or design files.

  • By default, all layers are visible.

CODE
"layersVisibility": [
        {
          "name": "layer1",
          "visible": false
        },
        {
          "name": "layer2",
          "visible": false
        }
      ]

Separations to Hide

  • Lists the names of separations (inks) to hide during inspection. Use this to exclude specific color channels from the inspection process.

  • This is useful for focusing on certain inks (e.g., black) or removing distracting elements from the inspection.

CODE
      "separationsToHide": [
        "separation1",
        "separation2"
      ]

Shape to Selected Layer

  • Defines an object for cropping the inspection region based on a selected layer's shape.

  • All visible layers within this area will be included in the inspection, allowing you to focus the analysis on specific zones of interest.

CODE
"shapeTo": {
    "selectedLayerName": "layer1"
      }

Shape to Selected Separation

  • Specifies the name of a separation (ink) whose shape is used to crop the inspection region.

  • All visible content within the area covered by this separation will be inspected.

CODE
"shapeTo": {
    "selectedSeparationName": "separation1"
      }

PDF Box Type

  • Sets the PDF box used to crop the document for inspection.

  • Options are: CropBox, MediaBox, BleedBox, TrimBox, and ArtBox.

  • Choosing the appropriate box helps focus the inspection on the desired content area and can improve accuracy by excluding irrelevant margins or marks.

CODE
"pdfBoxType": "CropBox"

Report Type

  • Determines the format and content of the PDF inspection report.

  • Options:

    • default: Includes summary, thumbnails, and annotated report.

    • summaryAnnotated: Includes only the summary and annotated report (no thumbnails).

CODE
"reportType": "default"

Inspection Results (API Output)

The official output of this API endpoint will be the Job ID. Use this ID to access all the inspection details described below.

Inspection Result

API Output Example

Report URL

  • Link to the generated PDF inspection report.

  • The content of this report is determined by the reportType parameter.

CODE
"reportUrl": "https://verify-automation-api.globalvision.co/files/automation-report?fileKey=PDF_File_Key"

XFDF Reports

  • Links to XFDF annotation files for both master and sample documents (if available), which can be used for further integration with PDF viewers or automated review systems.

CODE
"xfdfReports": {
                "master": null,
                "sample": "https://verify-automation-api.globalvision.co/files/automation-report?fileKey=XFDF_File_key"
                {

Barcode Decoding

  • Each entry in the barcodes array includes:

    • barcodeType and barcodeSubtype: The type and specific format of the barcode detected (see your "Supported Barcode Types" parameter).

    • decoded: The value/data read from the barcode.

CODE
"decoding": {
               "barcodeSubtype": "Code 128",
               "barcodeType": "Linear",
               "decoded": "GVE-gvd-15146244422"
           }

Barcode Grading

Overall Grade

  • Shown as overall.letter and overall.statusDescription. This is compared against the passingGrade you may have set.

  • status: Indicates whether each metric or the barcode overall is a pass or fail, factoring in all grading criteria.

CODE
"overall": {
               "letter": "A",
                "normalized": 4,
                "status": "A",
                "statusDescription": "High reliability in most environments."
             }

Barcode Grading

Individual Metrics

  • Each barcode is assessed on numerous quality parameters (e.g., decodability, symbol contrast, modulation, quiet zone, etc.), often reported as both a numeric value and a grade (e.g., "A" for best, down to "F").

  • status: Indicates whether each metric or the barcode overall is a pass or fail, factoring in all grading criteria.

CODE
"grading": {
                "barWidthReduction": {
                "absolute": -0.01,
                "status": "Pass",
                "statusDescription": "",
                "unit": "Millimeter"
           },
                "decodability": {
                "absolute": 62,
                "letter": "A",
                "normalized": 4,
                "status": "A",
                "statusDescription": "",
                "unit": "Percentage"
           },
                "quietZone": {
                "left": {
                "absolute": 0.29,
                "letter": "F",
                "normalized": 0,
                "unit": "Millimeter"
           }
      }

Barcode Inspection Summary

  • barcodeInspectedAmount:
    The total number of barcodes inspected in this document.

  • barcodePassedGrading:
    Boolean indicating if all barcodes passed the grading criteria (as set by your passingGrade parameter).

CODE
"barcodeInspectedAmount": 2,
"barcodePassedGrading": true

Location Information

  • Specifies where on the page the barcode was found:

    • boundingBox (coordinates),

    • cornerPoints (detailed points for shape),

    • pageNumber.

CODE
"location": {
                "boundingBox": {
                "bottom": 541.2,
                "left": 805.2,
                "right": 955.44,
                "top": 523.2
            }
                "pageNumber": 1
      }
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.