Skip to main content
Not sure which Scandit product fits your use case?

Install our data-capture-sdk skill so your coding agent can answer questions about Scandit products and recommend the right one for your use case, directly from your editor. More info →

Run this in a terminal in your project directory, then follow the instructions to select your coding agent.

npx skills add https://github.com/scandit/skills --skill data-capture-sdk

Your coding agent loads the skill automatically based on your prompt; to invoke it explicitly, call /data-capture-sdk followed by your task.

Advanced Options

This page covers advanced features and options for ID Bolt that help optimize performance and handle specific use cases.

Keep Alive

Available since version 1.6.

When running ID Bolt multiple times in sequence (such as scanning multiple passports in a batch), you can improve performance by keeping resources alive between sessions:

// first scan
let idBoltSession = IdBoltSession.create(ID_BOLT_URL, {
// other options...
keepAliveForNextSession: true,
});

// second scan

idBoltSession = IdBoltSession.create(ID_BOLT_URL, {
// other options...
keepAliveForNextSession: true,
});

// more scans...

// When finished with all scans
IdBoltSession.terminate();

Benefits

  • Faster loading times for subsequent scans
  • No need to request camera permissions again
  • Reduced resource initialization overhead

Important Notes

  • Always call IdBoltSession.terminate() when done with all scans to release resources
  • This feature is most beneficial when scanning multiple IDs in quick succession

Browser Navigation Control

Available since version 1.14.

By default, ID Bolt closes when users press the browser's back button. You can disable this behavior:

const idBoltSession = IdBoltSession.create(ID_BOLT_URL, {
// other options...
disableCloseOnBrowserBack: true,
});

When to Use

  • When you have custom navigation logic in your application, that interferes with this feature

Default Behavior

When disableCloseOnBrowserBack is false (default), pressing the back button closes the ID Bolt pop-up and triggers the onCancellation callback with CancellationReason.UserClosed.

Transaction Tracking

Available since version 1.17.

You can associate ID Bolt sessions with your internal tracking identifiers for analytics and debugging:

const idBoltSession = IdBoltSession.create(ID_BOLT_URL, {
// other options...
externalTransactionId: "booking-12345", // your booking, order, or transaction ID
});

Benefits

  • Correlate ID Bolt sessions with your business transactions
  • Better analytics and reporting capabilities

Example Use Cases

  • E-commerce: Order IDs
  • Booking systems: Reservation Numbers