@asgardeo/javascript 0.14.0 → 0.16.0
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/dist/HttpClient.d.ts +64 -0
- package/dist/cjs/index.js +124 -0
- package/dist/cjs/index.js.map +4 -4
- package/dist/index.d.ts +2 -0
- package/dist/index.js +123 -0
- package/dist/index.js.map +4 -4
- package/dist/models/config.d.ts +15 -1
- package/dist/models/http.d.ts +45 -0
- package/dist/theme/types.d.ts +5 -0
- package/package.json +1 -1
package/dist/models/config.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
2
|
+
* Copyright (c) 2025-2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
3
|
*
|
|
4
4
|
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
5
|
* Version 2.0 (the "License"); you may not use this file except
|
|
@@ -281,6 +281,20 @@ export interface BaseConfig<T = unknown> extends WithPreferences {
|
|
|
281
281
|
* @see {@link https://openid.net/specs/openid-connect-session-management-1_0.html#IframeBasedSessionManagement}
|
|
282
282
|
*/
|
|
283
283
|
syncSession?: boolean;
|
|
284
|
+
/**
|
|
285
|
+
* Configuration for token lifecycle management.
|
|
286
|
+
*/
|
|
287
|
+
tokenLifecycle?: {
|
|
288
|
+
/**
|
|
289
|
+
* Configuration for refresh token behavior.
|
|
290
|
+
*/
|
|
291
|
+
refreshToken?: {
|
|
292
|
+
/**
|
|
293
|
+
* Whether to automatically refresh the access token periodically before it expires.
|
|
294
|
+
*/
|
|
295
|
+
autoRefresh?: boolean;
|
|
296
|
+
};
|
|
297
|
+
};
|
|
284
298
|
/**
|
|
285
299
|
* Token validation configuration.
|
|
286
300
|
* This allows you to configure how the SDK validates tokens received from the authorization server.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
+
*
|
|
4
|
+
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
+
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
+
* in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing,
|
|
12
|
+
* software distributed under the License is distributed on an
|
|
13
|
+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
+
* KIND, either express or implied. See the License for the
|
|
15
|
+
* specific language governing permissions and limitations
|
|
16
|
+
* under the License.
|
|
17
|
+
*/
|
|
18
|
+
export interface HttpResponse<T = any> {
|
|
19
|
+
config: HttpRequestConfig;
|
|
20
|
+
data: T;
|
|
21
|
+
headers: Record<string, string>;
|
|
22
|
+
status: number;
|
|
23
|
+
statusText: string;
|
|
24
|
+
}
|
|
25
|
+
export interface HttpError extends Error {
|
|
26
|
+
code?: string;
|
|
27
|
+
config?: HttpRequestConfig;
|
|
28
|
+
response?: {
|
|
29
|
+
data?: any;
|
|
30
|
+
headers?: Record<string, string>;
|
|
31
|
+
status: number;
|
|
32
|
+
statusText?: string;
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
export interface HttpRequestConfig {
|
|
36
|
+
attachToken?: boolean;
|
|
37
|
+
data?: any;
|
|
38
|
+
headers?: Record<string, string>;
|
|
39
|
+
method?: string;
|
|
40
|
+
params?: Record<string, any>;
|
|
41
|
+
shouldAttachIDPAccessToken?: boolean;
|
|
42
|
+
shouldEncodeToFormData?: boolean;
|
|
43
|
+
startTimeInMs?: number;
|
|
44
|
+
url?: string;
|
|
45
|
+
}
|
package/dist/theme/types.d.ts
CHANGED
|
@@ -65,11 +65,13 @@ export interface ThemeColors {
|
|
|
65
65
|
error: {
|
|
66
66
|
contrastText: string;
|
|
67
67
|
dark?: string;
|
|
68
|
+
light?: string;
|
|
68
69
|
main: string;
|
|
69
70
|
};
|
|
70
71
|
info: {
|
|
71
72
|
contrastText: string;
|
|
72
73
|
dark?: string;
|
|
74
|
+
light?: string;
|
|
73
75
|
main: string;
|
|
74
76
|
};
|
|
75
77
|
primary: {
|
|
@@ -80,11 +82,13 @@ export interface ThemeColors {
|
|
|
80
82
|
secondary: {
|
|
81
83
|
contrastText: string;
|
|
82
84
|
dark?: string;
|
|
85
|
+
light?: string;
|
|
83
86
|
main: string;
|
|
84
87
|
};
|
|
85
88
|
success: {
|
|
86
89
|
contrastText: string;
|
|
87
90
|
dark?: string;
|
|
91
|
+
light?: string;
|
|
88
92
|
main: string;
|
|
89
93
|
};
|
|
90
94
|
text: {
|
|
@@ -95,6 +99,7 @@ export interface ThemeColors {
|
|
|
95
99
|
warning: {
|
|
96
100
|
contrastText: string;
|
|
97
101
|
dark?: string;
|
|
102
|
+
light?: string;
|
|
98
103
|
main: string;
|
|
99
104
|
};
|
|
100
105
|
}
|