@descope/react-sdk 0.0.0-alpha.0 → 0.0.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -4
- package/dist/cjs/components/AuthProvider/AuthProvider.js +1 -1
- package/dist/cjs/components/AuthProvider/AuthProvider.js.map +1 -1
- package/dist/cjs/components/AuthProvider/useSdk.js +1 -1
- package/dist/cjs/components/AuthProvider/useSdk.js.map +1 -1
- package/dist/cjs/components/Descope.js +1 -1
- package/dist/cjs/components/Descope.js.map +1 -1
- package/dist/cjs/components/UserProfile.js +1 -1
- package/dist/cjs/components/UserProfile.js.map +1 -1
- package/dist/cjs/constants.js +1 -1
- package/dist/cjs/hooks/useSession.js +1 -1
- package/dist/cjs/hooks/useSession.js.map +1 -1
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/components/AuthProvider/AuthProvider.js +1 -1
- package/dist/esm/components/AuthProvider/AuthProvider.js.map +1 -1
- package/dist/esm/components/AuthProvider/useSdk.js +1 -1
- package/dist/esm/components/AuthProvider/useSdk.js.map +1 -1
- package/dist/esm/components/Descope.js +1 -1
- package/dist/esm/components/Descope.js.map +1 -1
- package/dist/esm/components/UserProfile.js +1 -1
- package/dist/esm/components/UserProfile.js.map +1 -1
- package/dist/esm/constants.js +1 -1
- package/dist/esm/hooks/useSession.js +1 -1
- package/dist/esm/hooks/useSession.js.map +1 -1
- package/dist/esm/sdk.js.map +1 -1
- package/dist/index.d.ts +135 -31
- package/dist/index.umd.js +2 -2
- package/dist/index.umd.js.map +1 -1
- package/dist/types/components/AuthProvider/AuthProvider.d.ts +12 -0
- package/dist/types/components/AuthProvider/useSdk.d.ts +2 -2
- package/dist/types/sdk.d.ts +308 -46
- package/dist/types/types.d.ts +4 -1
- package/package.json +11 -10
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { FC, DOMAttributes } from 'react';
|
|
2
2
|
import * as _descope_web_js_sdk from '@descope/web-js-sdk';
|
|
3
3
|
import { CookieConfig, OidcConfig } from '@descope/web-js-sdk';
|
|
4
|
+
import * as _1 from '@descope/core-js-sdk';
|
|
5
|
+
import * as _2 from 'oidc-client-ts';
|
|
4
6
|
import * as _descope_web_component from '@descope/web-component';
|
|
5
7
|
import _descope_web_component__default, { ILogger, ThemeOptions, AutoFocusOptions } from '@descope/web-component';
|
|
6
8
|
export { ILogger } from '@descope/web-component';
|
|
@@ -10,22 +12,6 @@ import AccessKeyManagementWidget from '@descope/access-key-management-widget';
|
|
|
10
12
|
import AuditManagementWidget from '@descope/audit-management-widget';
|
|
11
13
|
import UserProfileWidget from '@descope/user-profile-widget';
|
|
12
14
|
import ApplicationsPortalWidget from '@descope/applications-portal-widget';
|
|
13
|
-
import * as _1 from '@descope/core-js-sdk';
|
|
14
|
-
import * as _2 from '@descope/web-js-sdk/node_modules/oidc-client-ts/dist/types/oidc-client-ts';
|
|
15
|
-
|
|
16
|
-
interface IAuthProviderProps {
|
|
17
|
-
projectId: string;
|
|
18
|
-
baseUrl?: string;
|
|
19
|
-
baseStaticUrl?: string;
|
|
20
|
-
persistTokens?: boolean;
|
|
21
|
-
sessionTokenViaCookie?: CookieConfig;
|
|
22
|
-
oidcConfig?: OidcConfig;
|
|
23
|
-
storeLastAuthenticatedUser?: boolean;
|
|
24
|
-
keepLastAuthenticatedUserAfterLogout?: boolean;
|
|
25
|
-
refreshCookieName?: string;
|
|
26
|
-
children?: React.ReactNode;
|
|
27
|
-
}
|
|
28
|
-
declare const AuthProvider: FC<IAuthProviderProps>;
|
|
29
15
|
|
|
30
16
|
declare const createSdkWrapper: <P extends Omit<{
|
|
31
17
|
projectId: string;
|
|
@@ -65,6 +51,7 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
65
51
|
};
|
|
66
52
|
} & {
|
|
67
53
|
oidcConfig?: _descope_web_js_sdk.OidcConfig;
|
|
54
|
+
getExternalToken?: () => Promise<string>;
|
|
68
55
|
} & {
|
|
69
56
|
fpKey?: string;
|
|
70
57
|
fpLoad?: boolean;
|
|
@@ -119,7 +106,9 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
119
106
|
};
|
|
120
107
|
thirdPartyAppStateId?: string;
|
|
121
108
|
applicationScopes?: string;
|
|
122
|
-
|
|
109
|
+
outboundAppId?: string;
|
|
110
|
+
outboundAppScopes?: string[];
|
|
111
|
+
}, "tenant" | "redirectUrl" | "redirectAuth" | "oidcIdpStateId" | "samlIdpStateId" | "samlIdpUsername" | "ssoAppId" | "thirdPartyAppId" | "oidcLoginHint" | "preview" | "abTestingKey" | "client" | "locale" | "oidcPrompt" | "oidcErrorRedirectUri" | "nativeOptions" | "thirdPartyAppStateId" | "applicationScopes" | "outboundAppId" | "outboundAppScopes"> & {
|
|
123
112
|
lastAuth?: Omit<{
|
|
124
113
|
authMethod?: "webauthn" | "otp" | "oauth" | "saml" | "totp" | "magiclink" | "enchantedlink";
|
|
125
114
|
oauthProvider?: string;
|
|
@@ -157,8 +146,8 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
157
146
|
create: boolean;
|
|
158
147
|
}>>;
|
|
159
148
|
};
|
|
160
|
-
update: ((identifier: string, token
|
|
161
|
-
start: (loginId: string, origin: string, token
|
|
149
|
+
update: ((identifier: string, token?: string, passkeyOptions?: _1.PasskeyOptions) => Promise<_1.SdkResponse<_1.ResponseData>>) & {
|
|
150
|
+
start: (loginId: string, origin: string, token?: string, passkeyOptions?: _1.PasskeyOptions) => Promise<_1.SdkResponse<{
|
|
162
151
|
transactionId: string;
|
|
163
152
|
options: string;
|
|
164
153
|
create: boolean;
|
|
@@ -173,13 +162,33 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
173
162
|
};
|
|
174
163
|
};
|
|
175
164
|
fedcm: {
|
|
176
|
-
|
|
165
|
+
onetap: {
|
|
166
|
+
requestExchangeCode(options: {
|
|
167
|
+
provider?: string;
|
|
168
|
+
oneTapConfig?: _descope_web_js_sdk.OneTapConfig;
|
|
169
|
+
loginOptions?: _1.LoginOptions;
|
|
170
|
+
onSkipped?: (reason?: string) => void;
|
|
171
|
+
onDismissed?: (reason?: string) => void;
|
|
172
|
+
onFailed?: (error: Error) => void;
|
|
173
|
+
onCodeReceived: (code: string) => void;
|
|
174
|
+
}): void;
|
|
175
|
+
requestAuthentication(options?: {
|
|
176
|
+
provider?: string;
|
|
177
|
+
oneTapConfig?: _descope_web_js_sdk.OneTapConfig;
|
|
178
|
+
loginOptions?: _1.LoginOptions;
|
|
179
|
+
onSkipped?: (reason?: string) => void;
|
|
180
|
+
onDismissed?: (reason?: string) => void;
|
|
181
|
+
onFailed?: (error: Error) => void;
|
|
182
|
+
onAuthenticated?: (response: _1.JWTResponse) => void;
|
|
183
|
+
}): void;
|
|
184
|
+
};
|
|
185
|
+
oneTap(provider?: string, oneTapConfig?: _descope_web_js_sdk.OneTapConfig, loginOptions?: _1.LoginOptions, onSkipped?: (reason?: string) => void, onDismissed?: (reason?: string) => void): void;
|
|
177
186
|
launch(context?: "signin" | "signup" | "use" | "continue"): Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
178
187
|
isSupported(): boolean;
|
|
179
188
|
isLoggedIn(context?: "signin" | "signup" | "use" | "continue"): Promise<boolean>;
|
|
180
189
|
};
|
|
181
190
|
oidc: {
|
|
182
|
-
|
|
191
|
+
loginWithRedirect: (arg?: _2.CreateSigninRequestArgs, disableNavigation?: boolean) => Promise<_1.SdkResponse<_1.URLResponse>>;
|
|
183
192
|
finishLogin: (url?: string) => Promise<any>;
|
|
184
193
|
finishLoginIfNeed: (url?: string) => Promise<any>;
|
|
185
194
|
refreshToken: (refreshToken: string) => Promise<_2.SigninResponse>;
|
|
@@ -544,6 +553,13 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
544
553
|
exchange: (code: string) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
545
554
|
startNative: (provider: string, loginOptions?: _1.LoginOptions, implicit?: boolean) => Promise<_1.SdkResponse<_1.ResponseData>>;
|
|
546
555
|
finishNative: (provider: string, stateId: string, user?: string, code?: string, idToken?: string) => Promise<_1.SdkResponse<_1.ResponseData>>;
|
|
556
|
+
getOneTapClientId: (provider: string) => Promise<_1.SdkResponse<{
|
|
557
|
+
clientId: string;
|
|
558
|
+
}>>;
|
|
559
|
+
verifyOneTapIDToken: (provider: string, idToken: string, nonce: string, loginOptions?: _1.LoginOptions) => Promise<_1.SdkResponse<{
|
|
560
|
+
code: string;
|
|
561
|
+
}>>;
|
|
562
|
+
exchangeOneTapIDToken: (provider: string, idToken: string, nonce: string, loginOptions?: _1.LoginOptions) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
547
563
|
};
|
|
548
564
|
saml: {
|
|
549
565
|
start: (tenantIdOrEmail: string, redirectUrl?: string, loginOptions?: _1.LoginOptions, token?: string, ssoId?: string) => Promise<_1.SdkResponse<_1.URLResponse>>;
|
|
@@ -737,7 +753,9 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
737
753
|
};
|
|
738
754
|
thirdPartyAppStateId?: string;
|
|
739
755
|
applicationScopes?: string;
|
|
740
|
-
|
|
756
|
+
outboundAppId?: string;
|
|
757
|
+
outboundAppScopes?: string[];
|
|
758
|
+
}, "tenant" | "redirectUrl" | "redirectAuth" | "oidcIdpStateId" | "samlIdpStateId" | "samlIdpUsername" | "ssoAppId" | "thirdPartyAppId" | "oidcLoginHint" | "preview" | "abTestingKey" | "client" | "locale" | "oidcPrompt" | "oidcErrorRedirectUri" | "nativeOptions" | "thirdPartyAppStateId" | "applicationScopes" | "outboundAppId" | "outboundAppScopes"> & {
|
|
741
759
|
lastAuth?: Omit<{
|
|
742
760
|
authMethod?: "webauthn" | "otp" | "oauth" | "saml" | "totp" | "magiclink" | "enchantedlink";
|
|
743
761
|
oauthProvider?: string;
|
|
@@ -775,8 +793,8 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
775
793
|
create: boolean;
|
|
776
794
|
}>>;
|
|
777
795
|
};
|
|
778
|
-
update: ((identifier: string, token
|
|
779
|
-
start: (loginId: string, origin: string, token
|
|
796
|
+
update: ((identifier: string, token?: string, passkeyOptions?: _1.PasskeyOptions) => Promise<_1.SdkResponse<_1.ResponseData>>) & {
|
|
797
|
+
start: (loginId: string, origin: string, token?: string, passkeyOptions?: _1.PasskeyOptions) => Promise<_1.SdkResponse<{
|
|
780
798
|
transactionId: string;
|
|
781
799
|
options: string;
|
|
782
800
|
create: boolean;
|
|
@@ -791,13 +809,33 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
791
809
|
};
|
|
792
810
|
};
|
|
793
811
|
fedcm: {
|
|
794
|
-
|
|
812
|
+
onetap: {
|
|
813
|
+
requestExchangeCode(options: {
|
|
814
|
+
provider?: string;
|
|
815
|
+
oneTapConfig?: _descope_web_js_sdk.OneTapConfig;
|
|
816
|
+
loginOptions?: _1.LoginOptions;
|
|
817
|
+
onSkipped?: (reason?: string) => void;
|
|
818
|
+
onDismissed?: (reason?: string) => void;
|
|
819
|
+
onFailed?: (error: Error) => void;
|
|
820
|
+
onCodeReceived: (code: string) => void;
|
|
821
|
+
}): void;
|
|
822
|
+
requestAuthentication(options?: {
|
|
823
|
+
provider?: string;
|
|
824
|
+
oneTapConfig?: _descope_web_js_sdk.OneTapConfig;
|
|
825
|
+
loginOptions?: _1.LoginOptions;
|
|
826
|
+
onSkipped?: (reason?: string) => void;
|
|
827
|
+
onDismissed?: (reason?: string) => void;
|
|
828
|
+
onFailed?: (error: Error) => void;
|
|
829
|
+
onAuthenticated?: (response: _1.JWTResponse) => void;
|
|
830
|
+
}): void;
|
|
831
|
+
};
|
|
832
|
+
oneTap(provider?: string, oneTapConfig?: _descope_web_js_sdk.OneTapConfig, loginOptions?: _1.LoginOptions, onSkipped?: (reason?: string) => void, onDismissed?: (reason?: string) => void): void;
|
|
795
833
|
launch(context?: "signin" | "signup" | "use" | "continue"): Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
796
834
|
isSupported(): boolean;
|
|
797
835
|
isLoggedIn(context?: "signin" | "signup" | "use" | "continue"): Promise<boolean>;
|
|
798
836
|
};
|
|
799
837
|
oidc: {
|
|
800
|
-
|
|
838
|
+
loginWithRedirect: (arg?: _2.CreateSigninRequestArgs, disableNavigation?: boolean) => Promise<_1.SdkResponse<_1.URLResponse>>;
|
|
801
839
|
finishLogin: (url?: string) => Promise<any>;
|
|
802
840
|
finishLoginIfNeed: (url?: string) => Promise<any>;
|
|
803
841
|
refreshToken: (refreshToken: string) => Promise<_2.SigninResponse>;
|
|
@@ -1162,6 +1200,13 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
1162
1200
|
exchange: (code: string) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
1163
1201
|
startNative: (provider: string, loginOptions?: _1.LoginOptions, implicit?: boolean) => Promise<_1.SdkResponse<_1.ResponseData>>;
|
|
1164
1202
|
finishNative: (provider: string, stateId: string, user?: string, code?: string, idToken?: string) => Promise<_1.SdkResponse<_1.ResponseData>>;
|
|
1203
|
+
getOneTapClientId: (provider: string) => Promise<_1.SdkResponse<{
|
|
1204
|
+
clientId: string;
|
|
1205
|
+
}>>;
|
|
1206
|
+
verifyOneTapIDToken: (provider: string, idToken: string, nonce: string, loginOptions?: _1.LoginOptions) => Promise<_1.SdkResponse<{
|
|
1207
|
+
code: string;
|
|
1208
|
+
}>>;
|
|
1209
|
+
exchangeOneTapIDToken: (provider: string, idToken: string, nonce: string, loginOptions?: _1.LoginOptions) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
1165
1210
|
};
|
|
1166
1211
|
saml: {
|
|
1167
1212
|
start: (tenantIdOrEmail: string, redirectUrl?: string, loginOptions?: _1.LoginOptions, token?: string, ssoId?: string) => Promise<_1.SdkResponse<_1.URLResponse>>;
|
|
@@ -1355,7 +1400,9 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
1355
1400
|
};
|
|
1356
1401
|
thirdPartyAppStateId?: string;
|
|
1357
1402
|
applicationScopes?: string;
|
|
1358
|
-
|
|
1403
|
+
outboundAppId?: string;
|
|
1404
|
+
outboundAppScopes?: string[];
|
|
1405
|
+
}, "tenant" | "redirectUrl" | "redirectAuth" | "oidcIdpStateId" | "samlIdpStateId" | "samlIdpUsername" | "ssoAppId" | "thirdPartyAppId" | "oidcLoginHint" | "preview" | "abTestingKey" | "client" | "locale" | "oidcPrompt" | "oidcErrorRedirectUri" | "nativeOptions" | "thirdPartyAppStateId" | "applicationScopes" | "outboundAppId" | "outboundAppScopes"> & {
|
|
1359
1406
|
lastAuth?: Omit<{
|
|
1360
1407
|
authMethod?: "webauthn" | "otp" | "oauth" | "saml" | "totp" | "magiclink" | "enchantedlink";
|
|
1361
1408
|
oauthProvider?: string;
|
|
@@ -1393,8 +1440,8 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
1393
1440
|
create: boolean;
|
|
1394
1441
|
}>>;
|
|
1395
1442
|
};
|
|
1396
|
-
update: ((identifier: string, token
|
|
1397
|
-
start: (loginId: string, origin: string, token
|
|
1443
|
+
update: ((identifier: string, token?: string, passkeyOptions?: _1.PasskeyOptions) => Promise<_1.SdkResponse<_1.ResponseData>>) & {
|
|
1444
|
+
start: (loginId: string, origin: string, token?: string, passkeyOptions?: _1.PasskeyOptions) => Promise<_1.SdkResponse<{
|
|
1398
1445
|
transactionId: string;
|
|
1399
1446
|
options: string;
|
|
1400
1447
|
create: boolean;
|
|
@@ -1409,13 +1456,33 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
1409
1456
|
};
|
|
1410
1457
|
};
|
|
1411
1458
|
fedcm: {
|
|
1412
|
-
|
|
1459
|
+
onetap: {
|
|
1460
|
+
requestExchangeCode(options: {
|
|
1461
|
+
provider?: string;
|
|
1462
|
+
oneTapConfig?: _descope_web_js_sdk.OneTapConfig;
|
|
1463
|
+
loginOptions?: _1.LoginOptions;
|
|
1464
|
+
onSkipped?: (reason?: string) => void;
|
|
1465
|
+
onDismissed?: (reason?: string) => void;
|
|
1466
|
+
onFailed?: (error: Error) => void;
|
|
1467
|
+
onCodeReceived: (code: string) => void;
|
|
1468
|
+
}): void;
|
|
1469
|
+
requestAuthentication(options?: {
|
|
1470
|
+
provider?: string;
|
|
1471
|
+
oneTapConfig?: _descope_web_js_sdk.OneTapConfig;
|
|
1472
|
+
loginOptions?: _1.LoginOptions;
|
|
1473
|
+
onSkipped?: (reason?: string) => void;
|
|
1474
|
+
onDismissed?: (reason?: string) => void;
|
|
1475
|
+
onFailed?: (error: Error) => void;
|
|
1476
|
+
onAuthenticated?: (response: _1.JWTResponse) => void;
|
|
1477
|
+
}): void;
|
|
1478
|
+
};
|
|
1479
|
+
oneTap(provider?: string, oneTapConfig?: _descope_web_js_sdk.OneTapConfig, loginOptions?: _1.LoginOptions, onSkipped?: (reason?: string) => void, onDismissed?: (reason?: string) => void): void;
|
|
1413
1480
|
launch(context?: "signin" | "signup" | "use" | "continue"): Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
1414
1481
|
isSupported(): boolean;
|
|
1415
1482
|
isLoggedIn(context?: "signin" | "signup" | "use" | "continue"): Promise<boolean>;
|
|
1416
1483
|
};
|
|
1417
1484
|
oidc: {
|
|
1418
|
-
|
|
1485
|
+
loginWithRedirect: (arg?: _2.CreateSigninRequestArgs, disableNavigation?: boolean) => Promise<_1.SdkResponse<_1.URLResponse>>;
|
|
1419
1486
|
finishLogin: (url?: string) => Promise<any>;
|
|
1420
1487
|
finishLoginIfNeed: (url?: string) => Promise<any>;
|
|
1421
1488
|
refreshToken: (refreshToken: string) => Promise<_2.SigninResponse>;
|
|
@@ -1780,6 +1847,13 @@ declare const createSdkWrapper: <P extends Omit<{
|
|
|
1780
1847
|
exchange: (code: string) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
1781
1848
|
startNative: (provider: string, loginOptions?: _1.LoginOptions, implicit?: boolean) => Promise<_1.SdkResponse<_1.ResponseData>>;
|
|
1782
1849
|
finishNative: (provider: string, stateId: string, user?: string, code?: string, idToken?: string) => Promise<_1.SdkResponse<_1.ResponseData>>;
|
|
1850
|
+
getOneTapClientId: (provider: string) => Promise<_1.SdkResponse<{
|
|
1851
|
+
clientId: string;
|
|
1852
|
+
}>>;
|
|
1853
|
+
verifyOneTapIDToken: (provider: string, idToken: string, nonce: string, loginOptions?: _1.LoginOptions) => Promise<_1.SdkResponse<{
|
|
1854
|
+
code: string;
|
|
1855
|
+
}>>;
|
|
1856
|
+
exchangeOneTapIDToken: (provider: string, idToken: string, nonce: string, loginOptions?: _1.LoginOptions) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
1783
1857
|
};
|
|
1784
1858
|
saml: {
|
|
1785
1859
|
start: (tenantIdOrEmail: string, redirectUrl?: string, loginOptions?: _1.LoginOptions, token?: string, ssoId?: string) => Promise<_1.SdkResponse<_1.URLResponse>>;
|
|
@@ -1953,6 +2027,34 @@ declare const getJwtRoles: (token?: any, tenant?: string) => string[];
|
|
|
1953
2027
|
declare const getCurrentTenant: (token?: any) => string;
|
|
1954
2028
|
declare const refresh: (token?: string) => Promise<_1.SdkResponse<_1.JWTResponse>>;
|
|
1955
2029
|
|
|
2030
|
+
type Config = Pick<Parameters<typeof createSdkWrapper>[0], 'projectId' | 'baseUrl' | 'persistTokens' | 'sessionTokenViaCookie' | 'storeLastAuthenticatedUser' | 'oidcConfig' | 'keepLastAuthenticatedUserAfterLogout' | 'refreshCookieName' | 'getExternalToken' | 'logger' | 'hooks'>;
|
|
2031
|
+
declare const _default: ({ projectId, baseUrl, persistTokens, sessionTokenViaCookie, refreshCookieName, oidcConfig, storeLastAuthenticatedUser, keepLastAuthenticatedUserAfterLogout, logger, hooks, getExternalToken, }: Config) => ReturnType<typeof createSdkWrapper>;
|
|
2032
|
+
|
|
2033
|
+
type UseSdkParams = Parameters<typeof _default>[0];
|
|
2034
|
+
type Logger = {
|
|
2035
|
+
debug: (...args: any[]) => void;
|
|
2036
|
+
warn: (...args: any[]) => void;
|
|
2037
|
+
error: (...args: any[]) => void;
|
|
2038
|
+
info: (...args: any[]) => void;
|
|
2039
|
+
log: (...args: any[]) => void;
|
|
2040
|
+
};
|
|
2041
|
+
interface IAuthProviderProps {
|
|
2042
|
+
projectId: string;
|
|
2043
|
+
baseUrl?: string;
|
|
2044
|
+
baseStaticUrl?: string;
|
|
2045
|
+
persistTokens?: boolean;
|
|
2046
|
+
sessionTokenViaCookie?: CookieConfig;
|
|
2047
|
+
oidcConfig?: OidcConfig;
|
|
2048
|
+
storeLastAuthenticatedUser?: boolean;
|
|
2049
|
+
keepLastAuthenticatedUserAfterLogout?: boolean;
|
|
2050
|
+
refreshCookieName?: string;
|
|
2051
|
+
getExternalToken?: () => Promise<string>;
|
|
2052
|
+
logger?: Logger;
|
|
2053
|
+
hooks?: UseSdkParams['hooks'];
|
|
2054
|
+
children?: React.ReactNode;
|
|
2055
|
+
}
|
|
2056
|
+
declare const AuthProvider: FC<IAuthProviderProps>;
|
|
2057
|
+
|
|
1956
2058
|
declare global {
|
|
1957
2059
|
namespace JSX {
|
|
1958
2060
|
interface IntrinsicElements {
|
|
@@ -2006,6 +2108,8 @@ type DescopeProps = {
|
|
|
2006
2108
|
debug?: boolean;
|
|
2007
2109
|
telemetryKey?: string;
|
|
2008
2110
|
redirectUrl?: string;
|
|
2111
|
+
outboundAppId?: string;
|
|
2112
|
+
outboundAppScopes?: string[];
|
|
2009
2113
|
errorTransformer?: (error: {
|
|
2010
2114
|
text: string;
|
|
2011
2115
|
type: string;
|