hp-app-bundle-sdk
Version:
A comprehensive SDK for building mini-applications.
58 lines • 1.44 kB
TypeScript
export interface BiometricsConfig {
/**
* Whether biometrics is enabled by default
* @default true
*/
enabled: boolean;
/**
* The type of biometric authentication to use
* @default 'auto' (let system decide)
*/
authType: "face" | "fingerprint" | "iris" | "auto";
/**
* Timeout for authentication in milliseconds
* @default 30000 (30 seconds)
*/
timeout: number;
/**
* Title to show in biometric prompt
*/
promptTitle: string;
/**
* Subtitle to show in biometric prompt
*/
promptSubtitle: string;
}
export interface BiometricResult {
success: boolean;
error?: {
code: string;
message: string;
};
}
export interface IBiometricsModule {
/**
* Check if biometric authentication is available
*/
isAvailable(): Promise<boolean>;
/**
* Authenticate using biometrics
*/
authenticate(options?: {
promptTitle?: string;
promptSubtitle?: string;
}): Promise<BiometricResult>;
/**
* Check if biometrics is enrolled/configured on device
*/
isEnrolled(): Promise<boolean>;
/**
* Get supported biometric types
*/
getSupportedTypes(): Promise<Array<"face" | "fingerprint" | "iris">>;
/**
* Check if biometrics is ready (available and enrolled)
*/
isReady(): Promise<boolean>;
}
//# sourceMappingURL=types.d.ts.map