Module: platform
Classes
Interfaces
Functions
authenticate
▸ authenticate(opts): Promise<{ accountStatus:
AccountStatus ; deviceTrusted:
boolean ; email: string ; legacyData?:
PBES2Container ; provisioning:
AccountProvisioning ; token:
string }>
Parameters
| Name | Type |
|---|---|
opts |
Object |
opts.authenticatorId? |
string |
opts.authenticatorIndex? |
number |
opts.email? |
string |
opts.purpose |
AuthPurpose |
opts.type? |
AuthType |
Returns
Promise<{ accountStatus:
AccountStatus ; deviceTrusted:
boolean ; email: string ; legacyData?:
PBES2Container ; provisioning:
AccountProvisioning ; token:
string }>
Defined in
completeAuthRequest
▸ completeAuthRequest(req): Promise<{ accountStatus:
AccountStatus ; deviceTrusted:
boolean ; email: string ; legacyData?:
PBES2Container ; provisioning:
AccountProvisioning ; token:
string }>
Parameters
| Name | Type |
|---|---|
req |
StartAuthRequestResponse |
Returns
Promise<{ accountStatus:
AccountStatus ; deviceTrusted:
boolean ; email: string ; legacyData?:
PBES2Container ; provisioning:
AccountProvisioning ; token:
string }>
Defined in
composeEmail
▸ composeEmail(addr, subject, message): Promise<void>
Parameters
| Name | Type |
|---|---|
addr |
string |
subject |
string |
message |
string |
Returns
Promise<void>
Defined in
getClipboard
▸ getClipboard(): Promise<string>
Copies the given text to the system clipboard
Returns
Promise<string>
Defined in
getCryptoProvider
▸ getCryptoProvider():
CryptoProvider
Returns
Defined in
getDeviceInfo
▸ getDeviceInfo():
Promise<DeviceInfo>
Get information about the current device
Returns
Promise<DeviceInfo>
Defined in
getPlatform
▸ getPlatform(): Platform
Get the current Platform implemenation
Returns
Defined in
getPlatformAuthType
▸ getPlatformAuthType(): null | AuthType
Returns
null | AuthType
Defined in
getStorage
▸ getStorage(): Storage
Returns
Defined in
openExternalUrl
▸ openExternalUrl(url): void
Parameters
| Name | Type |
|---|---|
url |
string |
Returns
void
Defined in
registerAuthenticator
▸ registerAuthenticator(opts): Promise<string>
Parameters
| Name | Type |
|---|---|
opts |
Object |
opts.data? |
any |
opts.device? |
DeviceInfo |
opts.purposes |
AuthPurpose[] |
opts.type |
AuthType |
Returns
Promise<string>
Defined in
registerPlatformAuthenticator
▸ registerPlatformAuthenticator(purposes): Promise<string>
Parameters
| Name | Type |
|---|---|
purposes |
AuthPurpose[] |
Returns
Promise<string>
Defined in
saveFile
▸ saveFile(name, type, contents): Promise<void>
Parameters
| Name | Type |
|---|---|
name |
string |
type |
string |
contents |
Uint8Array |
Returns
Promise<void>
Defined in
scanQR
▸ scanQR(): Promise<string>
Returns
Promise<string>
Defined in
setClipboard
▸ setClipboard(val): Promise<void>
Retrieves the current text from the system clipboard
Parameters
| Name | Type |
|---|---|
val |
string |
Returns
Promise<void>
Defined in
setPlatform
▸ setPlatform(p): void
Set the appropriate Platform implemenation for the current environment
Parameters
| Name | Type |
|---|---|
p |
Platform |
Returns
void
Defined in
startAuthRequest
▸ startAuthRequest(opts):
Promise<StartAuthRequestResponse>
Parameters
| Name | Type |
|---|---|
opts |
Object |
opts.authenticatorId? |
string |
opts.authenticatorIndex? |
number |
opts.email? |
string |
opts.purpose |
AuthPurpose |
opts.type? |
AuthType |
Returns
Promise<StartAuthRequestResponse>
Defined in
stopScanQR
▸ stopScanQR(): Promise<void>
Returns
Promise<void>
Defined in
supportsPlatformAuthenticator
▸ supportsPlatformAuthenticator(): Promise<boolean>
Returns
Promise<boolean>