On this page

Stuck? Open a support ticket and the barKoder team will help. Open a ticket

NativeScript API reference

Every method, setting, enum and result of the barKoder NativeScript SDK, grouped by what you do with it.

This page will explain all available methods and configuration settings of the barKoder Barcode Scanner SDK for NativeScript.

Scanning & session #

startScanning #

Starts scanning for barcodes.

Parameters:

BarkoderResultCallback: The callback that will handle barcode scanning events.

Syntax:

TypeScript
startScanning(BarkoderResultCallback : BarkoderConstants.BarkoderResultCallback) : void

stopScanning #

Stops the barcode scanning process.

Syntax:

TypeScript
stopScanning() : void

pauseScanning #

Pauses the barcode scanning process.

Syntax:

TypeScript
pauseScanning() : void

setLicenseKey #

Set your actual license key provided by the plugin.

Parameters:

licenseKey: license key.

Syntax:

TypeScript
setLicenseKey(licenseKey : string) : void

setDecodingSpeed #

Sets the decoding speed for barcode scanning.

Parameters:

decodingSpeed: The decoding speed to be set.

Syntax:

TypeScript
setDecodingSpeed(decodingSpeed : BarkoderConstants.DecodingSpeed) : void

setThreadsLimit #

Set the threads limit.

Parameters:

threadsLimit: The threads limit.

Syntax:

TypeScript
setThreadsLimit(threadsLimit : number) : void

configureBarkoder #

Set the config for a Barkoder.

Syntax:

TypeScript
configureBarkoder(config: BarkoderConstants.BarkoderConfig): void

getVersion #

Gets barKoder SDK version.

Syntax:

TypeScript
getVersion() : any

getDecodingSpeed #

Get the decoding speed for barcode scanning.

Syntax:

TypeScript
getDecodingSpeed() : any

getMsiCheckSumType #

Get the checksum type for MSI barcodes.

Syntax:

TypeScript
getMsiCheckSumType() : any

getCode11CheckSumType #

Get the checksum type for Code 11 barcodes.

Syntax:

TypeScript
getCode11CheckSumType() : any

getCode39CheckSumType #

Get the checksum type for Code 39 barcodes.

Syntax:

TypeScript
getCode39CheckSumType() : any

getThreadsLimit #

Get the threads limit.

Syntax:

TypeScript
getThreadsLimit() : any

freezeScanning #

Freezes the current AR scanning session by capturing a still image from the camera feed. Use only when AR mode is enabled to temporarily freeze the view while keeping overlays visible.

Syntax:

TypeScript
freezeScanning()

unfreezeScanning #

Unfreezes the AR scanning session by removing the still image and reactivating the camera and overlays. Use only when AR mode is enabled to restore the live AR view and continue scanning.

Syntax:

TypeScript
unfreezeScanning()

setUPCEexpandToUPCA #

TypeScript
▸ setUPCEexpandToUPCA(enabled): void

Sets whether the UPC-E barcodes should be expanded to UPC-A format.

Parameters:

NameType
enabledboolean

setUPCE1expandToUPCA #

TypeScript
▸ setUPCE1expandToUPCA(enabled): void

Sets whether the UPC-E1 barcodes should be expanded to UPC-A format.

Parameters:

NameType
enabledboolean

setPowerSavingMode #

TypeScript
▸ setPowerSavingMode(powerSavingMode): void

Power saving mode level. Higher values reduce CPU/battery usage by limiting frame processing.

Default value is 0.
0 - Disabled (full performance)
1 - Light saving
2 - Medium saving
3 - High saving
4 - Maximum saving

Parameters:

NameType
powerSavingModenumber

setVideoStabilization #

TypeScript
▸ setVideoStabilization(value): void

Enable or disable video stabilization for smoother video capture.

Parameters:

NameType
valueboolean

unfreezeScanning #

TypeScript
▸ unfreezeScanning(): void

Unfreezes the AR scanning session by removing the still image and reactivating the camera and overlays. Use only when AR mode is enabled to restore the live AR view and continue scanning.

selectVisibleBarcodes #

Selects all barcodes that are currently visible in AR mode.

Syntax:

TypeScript
selectVisibleBarcodes()

setDynamicExposure #

Sets the camera's exposure dynamically based on the provided intensity, cycling through predefined compensation values.

Parameters:

  • value: The integer value for the exposure intensity.

Syntax:

TypeScript
setDynamicExposure(int exposure)

setVideoStabilization #

Enable or disable video stabilization for smoother video capture.

Parameters:

  • value: A boolean indicating whether video stabilization should be enabled/disabled.

Syntax:

TypeScript
setVideoStabilization(BarkoderCameraPosition barkoderCameraPosition)

getPowerSavingMode #

TypeScript
▸ getPowerSavingMode()

Retrieves the power saving mode level.

Models, #

DecodingSpeed #

TypeScript
export enum DecodingSpeed {
  Fast = 0,
  Normal = 1,
  Slow = 2
}

Camera #

startCamera #

Starts the camera for barcode scanning.

Syntax:

TypeScript
startCamera() : void

setFlashEnabled #

Sets the flash (torch) on or off for barcode scanning.

Parameters:

enabled: True to enable the flash, false to disable it.

Syntax:

TypeScript
setFlashEnabled(enabled : boolean) : void

setZoomFactor #

Sets the zoom factor for the camera used in barcode scanning.

Parameters:

zoomFactor: The zoom factor to set.

Syntax:

TypeScript
setZoomFactor(zoomFactor : number) : void

setPinchToZoomEnabled #

Enables or disables pinch-to-zoom functionality for the camera used in barcode scanning.

Parameters:

enabled: True to enable pinch-to-zoom, false to disable it.

Syntax:

TypeScript
setPinchToZoomEnabled(enabled : boolean) : void

setLocationInPreviewEnabled #

Enables or disables displaying the barcode location in the camera preview.

Parameters:

enabled: True to display the location, false to hide it.

Syntax:

TypeScript
setLocationInPreviewEnabled(enabled : boolean) : void

setBarkoderResolution #

Sets the resolution for barcode scanning.

Parameters:

barkoderResolution: The barkoder resolution to be set.

Syntax:

TypeScript
setBarkoderResolution(barkoderResolution : BarkoderConstants.BarkoderResolution) : void

isFlashAvailable #

Get a value indicating whether the flash is available.

Syntax:

TypeScript
isFlashAvailable(callback : BarkoderConstants.FlashAvailableCallback): Promise<boolean>

getMaxZoomFactor #

Get the maximum zoom factor

Syntax:

TypeScript
getMaxZoomFactor(callback : BarkoderConstants.MaxZoomAvailableCallback): Promise<number>

isLocationInPreviewEnabled #

Get a value indicating whether the location is displayed in the camera preview.

Syntax:

TypeScript
isLocationInPreviewEnabled() : any

isPinchToZoomEnabled #

Get a value indicating whether pinch-to-zoom functionality is enabled.

Syntax:

TypeScript
isPinchToZoomEnabled() : any

getBarkoderResolution #

Get the resolution for barcode scanning.

Syntax:

TypeScript
getBarkoderResolution() : any

setCamera #

TypeScript
▸ setCamera(value): void

Parameters:

NameType
valuenumber

setCentricFocusAndExposure #

Selects all barcodes that are currently visible in AR mode.

Parameters:

value: A boolean indicating whether the center of the viewfinder should be used.

Syntax:

TypeScript
setCentricFocusAndExposure(boolean enabled)

setCamera #

Sets the camera to be used for scanning (back/front).

Parameters:

  • value: The value which camera should be used.

Syntax:

TypeScript
setCamera(BarkoderCameraPosition barkoderCameraPosition)

BarkoderResolution #

TypeScript
export enum BarkoderResolution {
  NORMAL = 'HD',
  HIGH = 'Full HD'
}

Barcode types #

setFormattingType #

Sets the formatting type for barcode scanning.

Parameters:

formattingType: The formatting type to be set.

Syntax:

TypeScript
setFormattingType(formattingType : BarkoderConstants.FormattingType) : void

setMsiChecksumType #

Sets the checksum type for MSI barcodes.

Parameters:

msiChecksumType: The MSI checksum type to be set.

Syntax:

TypeScript
setMsiChecksumType(msiCheckSumType : BarkoderConstants.MsiCheckSumType) : void

setCode11ChecksumType #

Sets the checksum type for Code 11 barcodes.

Parameters:

code11ChecksumType: The Code 11 checksum type to be set.

Syntax:

TypeScript
setCode11ChecksumType(code11CheckSumType : BarkoderConstants.Code11CheckSumType) : void

setCode39ChecksumType #

Sets the checksum type for Code 39 barcodes.

Parameters:

code39ChecksumType: The Code 39 checksum type to be set.

Syntax:

TypeScript
setCode39ChecksumType(code39ChecksumType : BarkoderConstants.Code39CheckSumType) : void

setEncodingCharacterSet #

Sets the encoding character set for barcode scanning.

Parameters:

encodingCharacterSet: The encoding character set to be set.

Syntax:

TypeScript
setEncodingCharacterSet(encodingCharSet : string) : void

setDatamatrixDpmModeEnabled #

Enables or disables the (DPM) mode for Datamatrix barcodes.

Parameters:

enabled: True to enable DPM mode, false to disable it.

Syntax:

TypeScript
setDatamatrixDpmModeEnabled(enabled : boolean) : void

setUpcEanDeblurEnabled #

Enables or disables deblurring for UPC/EAN barcodes.

Parameters:

enabled: True to enable deblurring, false to disable it.

Syntax:

TypeScript
setUpcEanDeblurEnabled(enabled : boolean) : void

setEnableMisshaped1DEnabled #

Enables or disables the decoding of misshaped 1D barcodes.

Parameters:

enabled: True to enable decoding, false to disable it.

Syntax:

TypeScript
setEnableMisshaped1DEnabled(enabled : boolean) : void

setBarcodeTypeEnabled #

Enable the specified barcode types for scanning.

Parameters:

Syntax:

TypeScript
setBarcodeTypeEnabled(decoders: BarkoderConstants.DecoderType[]): void

setEnableVINRestrictions #

Sets whether Vehicle Identification Number (VIN) restrictions are enabled for scanning.

Parameters:

enabled: True to enable VIN restrictions, false to disable them.

Syntax:

TypeScript
setEnableVINRestrictions(enabled: boolean) : void

isBarcodeTypeEnabled #

Checks if a specific barcode type is enabled.

Parameters:

barcode: The barcode type to check.

Syntax:

TypeScript
isBarcodeTypeEnabled(decoder: BarkoderConstants.DecoderType) : boolean

setBarcodeTypeLengthRange #

Sets the length range for a specified barcode type.

Parameters:

decoder: The type of barcode.minimumLength: The minimum length of the barcode.maximumLength: The maximum length of the barcode.

Syntax:

TypeScript
setBarcodeTypeLengthRange(decoder: BarkoderConstants.DecoderType, minimumLength: number, maximumLength: number) : void

getEncodingCharacterSet #

Get the character set used for encoding.

Syntax:

TypeScript
getEncodingCharacterSet() : any

getFormattingType #

Get the formatting type for barcode scanning.

Syntax:

TypeScript
getFormattingType() : any

isUpcEanDeblurEnabled #

Get a value indicating whether deblurring is enabled for UPC/EAN barcodes.

Syntax:

TypeScript
isUpcEanDeblurEnabled() : any

isMisshaped1DEnabled #

Get a value indicating whether decoding of misshaped 1D barcodes is enabled.

Syntax:

TypeScript
isMisshaped1DEnabled() : any

isVINRestrictionsEnabled #

Get a value indicating whether Vehicle Identification Number (VIN) restrictions are enabled for scanning.

Syntax:

TypeScript
isVINRestrictionsEnabled() : any

setCustomOption #

TypeScript
▸ setCustomOption(string, int`): void

Setting custom option.

Parameters:

NameType
stringString
intnumber

setEnableComposite #

TypeScript
▸ setEnableComposite(value): void

Parameters:

NameType
valuenumber

setIdDocumentMasterChecksumEnabled #

TypeScript
▸ setIdDocumentMasterChecksumEnabled(enabled): void

Parameters:

NameType
enabledboolean

setQrDpmModeEnabled #

TypeScript
▸ setQrDpmModeEnabled(enabled): void

Parameters:

NameType
enabledboolean

setQrMicroDpmModeEnabled #

TypeScript
▸ setQrMicroDpmModeEnabled(enabled): void

Parameters:

NameType
enabledboolean

setQrMultiPartMergeEnabled #

TypeScript
▸ setQrMultiPartMergeEnabled(enabled): void

Parameters:

NameType
enabledboolean

setDecoderMatchFilter #

Defines which barcode results the scanner should return as matches.

Parameters:

  • value: A string value that the barcode must match.
TypeScript
setDecoderMatchFilter(value : String)

isIdDocumentMasterChecksumEnabled #

TypeScript
▸ isIdDocumentMasterChecksumEnabled()

Retrieves whether Master checksum is enabled when scanning ID Documents.

isQrDpmModeEnabled #

TypeScript
▸ isQrDpmModeEnabled()

Retrieves whether Direct Part Marking (DPM) mode for QR barcodes is enabled.

isQrMicroDpmModeEnabled #

TypeScript
▸ isQrMicroDpmModeEnabled()

Retrieves whether Direct Part Marking (DPM) mode for QR Micro barcodes is enabled.

isQrMultiPartMergeEnabled #

TypeScript
▸ isQrMultiPartMergeEnabled()

Retrieves whether the QR multi-part merge mode is enabled.

DecoderType #

Represents the types of barcodes that are supported by barKoder.

TypeScript
export enum DecoderType {
  Aztec = 0,
  AztecCompact = 1,
  QR = 2,
  QRMicro = 3,
  Code128 = 4,
  Code93 = 5,
  Code39 = 6,
  Codabar = 7,
  Code11 = 8,
  Msi = 9,
  UpcA = 10,
  UpcE = 11,
  UpcE1 = 12,
  Ean13 = 13,
  Ean8 = 14,
  PDF417 = 15,
  PDF417Micro = 16,
  Datamatrix = 17,
  Code25 = 18,
  Interleaved25 = 19,
  ITF14 = 20,
  IATA25 = 21,
  Matrix25 = 22,
  Datalogic25 = 23,
  COOP25 = 24,
  Code32 = 25,
  Telepen = 26,
  Dotcode = 27,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39,
  IDDocument = 28,
  Databar14 = 29,
  DatabarLimited = 30,
  DatabarExpanded = 31,
  PostalIMB = 32,
  Postnet = 33,
  Planet = 34,
  AustralianPost = 35,
  RoyalMail = 36,
  KIX = 37,
  JapanesePost = 38,
  MaxiCode = 39
}

FormattingType #

TypeScript
export enum FormattingType {
  Disabled = 0,
  Automatic = 1,
  GS1 = 2,
  AAMVA = 3,
    SADL = 4, BCBP = 5
}

Code11ChecksumType #

TypeScript
export enum Code11ChecksumType {
  Disabled = 0,
  Single = 1,
  Double = 2
}

Code39ChecksumType #

TypeScript
export enum Code39ChecksumType {
  Disabled = 0,
  Enabled = 1
}

MsiChecksumType #

TypeScript
export enum MsiChecksumType {
  Disabled = 0,
  Mod10 = 1,
  Mod11 = 2,
  Mod1010 = 3,
  Mod1110 = 4,
  Mod11IBM = 5,
  Mod1110IBM = 6
}

Results #

setCloseSessionOnResultEnabled #

Sets whether the session should be closed upon detecting a result during barcode scanning.

Parameters:

enabled: True to close the session on result detection, false otherwise

Syntax:

TypeScript
setCloseSessionOnResultEnabled(enabled : boolean) : void

setImageResultEnabled #

Enables or disables the display of image results during barcode scanning.

Parameters:

enabled: True to enable image result display, false to disable it.

Syntax:

TypeScript
setImageResultEnabled(enabled : boolean) : void

setBeepOnSuccessEnabled #

Enables or disables the beep sound on successful barcode scanning.

Parameters:

enabled: True to enable beep sound, false to disable it.

Syntax:

TypeScript
setBeepOnSuccessEnabled(enabled : boolean) : void

setVibrateOnSuccessEnabled #

Enables or disables the vibration on successful barcode scanning.

Parameters:

enabled: True to enable vibration, false to disable it.

Syntax:

TypeScript
setVibrateOnSuccessEnabled(enabled : boolean) : void

setBarcodeThumbnailOnResultEnabled #

Enables or disables the display of barcode thumbnails in the scan results.

Parameters:

enabled: True to enable barcode thumbnails, false to disable them.

Syntax:

TypeScript
setBarcodeThumbnailOnResultEnabled(enabled : boolean) : void

setMaximumResultsCount #

Sets the maximum number of results to be returned from barcode scanning.

Parameters:

maximumResultsCount: The maximum number of results to return.

Syntax:

TypeScript
setMaximumResultsCount(maximumResultsCount : number): void

setThresholdBetweenDuplicatesScans #

Sets the threshold between duplicate scans in milliseconds.

Parameters:

thresholdBetweenDuplicatesScans: The threshold between duplicate scans in milliseconds.

Syntax:

TypeScript
setThresholdBetweenDuplicatesScans(thresholdBetweenDuplicatesScans : number) : void

setMulticodeCachingDuration #

Set the multicode caching duration.

Parameters:

multicodeCachingDuration: multicode caching duration.

Syntax:

TypeScript
setMulticodeCachingDuration(multicodeCachingDuration : number) : void

setMulticodeCachingEnabled #

Set the multicode caching enabled.

Parameters:

multiCodeCachingEnabled: multicode caching enabled.

Syntax:

TypeScript
setMulticodeCachingEnabled(multiCodeCachingEnabled : boolean) : void

getMulticodeCachingEnabled #

Get the multicode caching is enabled.

Syntax:

TypeScript
getMulticodeCachingEnabled() : any

getMulticodeCachingDuration #

Get the multicode caching duration.

Syntax:

TypeScript
getMulticodeCachingDuration() : any

isImageResultEnabled #

Get a value indicating whether image results are enabled.

Syntax:

TypeScript
isImageResultEnabled() : any

isBeepOnSuccessEnabled #

Get a value indicating whether a beep sound is played on successful barcode scanning.

Syntax:

TypeScript
isBeepOnSuccessEnabled() : any

isVibrateOnSuccessEnabled #

Get a value indicating whether vibration is enabled on successful barcode scanning.

Syntax:

TypeScript
isVibrateOnSuccessEnabled() : any

isCloseSessionOnResultEnabled #

Get a value indicating whether the session is closed upon detecting a result during barcode scanning.

Syntax:

TypeScript
isCloseSessionOnResultEnabled() : any

isBarcodeThumbnailOnResultEnabled #

Get a value indicating whether barcode thumbnails are enabled in the scan results.

Syntax:

TypeScript
isBarcodeThumbnailOnResultEnabled() : any

getMaximumResultsCount #

Get the maximum number of results to be returned from barcode scanning.

Syntax:

TypeScript
getMaximumResultsCount() : any

getThresholdBetweenDuplicatesScans #

Get the threshold between duplicate scans in seconds.

Syntax:

TypeScript
getThresholdBetweenDuplicatesScans() : any

captureImage #

Captures the latest camera frame.

Syntax:

TypeScript
captureImage()

scanImage #

Scan from base64 image string.

Parameters:

base64: String.

resultsCallback: ResultCalllBack.

Syntax:

TypeScript
scanImage(base64, resultsCallback)

setResultDisappearanceDelayMs #

TypeScript
▸ setResultDisappearanceDelayMs(value): void

Parameters:

NameType
valuenumber

setShowDuplicatesLocations #

TypeScript
▸ setShowDuplicatesLocations(value): void

Enables or disables showing duplicate barcode locations on the preview overlay.

Parameters:

NameType
valueboolean

getResultDisappearanceDelayMs #

TypeScript
▸ getResultDisappearanceDelayMs()

Retrieves the delay after which AR results disappear once detected.

getShowDuplicatesLocations #

TypeScript
▸ getShowDuplicatesLocations()

Retrieves whether showing duplicate barcode locations in the AR view is enabled.

BarkoderResultCallback #

Represents a callback for handling barcode scanning events. Called when barcode scanning has finished.

CSS
export interface BarkoderResultCallback {
  scanningFinished(results: any[], thumbnails: any[], resultImage: any): void;
}

Results

  • textualData: The textual data encoded in the barcode.
  • barcodeTypeName: The type name of the barcode.
  • characterSet: The character set used in encoding the barcode.

Region & overlay #

setRegionOfInterestVisible #

Sets the visibility of the region of interest (ROI) overlay for barcode scanning.

Parameters:

visible: True to make the ROI visible, false to hide it.

Syntax:

TypeScript
setRegionOfInterestVisible(visible : boolean) : void

setLocationInImageResultEnabled #

Enables or disables displaying the barcode location in the image result.

Parameters:

enabled: True to display the location, false to hide it.

Syntax:

TypeScript
setLocationInImageResultEnabled(enabled : boolean) : void

setLocationLineColor #

Sets the color of the line indicating the barcode location in the camera preview.

Parameters:

hexColor: The hexadecimal representation of the color.

Syntax:

TypeScript
setLocationLineColor(hexColor : string) : void

setLocationLineWidth #

Sets the width of the line indicating the barcode location in the camera preview.

Parameters:

width: The width representation of the location line.

Syntax:

TypeScript
setLocationLineWidth(width : number) : void

setRoiLineColor #

Sets the color of the line indicating the region of interest (ROI) in the camera preview.

Parameters:

hexColor: The hexadecimal representation of the color.

Syntax:

TypeScript
setRoiLineColor(hexColor : string) : void

setRoiLineWidth #

Sets the width of the line indicating the region of interest (ROI) in the camera preview.

Parameters:

roiLineWidth: The number representation of the width.

Syntax:

TypeScript
setRoiLineWidth(roiLineWidth : number) : void

setRoiOverlayBackgroundColor #

Sets the background color of the region of interest (ROI) overlay in the camera preview.

Parameters:

hexColor: The hexadecimal representation of the color.

Syntax:

TypeScript
setRoiOverlayBackgroundColor(hexColor : string) : void

setRegionOfInterest #

Sets the region of interest (ROI) for barcode scanning within the camera preview.

Parameters:

left: The left coordinate of the ROI.top: The top coordinate of the ROI.width: The width of the ROI.height: The height of the ROI.

Syntax:

TypeScript
setRegionOfInterest(left : number, top : number, width : number, height : number) : void

getRegionOfInterest #

Gets or sets a value indicating whether the region of interest (ROI) overlay is visible.

Syntax:

TypeScript
getRegionOfInterest() : any

getLocationLineColorHex #

Get the hexadecimal representation of the location line color

Syntax:

TypeScript
getLocationLineColorHex() : any

getRoiLineColor #

Get the hexadecimal representation of the region of interest (ROI) line color.

Syntax:

TypeScript
getRoiLineColor() : any

getRoiOverlayBackgroundColorHex #

Get the hexadecimal representation of the region of interest (ROI) overlay background color.

Syntax:

TypeScript
getRoiOverlayBackgroundColorHex() : any

getLocationLineWidth #

Get the width of the location line.

Syntax:

TypeScript
getLocationLineWidth() : any

getRoiLineWidth #

Get the width of the region of interest (ROI) line.

Syntax:

TypeScript
getRoiLineWidth() : any

isLocationInImageResultEnabled #

Get a value indicating whether the location is displayed in image results.

Syntax:

TypeScript
isLocationInImageResultEnabled() : any

setScanningIndicatorAlwaysVisible #

TypeScript
▸ setScanningIndicatorAlwaysVisible(value): void

Parameters:

NameType
valueboolean

setScanningIndicatorColor #

TypeScript
▸ setScanningIndicatorColor(value): void

Parameters:

NameType
hexColorString

setScanningIndicatorWidth #

TypeScript
▸ setScanningIndicatorWidth(lineWidth): void

Parameters:

NameType
lineWidthnumber

setScanningIndicatorAnimation #

TypeScript
▸ setScanningIndicatorAnimation(animation): void

Parameters:

NameType
animationnumber

getScanningIndicatorColorHex #

TypeScript
▸ getScanningIndicatorColorHex()

Retrieves the hexadecimal color code representing the line color of the scanning indicator on the camera preview.

getScanningIndicatorWidth #

TypeScript
▸ getScanningIndicatorWidth()

Retrieves the current width setting for the scanning indicator on the camera preview.

getScanningIndicatorAnimation #

TypeScript
▸ getScanningIndicatorAnimation()

Retrieves the current animation setting for the scanning indicator on the camera preview.

isScanningIndicatorAlwaysVisible #

TypeScript
▸ isScanningIndicatorAlwaysVisible()

Retrieves if the scanning indicator is set to be always visible on the camera preview.

setBarkoderRoiCenterMark #

Sets the center mark displayed in the scanner's Region of Interest (ROI). The barcode scanner will scan only within the ROI, with the selected center mark indicating the center of the scanning area.

TypeScript
setBarkoderRoiCenterMark(barkoderRoiCenterMark: BarkoderRoiCenterMark)

getBarkoderRoiCenterMark #

Returns the currently configured ROI center mark.

TypeScript
getBarkoderRoiCenterMark() : BarkoderRoiCenterMark

BarkoderRoiCenterMark #

TypeScript
export enum BarkoderRoiCenterMark {
  POINT = 0,
  CROSSHAIR = 1,
  NONE = 2
}

AR mode #

setBarkoderARMode #

TypeScript
▸ setBarkoderARMode(value): void

Sets the AR mode used for barcode scanning visualization.

Parameters:

NameType
valueBarkoderARMode

setARLocationTransitionSpeed #

TypeScript
▸ setARLocationTransitionSpeed(value): void

Parameters:

NameType
valuenumber

setAROverlayRefresh #

TypeScript
▸ setAROverlayRefresh(value): void

Parameters:

NameType
valueBarkoderAROverlayRefresh

setARSelectedLocationColor #

TypeScript
▸ setARSelectedLocationColor(value): void

Parameters:

NameType
hexColorstring

setARNonSelectedLocationColor #

TypeScript
▸ setARNonSelectedLocationColor(value): void

Parameters:

NameType
hexColorstring

setARSelectedLocationLineWidth #

TypeScript
▸ setARSelectedLocationLineWidth(value): void

Parameters:

NameType
valuenumber

setARNonSelectedLocationLineWidth #

TypeScript
▸ setARNonSelectedLocationLineWidth(value): void

Parameters:

NameType
valuenumber

setARLocationType #

TypeScript
▸ setARLocationType(value): void

Parameters:

NameType
valueBarkoderARLocationType

setARDoubleTapToFreezeEnabled #

TypeScript
▸ setARDoubleTapToFreezeEnabled(enabled): void

Parameters:

NameType
enabledboolean

setARImageResultEnabled #

TypeScript
▸ setARImageResultEnabled(enabled): void

Parameters:

NameType
enabledboolean

setARBarcodeThumbnailOnResultEnabled #

TypeScript
▸ setARBarcodeThumbnailOnResultEnabled(enabled): void

Parameters:

NameType
enabledboolean

setARResultLimit #

TypeScript
▸ setARResultLimit(value): void

Parameters:

NameType
valuenumber

setARContinueScanningOnLimit #

TypeScript
▸ setARContinueScanningOnLimit(value): void

Parameters:

NameType
valueboolean

setAREmitResultsAtSessionEndOnly #

TypeScript
▸ setAREmitResultsAtSessionEndOnly(value): void

Parameters:

NameType
valueboolean

setARHeaderHeight #

TypeScript
▸ setARHeaderHeight(value): void

Parameters:

NameType
valuenumber

setARHeaderShowMode #

TypeScript
▸ setARHeaderShowMode(value): void

Parameters:

NameType
valueBarkoderARHeaderShowMode

setARHeaderMaxTextHeight #

TypeScript
▸ setARHeaderMaxTextHeight(value): void

Parameters:

NameType
valuenumber

setARHeaderMinTextHeight #

TypeScript
▸ setARHeaderMinTextHeight(value): void

Parameters:

NameType
valuenumber

setARHeaderTextColorSelected #

TypeScript
▸ setARHeaderTextColorSelected(value): void

Parameters:

NameType
hexColorstring

setARHeaderTextColorNonSelected #

TypeScript
▸ setARHeaderTextColorNonSelected(value): void

Parameters:

NameType
hexColorstring

setARHeaderHorizontalTextMargin #

TypeScript
▸ setARHeaderHorizontalTextMargin(value): void

Parameters:

NameType
valuenumber

setARHeaderVerticalTextMargin #

TypeScript
▸ setARHeaderVerticalTextMargin(value): void

Parameters:

NameType
valuenumber

setARHeaderTextFormat #

TypeScript
▸ setARHeaderTextFormat(value): void

Parameters:

NameType
valuestring

getBarkoderARMode #

TypeScript
▸ getBarkoderARMode()

Retrieves the current AR mode used for barcode scanning.

getARLocationTransitionSpeed #

TypeScript
▸ getARLocationTransitionSpeed()

Retrieves the transition speed for AR barcode location overlays.

getAROverlayRefresh #

TypeScript
▸ getAROverlayRefresh()

Retrieves the AR overlay refresh mode.

getARSelectedLocationColor #

TypeScript
▸ getARSelectedLocationColor()

Retrieves the color used for selected barcode overlays in AR mode.

getARNonSelectedLocationColor #

TypeScript
▸ getARNonSelectedLocationColor()

Retrieves the color used for non-selected barcode overlays in AR mode.

getARSelectedLocationLineWidth #

TypeScript
▸ getARSelectedLocationLineWidth()

Retrieves the line width for selected barcode overlays in AR mode.

getARNonSelectedLocationLineWidth #

TypeScript
▸ getARNonSelectedLocationLineWidth()

Retrieves the line width for non-selected barcode overlays in AR mode.

getARLocationType #

TypeScript
▸ getARLocationType()

Retrieves the style of AR location overlays (tight, bounding box, none).

getARResultLimit #

TypeScript
▸ getARResultLimit()

Retrieves the maximum number of results allowed in a single AR scanning session.

getARContinueScanningOnLimit #

TypeScript
▸ getARContinueScanningOnLimit()

Retrieves whether scanning continues when the result limit is reached (only in .interactiveDisabled mode).

getAREmitResultsAtSessionEndOnly #

TypeScript
▸ getAREmitResultsAtSessionEndOnly()

Retrieves whether results are emitted only at AR session end (or when the limit is reached).

getARHeaderHeight #

TypeScript
▸ getARHeaderHeight()

Retrieves the header height above barcode in AR mode.

getBarkoderARHeaderShowMode #

TypeScript
▸ getBarkoderARHeaderShowMode()

Retrieves the header display mode (always, on selected, never).

getARHeaderMaxTextHeight #

TypeScript
▸ getARHeaderMaxTextHeight()

Retrieves the maximum text height for AR headers.

getARHeaderMinTextHeight #

TypeScript
▸ getARHeaderMinTextHeight()

Retrieves the minimum text height for AR headers.

getARHeaderTextColorSelected #

TypeScript
▸ getARHeaderTextColorSelected()

Retrieves the header text color for selected barcodes.

getARHeaderTextColorNonSelected #

TypeScript
▸ getARHeaderTextColorNonSelected()

Retrieves the header text color for non-selected barcodes.

getARHeaderHorizontalTextMargin #

TypeScript
▸ getARHeaderHorizontalTextMargin()

Retrieves the horizontal margin for AR header text.

getARHeaderVerticalTextMargin #

TypeScript
▸ getARHeaderVerticalTextMargin()

Retrieves the vertical margin for AR header text.

getARHeaderTextFormat #

TypeScript
▸ getARHeaderTextFormat()

Retrieves the format string used for AR header text.

isARDoubleTapToFreezeEnabled #

TypeScript
▸ isARDoubleTapToFreezeEnabled()

Checks whether double-tap to freeze is enabled in AR mode.

isARImageResultEnabled #

TypeScript
▸ isARImageResultEnabled()

Retrieves whether image result is enabled for AR mode.

isARBarcodeThumbnailOnResultEnabled #

TypeScript
▸ isARBarcodeThumbnailOnResultEnabled()

Retrieves whether barcode thumbnail on result is enabled for AR mode.