11 lines
402 B
TypeScript
11 lines
402 B
TypeScript
|
|
export type TBackendType = 'macos-keychain' | 'linux-secret-service' | 'file-encrypted';
|
||
|
|
|
||
|
|
export interface ISecretBackend {
|
||
|
|
readonly backendType: TBackendType;
|
||
|
|
isAvailable(): Promise<boolean>;
|
||
|
|
setSecret(account: string, secret: string): Promise<void>;
|
||
|
|
getSecret(account: string): Promise<string | null>;
|
||
|
|
deleteSecret(account: string): Promise<boolean>;
|
||
|
|
listAccounts(): Promise<string[]>;
|
||
|
|
}
|