privacypal-local-client
v1.0.4
Published
Javascript library to work with privacypal (keepass) vaults.
Downloads
3
Readme
PrivacyPal Local Client
Class Hierarchy
Methods
Methods
constructor
▸ constructor(fileInterface
: [FileInterface], path
: string): Promise‹boolean›
Parameters:
| Name | Type |
| --------------- | --------------- |
| fileInterface
| [FileInterface] |
| path
| string |
Returns: void
addAccount
▸ addAccount(entry
: [Entry]): Promise‹boolean›
Parameters:
| Name | Type |
| ------- | ------- |
| entry
| [Entry] |
Returns: Promise‹boolean›
getAccounts
▸ getAccounts(): Promise‹[Entry]
Returns: Promise
getAccountCredentials
▸ getAccountCredentials(): Promise‹[EntryCredentials]
Returns: Promise
login
▸ login(username
: string, password
: string): Promise‹void›
Parameters:
| Name | Type |
| ---------- | ------ |
| username
| string |
| password
| string |
Returns: Promise‹void›
Type aliases
FileInterface
Ƭ FileInterface:
{
readFile: (path: string) => Promise<string>;
writeFile: (path: string, data: string) => Promise<void>;
findFile: (path: string) => Promise<boolean>;
createFile: (path: string) => Promise<void>;
deleteFile: (path: string) => Promise<void>;
}
Entry
Ƭ Entry: Record‹EntryFields, string›
EntryFields
Ƭ EntryFields: _"name" | "url" | "type"
###EntryCredentials
Ƭ EntryCredentials: Record‹EntryCredentialsFields, string›
###EntryCredentialsFields
Ƭ EntryCredentialsFields: _"username" | "password" | "otp";