API: Capture Photos & Videos
This sample code allows you to capture photos and videos using the device's front or rear cameras and store the result locally in Kiosk Pro's documents folder. Images can also be returned as a Base64 string for easy upload to a database.
Requires
- Kiosk Pro Plus or Enterprise, version 10.3 or later
- App Settings
- Content > JavaScript API > Access JavaScript API = By Import
- iOS/iPadOS Permissions
- Camera - more on enabling specific iOS/iPadOS permissions here
Sample Code
Photo
Photo capture with both cameras available
Photo capture with two cameras, 2x zoom for front, 3x zoom for rear
Photo capture with countdown
Video
Video capture with both cameras available
Video capture with two cameras, 2x zoom for front, 3x zoom for rear
Video capture with countdown
Video capture with Center Stage
General Functions
Cancel current capture flow task
Is capture flow task in progress?
Cancel started capture flow task
Clear report history
Results