Skip to main content

Data Handling

ID Bolt provides options to control what data is returned from scanned documents and how sensitive information is handled, allowing you to balance functionality with privacy requirements.

Return Data Mode

The returnDataMode option controls the extent of data returned by the onCompletion() callback:

const idBoltSession = IdBoltSession.create(ID_BOLT_URL, {
// other options...
returnDataMode: ReturnDataMode.Full
});

Available Modes

ValueDescription
ReturnDataMode.FullAll extracted data is returned, but images are excluded
ReturnDataMode.FullWithImagesAll extracted data is returned, including images of the scanned ID

Choosing the Right Mode

  • Use ReturnDataMode.Full when you need the extracted data but don't require images
  • Use ReturnDataMode.FullWithImages when you need visual verification or need to store images for compliance purposes

When using FullWithImages, be aware that the response will be larger due to the base64-encoded image data.

Anonymization Mode

Some countries have specific requirements for the anonymization of documents. ID Bolt can be configured to protect sensitive fields and obscure them in result images:

const idBoltSession = IdBoltSession.create(ID_BOLT_URL, {
// other options...
anonymizationMode: AnonymizationMode.FieldsOnly
});

Available Modes

ValueDescription
AnonymizationMode.NoneNo anonymization is applied (default)
AnonymizationMode.FieldsOnlyOnly fields (data) are anonymized
AnonymizationMode.ImagesOnlyOnly images are anonymized
AnonymizationMode.FieldsAndImagesBoth fields and images are anonymized

Effects of Anonymization

  • Fields Anonymization: Sensitive fields are not extracted from documents
  • Image Anonymization: Black boxes cover sensitive data in result images

When image anonymization is enabled (ImagesOnly or FieldsAndImages), and ReturnDataMode.FullWithImages is used, full-frame images will not be returned. Cropped images will still be available but with sensitive areas obscured.