Taro.checkIsSupportSoterAuthentication(option)
Gets SOTER biometric authentication methods supported by this device.
Type
(option?: Option) => Promise<SuccessCallbackResult>
Parameters
Option
Property | Type | Required | Description |
---|---|---|---|
complete | (res: any) => void | No | The callback function used when the API call completed (always executed whether the call succeeds or fails) |
fail | (res: any) => void | No | The callback function for a failed API call |
success | (res: Result) => void | No | The callback function for a successful API call |
SuccessCallbackResult
Property | Type | Description |
---|---|---|
supportMode | ("fingerPrint" | "facial" | "speech")[] | Biometric recognition methods recognized by SOTER and supported by this device |
errMsg | string | Call result |
requestAuthModes
Property | Description |
---|---|
fingerPrint | Fingerprint recognition |
facial | Face recognition (not supported) |
speech | Voiceprint recognition (not supported) |
API Support
API | WeChat Mini-Program | H5 | React Native |
---|---|---|---|
requestAuthModes.speech |
Sample Code
Taro.checkIsSupportSoterAuthentication({
success: function (res) {
// res.supportMode = [] No biometric recognition methods supported by SOTER are available
// res.supportMode = ['fingerPrint'] Only fingerprint recognition is supported
// res.supportMode = ['fingerPrint', 'facial'] Fingerprint recognition and face recognition are supported
}
})
API Support
API | WeChat Mini-Program | H5 | React Native |
---|---|---|---|
Taro.checkIsSupportSoterAuthentication | ✔️ |