@frontegg/rest-api 7.75.0-alpha.0 → 7.75.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/index.d.ts CHANGED
@@ -27,7 +27,6 @@ import { SecurityCenterApi } from './security-center';
27
27
  import { PhoneNumbersApi } from './user-phone-numbers';
28
28
  import { ApplicationsApi } from './applications';
29
29
  import { VeloApi } from './velo';
30
- import { UserEmailPolicyApi } from './users-emails-policy';
31
30
  export * from './interfaces';
32
31
  export * from './auth/interfaces';
33
32
  export * from './auth/enums';
@@ -58,7 +57,6 @@ export * from './security-center/interfaces';
58
57
  export * from './user-phone-numbers/interfaces';
59
58
  export * from './applications/interfaces';
60
59
  export * from './velo/interfaces';
61
- export * from './users-emails-policy/interfaces';
62
60
  export { GENERIC_ERROR_CODE, GENERIC_ERROR_MESSAGE } from './constants';
63
61
  /**
64
62
  * Frontegg API client for default app
@@ -90,7 +88,6 @@ declare const api: {
90
88
  userPhoneNumbers: PhoneNumbersApi;
91
89
  applications: ApplicationsApi;
92
90
  velo: VeloApi;
93
- userEmailPolicy: UserEmailPolicyApi;
94
91
  };
95
92
  export type FronteggApiClient = {
96
93
  auth: AuthenticationApi;
@@ -117,7 +114,6 @@ export type FronteggApiClient = {
117
114
  userPhoneNumbers: PhoneNumbersApi;
118
115
  applications: ApplicationsApi;
119
116
  velo: VeloApi;
120
- userEmailPolicy: UserEmailPolicyApi;
121
117
  };
122
118
  declare const createApiClient: (appName: string) => FronteggApiClient;
123
119
  export { fetch, FetchClient, ContextHolder, FronteggContext, api, createApiClient, FronteggApiError, AuthStrategyEnum, SocialLoginProviders, ISubscriptionCancellationPolicy, ISubscriptionStatus, PaymentMethodType, ProviderType, MachineToMachineAuthStrategy, };
@@ -169,7 +165,6 @@ declare const _default: {
169
165
  userPhoneNumbers: PhoneNumbersApi;
170
166
  applications: ApplicationsApi;
171
167
  velo: VeloApi;
172
- userEmailPolicy: UserEmailPolicyApi;
173
168
  };
174
169
  createApiClient: (appName: string) => FronteggApiClient;
175
170
  FronteggApiError: typeof FronteggApiError;
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v7.75.0-alpha.0
1
+ /** @license Frontegg v7.75.0-alpha.1
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.
@@ -32,7 +32,6 @@ import DefaultSecurityCenterApi, { SecurityCenterApi } from './security-center';
32
32
  import DefaultPhoneNumbersApi, { PhoneNumbersApi } from './user-phone-numbers';
33
33
  import DefaultApplicationsApi, { ApplicationsApi } from './applications';
34
34
  import DefaultVeloApi, { VeloApi } from './velo';
35
- import DefaultUserEmailPolicyApi, { UserEmailPolicyApi } from './users-emails-policy';
36
35
  export * from './interfaces';
37
36
  export * from './auth/interfaces';
38
37
  export * from './auth/enums';
@@ -63,7 +62,6 @@ export * from './security-center/interfaces';
63
62
  export * from './user-phone-numbers/interfaces';
64
63
  export * from './applications/interfaces';
65
64
  export * from './velo/interfaces';
66
- export * from './users-emails-policy/interfaces';
67
65
  export { GENERIC_ERROR_CODE, GENERIC_ERROR_MESSAGE } from './constants';
68
66
  /**
69
67
  * Frontegg API client for default app
@@ -94,8 +92,7 @@ const api = {
94
92
  securityCenter: DefaultSecurityCenterApi,
95
93
  userPhoneNumbers: DefaultPhoneNumbersApi,
96
94
  applications: DefaultApplicationsApi,
97
- velo: DefaultVeloApi,
98
- userEmailPolicy: DefaultUserEmailPolicyApi
95
+ velo: DefaultVeloApi
99
96
  };
100
97
  const createApiClient = appName => ({
101
98
  auth: new AuthenticationApi(appName),
@@ -121,8 +118,7 @@ const createApiClient = appName => ({
121
118
  securityCenter: new SecurityCenterApi(appName),
122
119
  userPhoneNumbers: new PhoneNumbersApi(appName),
123
120
  applications: new ApplicationsApi(appName),
124
- velo: new VeloApi(appName),
125
- userEmailPolicy: new UserEmailPolicyApi(appName)
121
+ velo: new VeloApi(appName)
126
122
  });
127
123
  export { fetch, FetchClient, ContextHolder, FronteggContext, api, createApiClient, FronteggApiError, AuthStrategyEnum, SocialLoginProviders, ISubscriptionCancellationPolicy, ISubscriptionStatus, PaymentMethodType, ProviderType, MachineToMachineAuthStrategy };
128
124
  export default {
package/node/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v7.75.0-alpha.0
1
+ /** @license Frontegg v7.75.0-alpha.1
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.
@@ -173,7 +173,6 @@ var _securityCenter = _interopRequireWildcard(require("./security-center"));
173
173
  var _userPhoneNumbers = _interopRequireWildcard(require("./user-phone-numbers"));
174
174
  var _applications = _interopRequireWildcard(require("./applications"));
175
175
  var _velo = _interopRequireWildcard(require("./velo"));
176
- var _usersEmailsPolicy = _interopRequireWildcard(require("./users-emails-policy"));
177
176
  var _interfaces = require("./interfaces");
178
177
  Object.keys(_interfaces).forEach(function (key) {
179
178
  if (key === "default" || key === "__esModule") return;
@@ -522,18 +521,6 @@ Object.keys(_interfaces24).forEach(function (key) {
522
521
  }
523
522
  });
524
523
  });
525
- var _interfaces25 = require("./users-emails-policy/interfaces");
526
- Object.keys(_interfaces25).forEach(function (key) {
527
- if (key === "default" || key === "__esModule") return;
528
- if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
529
- if (key in exports && exports[key] === _interfaces25[key]) return;
530
- Object.defineProperty(exports, key, {
531
- enumerable: true,
532
- get: function () {
533
- return _interfaces25[key];
534
- }
535
- });
536
- });
537
524
  var _constants = require("./constants");
538
525
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
539
526
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
@@ -566,8 +553,7 @@ const api = {
566
553
  securityCenter: _securityCenter.default,
567
554
  userPhoneNumbers: _userPhoneNumbers.default,
568
555
  applications: _applications.default,
569
- velo: _velo.default,
570
- userEmailPolicy: _usersEmailsPolicy.default
556
+ velo: _velo.default
571
557
  };
572
558
  exports.api = api;
573
559
  const createApiClient = appName => ({
@@ -594,8 +580,7 @@ const createApiClient = appName => ({
594
580
  securityCenter: new _securityCenter.SecurityCenterApi(appName),
595
581
  userPhoneNumbers: new _userPhoneNumbers.PhoneNumbersApi(appName),
596
582
  applications: new _applications.ApplicationsApi(appName),
597
- velo: new _velo.VeloApi(appName),
598
- userEmailPolicy: new _usersEmailsPolicy.UserEmailPolicyApi(appName)
583
+ velo: new _velo.VeloApi(appName)
599
584
  });
600
585
  exports.createApiClient = createApiClient;
601
586
  var _default = {
@@ -16,17 +16,6 @@ class TeamsApi extends _BaseApiClient.BaseApiClient {
16
16
  addRoles: true
17
17
  });
18
18
  };
19
- this.updateEmail = async email => {
20
- return this.post(`${_constants.urls.identity.users.v1}/email/me`, {
21
- email
22
- });
23
- };
24
- this.verifyEmail = async (email, code) => {
25
- return this.post(`${_constants.urls.identity.users.v1}/email/me/verify`, {
26
- email,
27
- code
28
- });
29
- };
30
19
  this.updateProfile = async body => {
31
20
  return this.put(`${_constants.urls.identity.users.v2}/me`, body);
32
21
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@frontegg/rest-api",
3
- "version": "7.75.0-alpha.0",
3
+ "version": "7.75.0-alpha.1",
4
4
  "main": "./node/index.js",
5
5
  "license": "MIT",
6
6
  "author": "Frontegg LTD",
package/teams/index.d.ts CHANGED
@@ -5,8 +5,6 @@ import { BaseApiClient } from '../BaseApiClient';
5
5
  export declare class TeamsApi extends BaseApiClient {
6
6
  constructor(appName: string);
7
7
  getProfile: (params?: object) => Promise<IUserProfile>;
8
- updateEmail: (email: string) => Promise<void>;
9
- verifyEmail: (email: string, code: string) => Promise<void>;
10
8
  updateProfile: (body: Partial<IUpdateProfile>) => Promise<IUserProfile>;
11
9
  updateProfileImage: (body: FormData) => Promise<string>;
12
10
  /**
package/teams/index.js CHANGED
@@ -9,17 +9,6 @@ export class TeamsApi extends BaseApiClient {
9
9
  addRoles: true
10
10
  });
11
11
  };
12
- this.updateEmail = async email => {
13
- return this.post(`${urls.identity.users.v1}/email/me`, {
14
- email
15
- });
16
- };
17
- this.verifyEmail = async (email, code) => {
18
- return this.post(`${urls.identity.users.v1}/email/me/verify`, {
19
- email,
20
- code
21
- });
22
- };
23
12
  this.updateProfile = async body => {
24
13
  return this.put(`${urls.identity.users.v2}/me`, body);
25
14
  };
@@ -1,21 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.default = exports.UserEmailPolicyApi = void 0;
7
- var _BaseApiClient = require("../BaseApiClient");
8
- var _constants = require("../constants");
9
- class UserEmailPolicyApi extends _BaseApiClient.BaseApiClient {
10
- constructor(appName) {
11
- super(appName);
12
- this.getUserEmailPolicyConfig = async () => {
13
- return this.get(`${_constants.urls.identity.configurations.v1}/user-emails-policy`);
14
- };
15
- }
16
-
17
- /** Retrieve users email policy config. */
18
- }
19
- exports.UserEmailPolicyApi = UserEmailPolicyApi;
20
- var _default = new UserEmailPolicyApi('default');
21
- exports.default = _default;
@@ -1,5 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
@@ -1,9 +0,0 @@
1
- import { BaseApiClient } from '../BaseApiClient';
2
- import { IUserEmailPolicyConfig } from './interfaces';
3
- export declare class UserEmailPolicyApi extends BaseApiClient {
4
- constructor(appName: string);
5
- /** Retrieve users email policy config. */
6
- getUserEmailPolicyConfig: () => Promise<IUserEmailPolicyConfig>;
7
- }
8
- declare const _default: UserEmailPolicyApi;
9
- export default _default;
@@ -1,14 +0,0 @@
1
- import { BaseApiClient } from '../BaseApiClient';
2
- import { urls } from '../constants';
3
- export class UserEmailPolicyApi extends BaseApiClient {
4
- constructor(appName) {
5
- super(appName);
6
- this.getUserEmailPolicyConfig = async () => {
7
- return this.get(`${urls.identity.configurations.v1}/user-emails-policy`);
8
- };
9
- }
10
-
11
- /** Retrieve users email policy config. */
12
- }
13
-
14
- export default new UserEmailPolicyApi('default');
@@ -1,3 +0,0 @@
1
- export interface IUserEmailPolicyConfig {
2
- allowEmailChange: boolean;
3
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,6 +0,0 @@
1
- {
2
- "sideEffects": false,
3
- "module": "./index.js",
4
- "main": "../node/users-emails-policy/index.js",
5
- "types": "./index.d.ts"
6
- }