Skip to content

Disabling OneShotLiveness estimation#

If you want to skip a liveness estimation over the best shot, you can disable the OneShotLiveness estimation.

In LUNA ID for Android#

To disable the OneShotLiveness estimation, set the livenessType: LivenessType field to None in LunaConfig.

If livenessType: LivenessType is not specified, the OneShotLiveness estimation is disabled by default.

The example below shows how to disable the OneShotLiveness estimation:

val apiConfig = ApiHumanConfig("http://luna-platform.com/api/6/")
    LunaID.init(
        ...
        apiHumanConfig = apiConfig,
        lunaConfig = LunaConfig.create(
         livenessType = LivenessType.None,
        ),
    )

In LUNA ID for iOS#

To disable the OneShotLiveness estimation, disable sending of OneShotLiveness estimation requests to LUNA PLATFORM 5 by setting livenessType to .none. For example:

private lazy var configuration: LCLunaConfiguration = {
       let configuration = LCLunaConfiguration.defaultConfig()
       ...
       configuration.bestShotConfiguration.livenessType = .none
       ...
       return configuration
}()