LUNA SDK is a face recognition and analysis system that provides efficient and accurate processing of faces in images and video streams, and can run on a wide variety of mobile operating systems.
npm install capacitor-luna-id-sdk
npx cap sync
- Get
licence.conf
from VisionLabs - Configure Luna Platform 5 and get
LunaAccountID
- Configure
LunaServerURL
- Add to
./node_modules/capacitor-luna-id-sdk/ios/Frameworks/fsdk.framework/data/license.conf
your ownlicence.conf
file; - Add to
Info.plist
<key>LunaServerURL</key>
<string>https://[path-to-luna-platform-api]/6/</string>
<key>LunaAccountID</key>
<string><your luna account id></string>
Add to your project android/app/src/main/assets/data/license.conf
license file
Add to your root project local.properties
DEFAULT_BASE_URL="https://[path-to-luna-platform-api]/6/"
DEFAULT_LUNA_ACCOUNT_ID="<your luna account id>"
vl.login=YOUR_LOGIN
vl.pass=YOUR_PASSWORD
initialize(options?: LunaOptions | undefined) => any
Initialize plugin with configs
Param | Type |
---|---|
options |
LunaOptions |
Returns: any
Since: 1.0.8
start(options?: StartOptions | undefined) => any
Start face recognition
Param | Type |
---|---|
options |
StartOptions |
Returns: any
Since: 1.0.0
Prop | Type |
---|---|
livenessEnabled |
boolean |
occludeCheck |
boolean |
trackFaceIdentity |
boolean |
eyesCheck |
boolean |
glassesCheckEnabled |
boolean |
interactionEnabled |
boolean |
interactionTimeout |
number |
plistLicenseFileName |
string |
lunaConfig |
LunaConfig |
headers |
Headers |
Prop | Type | Description | Since |
---|---|---|---|
detectorStep |
number |
||
skipFrames |
number |
||
compressionQuality |
number |
||
minimalTrackLength |
number |
||
bestShotsCount |
number |
Android only | 5.0.0 |
numberOfBestShots |
number |
ios only | 5.0.0 |
borderDistance |
number |
||
detectFrameSize |
number |
||
bestShotInterval |
number |
||
headPitch |
number |
||
headYaw |
number |
||
headRoll |
number |
||
ags |
number |
||
eyesCheck |
boolean |
||
locationEnabled |
boolean |
ios only | 5.0.0 |
interactionEnabled |
boolean |
||
interactionTimeout |
number |
||
uploadImagesForLiveness |
boolean |
||
livenessErrorTimeout |
number |
||
livenessQuality |
number |
||
livenessType |
LivenessType |
Prop | Type | Description | Default | Since |
---|---|---|---|---|
disableErrors |
boolean |
Define whether to record video or not. | : false |
5.0.1 |
disableInteractionTips |
boolean |
Define whether to disable interaction Tips. | : false |
5.0.1 |
ignoreVideoWithoutFace |
boolean |
Define whether to start record video from camera activated or from face is deteced. | : false |
5.0.1 |
interactionEnabled |
boolean |
Define whether to enable interaction or not. | : true |
5.0.1 |
interactionTimeoutMs |
number |
Define timeout for interaction. | : 30000 |
5.0.1 |
recordVideo |
boolean |
Define whether to record video or not. | : false |
5.0.0 |
Prop | Type | Description | Since |
---|---|---|---|
base64String |
string |
The base64 encoded string representation of found bestShot. | 1.0.0 |
videoPath |
string |
The URI of video recorded from stream. | 5.0.0 |
Record<string, string> & Partial<Record<RestrictedHeaders, never>>
'Authorization' | 'Luna-Account-Id'
Members |
---|
None |
ByDescriptor |
ByPhoto |