mirror of
https://github.com/status-im/realm-js.git
synced 2025-02-23 19:58:19 +00:00
add TS definition for retrieveAccount
This commit is contained in:
parent
e31529397f
commit
55c7c8f68c
12
lib/index.d.ts
vendored
12
lib/index.d.ts
vendored
@ -240,6 +240,17 @@ declare namespace Realm {
|
||||
*/
|
||||
declare namespace Realm.Sync {
|
||||
|
||||
interface UserInfo {
|
||||
id: string;
|
||||
isAdmin: boolean;
|
||||
}
|
||||
|
||||
interface Account {
|
||||
provider_id: string;
|
||||
provider: string;
|
||||
user: UserInfo
|
||||
}
|
||||
|
||||
/**
|
||||
* User
|
||||
* @see { @link https://realm.io/docs/javascript/latest/api/Realm.Sync.User.html }
|
||||
@ -258,6 +269,7 @@ declare namespace Realm.Sync {
|
||||
static registerWithProvider(server: string, options: { provider: string, providerToken: string, userInfo: any }, callback: (error: Error | null, user: User | null) => void): void;
|
||||
logout(): void;
|
||||
openManagementRealm(): Realm;
|
||||
retrieveAccount(provider: string, username: string): Promise<Account>;
|
||||
}
|
||||
|
||||
interface SyncConfiguration {
|
||||
|
Loading…
x
Reference in New Issue
Block a user