@frontegg/rest-api 7.111.0-alpha.4 → 7.112.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/auth/index.d.ts CHANGED
@@ -741,6 +741,10 @@ export declare class AuthenticationApi extends BaseApiClient {
741
741
  oidcPostLoginV2: (body: IOidcPostLoginV2) => Promise<ILoginResponse>;
742
742
  exchangeOAuthTokensV2: (body: IExchangeOAuthTokens) => Promise<ILoginResponseV3>;
743
743
  silentOAuthRefreshTokenV2: () => Promise<ILoginResponseV3>;
744
+ silentOAuthRefreshTokenV3: (tokens: {
745
+ accessToken: string;
746
+ refreshToken: string;
747
+ }) => Promise<ILoginResponseV3>;
744
748
  exchangeOAuthTokens: (body: IExchangeOAuthTokens) => Promise<ILoginResponse>;
745
749
  silentOAuthRefreshToken: () => Promise<ILoginResponse>;
746
750
  /**
package/auth/index.js CHANGED
@@ -675,6 +675,14 @@ export class AuthenticationApi extends BaseApiClient {
675
675
  });
676
676
  return this.generateLoginResponseFromOAuthResponseV2(data);
677
677
  };
678
+ this.silentOAuthRefreshTokenV3 = async tokens => {
679
+ const oauthResponse = {
680
+ access_token: tokens.accessToken,
681
+ id_token: tokens.accessToken,
682
+ refresh_token: tokens.refreshToken
683
+ };
684
+ return this.generateLoginResponseFromOAuthResponseV2(oauthResponse);
685
+ };
678
686
  this.exchangeOAuthTokens = async body => {
679
687
  const data = await this.post(`${urls.oauth.v1}/token`, body);
680
688
  return this.generateLoginResponseFromOAuthResponse(data);
@@ -494,6 +494,8 @@ export interface IExchangeOAuthTokens {
494
494
  code_verifier?: string;
495
495
  redirect_uri?: string;
496
496
  refresh_token?: string;
497
+ grant_type?: string;
498
+ tenantId?: string;
497
499
  }
498
500
  export interface IOAuthTokenResponse {
499
501
  access_token: string;
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v7.111.0-alpha.4
1
+ /** @license Frontegg v7.112.0
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.
@@ -740,6 +740,14 @@ class AuthenticationApi extends _BaseApiClient.BaseApiClient {
740
740
  });
741
741
  return this.generateLoginResponseFromOAuthResponseV2(data);
742
742
  };
743
+ this.silentOAuthRefreshTokenV3 = async tokens => {
744
+ const oauthResponse = {
745
+ access_token: tokens.accessToken,
746
+ id_token: tokens.accessToken,
747
+ refresh_token: tokens.refreshToken
748
+ };
749
+ return this.generateLoginResponseFromOAuthResponseV2(oauthResponse);
750
+ };
743
751
  this.exchangeOAuthTokens = async body => {
744
752
  const data = await this.post(`${_constants2.urls.oauth.v1}/token`, body);
745
753
  return this.generateLoginResponseFromOAuthResponse(data);
package/node/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v7.111.0-alpha.4
1
+ /** @license Frontegg v7.112.0
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": "7.111.0-alpha.4",
3
+ "version": "7.112.0",
4
4
  "main": "./node/index.js",
5
5
  "license": "MIT",
6
6
  "author": "Frontegg LTD",