1 |
|
2 |
|
3 |
|
4 | export declare class GenericError extends Error {
|
5 | error: string;
|
6 | error_description: string;
|
7 | constructor(error: string, error_description: string);
|
8 | static fromPayload({ error, error_description }: {
|
9 | error: string;
|
10 | error_description: string;
|
11 | }): GenericError;
|
12 | }
|
13 | /**
|
14 | * Thrown when handling the redirect callback fails, will be one of Auth0's
|
15 | * Authentication API's Standard Error Responses: https://auth0.com/docs/api/authentication?javascript#standard-error-responses
|
16 | */
|
17 | export declare class AuthenticationError extends GenericError {
|
18 | state: string;
|
19 | appState: any;
|
20 | constructor(error: string, error_description: string, state: string, appState?: any);
|
21 | }
|
22 | /**
|
23 | * Thrown when silent auth times out (usually due to a configuration issue) or
|
24 | * when network requests to the Auth server timeout.
|
25 | */
|
26 | export declare class TimeoutError extends GenericError {
|
27 | constructor();
|
28 | }
|
29 | /**
|
30 | * Error thrown when the login popup times out (if the user does not complete auth)
|
31 | */
|
32 | export declare class PopupTimeoutError extends TimeoutError {
|
33 | popup: Window;
|
34 | constructor(popup: Window);
|
35 | }
|
36 | export declare class PopupCancelledError extends GenericError {
|
37 | popup: Window;
|
38 | constructor(popup: Window);
|
39 | }
|
40 | /**
|
41 | * Error thrown when the token exchange results in a `mfa_required` error
|
42 | */
|
43 | export declare class MfaRequiredError extends GenericError {
|
44 | mfa_token: string;
|
45 | constructor(error: string, error_description: string, mfa_token: string);
|
46 | }
|
47 | /**
|
48 | * Error thrown when there is no refresh token to use
|
49 | */
|
50 | export declare class MissingRefreshTokenError extends GenericError {
|
51 | audience: string;
|
52 | scope: string;
|
53 | constructor(audience: string, scope: string);
|
54 | }
|