@frontegg/rest-api 3.0.119 → 3.0.120

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/auth/index.d.ts CHANGED
@@ -91,6 +91,11 @@ export declare function refreshToken(): Promise<ILoginResponse>;
91
91
  * the server will return ILoginResponseV2 with new access Token and refresh token and store it in the browser cookies, as well as the tenants.
92
92
  */
93
93
  export declare function refreshTokenV2(): Promise<ILoginResponseV2>;
94
+ /**
95
+ * refresh token called as authenticated use, access and refresh tokens resolved by the cookies.
96
+ * the server will return ILoginResponseV3 with new access Token and refresh token and store it in the browser cookies, as well as the tenants and the active tenant.
97
+ */
98
+ export declare function refreshTokenV3(): Promise<ILoginResponseV3>;
94
99
  /**
95
100
  * logout from server, invalidate access and refresh token, remove it from cookies.
96
101
  */
package/auth/index.js CHANGED
@@ -131,6 +131,10 @@ export async function refreshTokenV2() {
131
131
  const data = await Post(`${urls.identity.auth.v1}/user/token/refresh`);
132
132
  return generateLoginResponseV2(data);
133
133
  }
134
+ export async function refreshTokenV3() {
135
+ const data = await Post(`${urls.identity.auth.v1}/user/token/refresh`);
136
+ return generateLoginResponseV3(data);
137
+ }
134
138
  export async function logout() {
135
139
  return Post(`${urls.identity.auth.v1}/logout`);
136
140
  }
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v3.0.119
1
+ /** @license Frontegg v3.0.120
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
@@ -23,6 +23,7 @@ var _exportNames = {
23
23
  acceptInvitation: true,
24
24
  refreshToken: true,
25
25
  refreshTokenV2: true,
26
+ refreshTokenV3: true,
26
27
  logout: true,
27
28
  OAuthLogout: true,
28
29
  forgotPassword: true,
@@ -225,6 +226,7 @@ exports.preVerifyMFAWebAuthnForLogin = preVerifyMFAWebAuthnForLogin;
225
226
  exports.recoverMfaToken = recoverMfaToken;
226
227
  exports.refreshToken = refreshToken;
227
228
  exports.refreshTokenV2 = refreshTokenV2;
229
+ exports.refreshTokenV3 = refreshTokenV3;
228
230
  exports.resendActivationEmail = resendActivationEmail;
229
231
  exports.resendInvitationEmail = resendInvitationEmail;
230
232
  exports.resetPassword = resetPassword;
@@ -445,6 +447,11 @@ async function refreshTokenV2() {
445
447
  return generateLoginResponseV2(data);
446
448
  }
447
449
 
450
+ async function refreshTokenV3() {
451
+ const data = await (0, _fetch.Post)(`${_constants.urls.identity.auth.v1}/user/token/refresh`);
452
+ return generateLoginResponseV3(data);
453
+ }
454
+
448
455
  async function logout() {
449
456
  return (0, _fetch.Post)(`${_constants.urls.identity.auth.v1}/logout`);
450
457
  }
package/node/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v3.0.119
1
+ /** @license Frontegg v3.0.120
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@frontegg/rest-api",
3
- "version": "3.0.119",
3
+ "version": "3.0.120",
4
4
  "main": "./node/index.js",
5
5
  "license": "MIT",
6
6
  "dependencies": {