forked from clerk/javascript
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexternalAccount.ts
More file actions
29 lines (27 loc) · 910 Bytes
/
Copy pathexternalAccount.ts
File metadata and controls
29 lines (27 loc) · 910 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import type { OAuthProvider, OAuthScope } from './oauth';
import type { ClerkResource } from './resource';
import type { VerificationResource } from './verification';
export type ReauthorizeExternalAccountParams = {
additionalScopes?: OAuthScope[];
redirectUrl?: string;
};
export interface ExternalAccountResource extends ClerkResource {
id: string;
identificationId: string;
provider: OAuthProvider;
providerUserId: string;
emailAddress: string;
approvedScopes: string;
firstName: string;
lastName: string;
imageUrl: string;
username?: string;
publicMetadata: Record<string, unknown>;
label?: string;
verification: VerificationResource | null;
reauthorize: (params: ReauthorizeExternalAccountParams) => Promise<ExternalAccountResource>;
destroy: () => Promise<void>;
providerSlug: () => OAuthProvider;
providerTitle: () => string;
accountIdentifier: () => string;
}