@frontegg/redux-store 5.47.0 → 5.50.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/SSOState/index.d.ts +9 -1
- package/auth/SSOState/interfaces.d.ts +5 -1
- package/auth/index.d.ts +7 -0
- package/auth/index.js +15 -0
- package/auth/reducer.d.ts +7 -0
- package/node/auth/index.js +1 -1
- package/node/{index-7ba717da.js → index-825aae6c.js} +15 -0
- package/node/index.js +1 -1
- package/node/subscriptions/index.js +4 -0
- package/node/toolkit/index.js +1 -1
- package/package.json +2 -2
- package/subscriptions/general.interfaces.d.ts +1 -0
- package/subscriptions/index.js +4 -0
package/auth/SSOState/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CreateSamlGroupPayload, DeleteSamlGroupPayload, SaveSSOConfigurationFilePayload, SaveSSOConfigurationPayload, ValidateSSODomainPayload, SSOState, SSOStateIndicator, UpdateSSOAuthorizationRolesPayload, SaveSSODomainPayload, UpdateSSOConfigurationPayload, DeleteSSOConfigurationPayload, SaveSSOConfigurationPayloadV2, UpdateSSODefaultRolesPayload, SetSSOGroupsPayload, SaveSSOConfigurationByMetadataPayload, UpdateSSOConfigurationByMetadataPayload } from './interfaces';
|
|
1
|
+
import { CreateSamlGroupPayload, DeleteSamlGroupPayload, SaveSSOConfigurationFilePayload, SaveSSOConfigurationPayload, ValidateSSODomainPayload, SSOState, SSOStateIndicator, UpdateSSOAuthorizationRolesPayload, SaveSSODomainPayload, UpdateSSOConfigurationPayload, DeleteSSOConfigurationPayload, SaveSSOConfigurationPayloadV2, UpdateSSODefaultRolesPayload, SetSSOGroupsPayload, SaveSSOConfigurationByMetadataPayload, UpdateSSOConfigurationByMetadataPayload, UpdateSSOGroupsPayload } from './interfaces';
|
|
2
2
|
import { WithCallback } from '../../interfaces';
|
|
3
3
|
import { IOidcPostLogin } from '@frontegg/rest-api';
|
|
4
4
|
declare const ssoState: SSOState;
|
|
@@ -136,6 +136,13 @@ declare const actions: {
|
|
|
136
136
|
groupsToAdd: import("@frontegg/rest-api").ICreateSamlGroup[];
|
|
137
137
|
groupsToDelete: string[];
|
|
138
138
|
}, boolean>, string, never, never>;
|
|
139
|
+
updateSSOGroups: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[WithCallback<{
|
|
140
|
+
ssoConfigId: string;
|
|
141
|
+
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
142
|
+
}, boolean>], WithCallback<{
|
|
143
|
+
ssoConfigId: string;
|
|
144
|
+
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
145
|
+
}, boolean>, string, never, never>;
|
|
139
146
|
saveSSOConfigurationByMetadata: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[WithCallback<{
|
|
140
147
|
configFile: File;
|
|
141
148
|
}, import("@frontegg/rest-api").ISSOConfiguration>], WithCallback<{
|
|
@@ -195,6 +202,7 @@ declare type DispatchedActions = {
|
|
|
195
202
|
validateSSODomainV2: (payload: ValidateSSODomainPayload) => void;
|
|
196
203
|
setSSODefaultRoles: (payload: UpdateSSODefaultRolesPayload) => void;
|
|
197
204
|
setSSOGroups: (payload: SetSSOGroupsPayload) => void;
|
|
205
|
+
updateSSOGroups: (payload: UpdateSSOGroupsPayload) => void;
|
|
198
206
|
saveSSOConfigurationByMetadata: (payload: SaveSSOConfigurationByMetadataPayload) => void;
|
|
199
207
|
updateSSOConfigurationByMetadata: (payload: UpdateSSOConfigurationByMetadataPayload) => void;
|
|
200
208
|
setSSOLoader: (payload: SSOStateIndicator) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ICreateSamlGroup, ISamlConfiguration, ISamlRolesGroup, IOidcConfiguration, ITeamUserRole, ICreateSSODomain, ISSODomain, IUpdateSamlConfiguration, ISamlMetadata, IUpdateSSOConfiguration, ISSOConfiguration } from '@frontegg/rest-api';
|
|
1
|
+
import { ICreateSamlGroup, ISamlConfiguration, ISamlRolesGroup, IOidcConfiguration, ITeamUserRole, ICreateSSODomain, ISSODomain, IUpdateSamlConfiguration, ISamlMetadata, IUpdateSSOConfiguration, ISSOConfiguration, IUpdateSamlGroup } from '@frontegg/rest-api';
|
|
2
2
|
import { WithCallback } from '../../interfaces';
|
|
3
3
|
export { ISSOConfiguration, ISSODomain };
|
|
4
4
|
export interface SSOState {
|
|
@@ -42,6 +42,10 @@ export declare enum SamlVendors {
|
|
|
42
42
|
Google = "google",
|
|
43
43
|
Oidc = "oidc"
|
|
44
44
|
}
|
|
45
|
+
export declare type UpdateSSOGroupsPayload = WithCallback<{
|
|
46
|
+
ssoConfigId: string;
|
|
47
|
+
changedGroups: IUpdateSamlGroup[];
|
|
48
|
+
}>;
|
|
45
49
|
export declare type SetSSOGroupsPayload = WithCallback<{
|
|
46
50
|
ssoConfigId: string;
|
|
47
51
|
groupsToAdd: ICreateSamlGroup[];
|
package/auth/index.d.ts
CHANGED
|
@@ -171,6 +171,13 @@ declare const _default: {
|
|
|
171
171
|
groupsToAdd: import("@frontegg/rest-api").ICreateSamlGroup[];
|
|
172
172
|
groupsToDelete: string[];
|
|
173
173
|
}, boolean>, string, never, never>;
|
|
174
|
+
updateSSOGroups: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[import("../interfaces").WithCallback<{
|
|
175
|
+
ssoConfigId: string;
|
|
176
|
+
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
177
|
+
}, boolean>], import("../interfaces").WithCallback<{
|
|
178
|
+
ssoConfigId: string;
|
|
179
|
+
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
180
|
+
}, boolean>, string, never, never>;
|
|
174
181
|
saveSSOConfigurationByMetadata: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[import("../interfaces").WithCallback<{
|
|
175
182
|
configFile: File;
|
|
176
183
|
}, import("@frontegg/rest-api/dist/auth/interfaces").ISSOConfiguration>], import("../interfaces").WithCallback<{
|
package/auth/index.js
CHANGED
|
@@ -204,6 +204,7 @@ const actions$b = {
|
|
|
204
204
|
validateSSODomainV2: createAction(`${authStoreName}/validateSSODomainV2`, (payload) => ({ payload })),
|
|
205
205
|
setSSODefaultRoles: createAction(`${authStoreName}/setSSODefaultRoles`, (payload) => ({ payload })),
|
|
206
206
|
setSSOGroups: createAction(`${authStoreName}/setSSOGroups`, (payload) => ({ payload })),
|
|
207
|
+
updateSSOGroups: createAction(`${authStoreName}/updateSSOGroups`, (payload) => ({ payload })),
|
|
207
208
|
saveSSOConfigurationByMetadata: createAction(`${authStoreName}/saveSSOConfigurationByMetadata`, (payload) => ({ payload })),
|
|
208
209
|
updateSSOConfigurationByMetadata: createAction(`${authStoreName}/updateSSOConfigurationByMetadata`, (payload) => ({ payload })),
|
|
209
210
|
loadSSOConfigurations: createAction(`${authStoreName}/loadSSOConfigurations`),
|
|
@@ -1922,6 +1923,19 @@ function* setSSOGroups({ payload: { groupsToAdd, groupsToDelete, ssoConfigId, ca
|
|
|
1922
1923
|
yield put(actions.setSSOLoader({ key: SSOStateKeys.SAVE_SSO_GROUPS, value: false }));
|
|
1923
1924
|
}
|
|
1924
1925
|
}
|
|
1926
|
+
function* updateSSOGroups({ payload: { ssoConfigId, changedGroups, callback } }) {
|
|
1927
|
+
try {
|
|
1928
|
+
yield all(changedGroups.map((group) => call(api.auth.updateSSOGroup, ssoConfigId, group)));
|
|
1929
|
+
callback === null || callback === void 0 ? void 0 : callback(true);
|
|
1930
|
+
}
|
|
1931
|
+
catch (error) {
|
|
1932
|
+
yield put(actions.setSSOError({ key: SSOStateKeys.SAVE_SSO_GROUPS, value: error.message }));
|
|
1933
|
+
callback === null || callback === void 0 ? void 0 : callback(null, error);
|
|
1934
|
+
}
|
|
1935
|
+
finally {
|
|
1936
|
+
yield put(actions.setSSOLoader({ key: SSOStateKeys.SAVE_SSO_GROUPS, value: false }));
|
|
1937
|
+
}
|
|
1938
|
+
}
|
|
1925
1939
|
function* ssoSagas() {
|
|
1926
1940
|
yield takeEvery(actions.loadSSOConfigurationsV2, loadSSOConfigurationsV2);
|
|
1927
1941
|
yield takeEvery(actions.saveSSOConfigurationV2, saveSSOConfigurationV2);
|
|
@@ -1931,6 +1945,7 @@ function* ssoSagas() {
|
|
|
1931
1945
|
yield takeEvery(actions.updateSSOConfiguration, updateSSOConfiguration);
|
|
1932
1946
|
yield takeEvery(actions.deleteSSOConfiguration, deleteSSOConfiguration);
|
|
1933
1947
|
yield takeEvery(actions.setSSOGroups, setSSOGroups);
|
|
1948
|
+
yield takeEvery(actions.updateSSOGroups, updateSSOGroups);
|
|
1934
1949
|
yield takeEvery(actions.setSSODefaultRoles, setSSODefaultRoles);
|
|
1935
1950
|
yield takeEvery(actions.saveSSOConfigurationByMetadata, saveSSOConfigurationByMetadata);
|
|
1936
1951
|
yield takeEvery(actions.updateSSOConfigurationByMetadata, updateSSOConfigurationByMetadata);
|
package/auth/reducer.d.ts
CHANGED
|
@@ -144,6 +144,13 @@ declare const actions: {
|
|
|
144
144
|
groupsToAdd: import("@frontegg/rest-api").ICreateSamlGroup[];
|
|
145
145
|
groupsToDelete: string[];
|
|
146
146
|
}, boolean>, string, never, never>;
|
|
147
|
+
updateSSOGroups: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[import("../interfaces").WithCallback<{
|
|
148
|
+
ssoConfigId: string;
|
|
149
|
+
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
150
|
+
}, boolean>], import("../interfaces").WithCallback<{
|
|
151
|
+
ssoConfigId: string;
|
|
152
|
+
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
153
|
+
}, boolean>, string, never, never>;
|
|
147
154
|
saveSSOConfigurationByMetadata: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[import("../interfaces").WithCallback<{
|
|
148
155
|
configFile: File;
|
|
149
156
|
}, import("@frontegg/rest-api").ISSOConfiguration>], import("../interfaces").WithCallback<{
|
package/node/auth/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var auth_index = require('../index-
|
|
5
|
+
var auth_index = require('../index-825aae6c.js');
|
|
6
6
|
var constants = require('../constants-52e37c08.js');
|
|
7
7
|
var restApi = require('@frontegg/rest-api');
|
|
8
8
|
require('@reduxjs/toolkit');
|
|
@@ -213,6 +213,7 @@ const actions$b = {
|
|
|
213
213
|
validateSSODomainV2: toolkit.createAction(`${constants.authStoreName}/validateSSODomainV2`, (payload) => ({ payload })),
|
|
214
214
|
setSSODefaultRoles: toolkit.createAction(`${constants.authStoreName}/setSSODefaultRoles`, (payload) => ({ payload })),
|
|
215
215
|
setSSOGroups: toolkit.createAction(`${constants.authStoreName}/setSSOGroups`, (payload) => ({ payload })),
|
|
216
|
+
updateSSOGroups: toolkit.createAction(`${constants.authStoreName}/updateSSOGroups`, (payload) => ({ payload })),
|
|
216
217
|
saveSSOConfigurationByMetadata: toolkit.createAction(`${constants.authStoreName}/saveSSOConfigurationByMetadata`, (payload) => ({ payload })),
|
|
217
218
|
updateSSOConfigurationByMetadata: toolkit.createAction(`${constants.authStoreName}/updateSSOConfigurationByMetadata`, (payload) => ({ payload })),
|
|
218
219
|
loadSSOConfigurations: toolkit.createAction(`${constants.authStoreName}/loadSSOConfigurations`),
|
|
@@ -1931,6 +1932,19 @@ function* setSSOGroups({ payload: { groupsToAdd, groupsToDelete, ssoConfigId, ca
|
|
|
1931
1932
|
yield effects.put(actions.setSSOLoader({ key: exports.SSOStateKeys.SAVE_SSO_GROUPS, value: false }));
|
|
1932
1933
|
}
|
|
1933
1934
|
}
|
|
1935
|
+
function* updateSSOGroups({ payload: { ssoConfigId, changedGroups, callback } }) {
|
|
1936
|
+
try {
|
|
1937
|
+
yield effects.all(changedGroups.map((group) => effects.call(restApi.api.auth.updateSSOGroup, ssoConfigId, group)));
|
|
1938
|
+
callback === null || callback === void 0 ? void 0 : callback(true);
|
|
1939
|
+
}
|
|
1940
|
+
catch (error) {
|
|
1941
|
+
yield effects.put(actions.setSSOError({ key: exports.SSOStateKeys.SAVE_SSO_GROUPS, value: error.message }));
|
|
1942
|
+
callback === null || callback === void 0 ? void 0 : callback(null, error);
|
|
1943
|
+
}
|
|
1944
|
+
finally {
|
|
1945
|
+
yield effects.put(actions.setSSOLoader({ key: exports.SSOStateKeys.SAVE_SSO_GROUPS, value: false }));
|
|
1946
|
+
}
|
|
1947
|
+
}
|
|
1934
1948
|
function* ssoSagas() {
|
|
1935
1949
|
yield effects.takeEvery(actions.loadSSOConfigurationsV2, loadSSOConfigurationsV2);
|
|
1936
1950
|
yield effects.takeEvery(actions.saveSSOConfigurationV2, saveSSOConfigurationV2);
|
|
@@ -1940,6 +1954,7 @@ function* ssoSagas() {
|
|
|
1940
1954
|
yield effects.takeEvery(actions.updateSSOConfiguration, updateSSOConfiguration);
|
|
1941
1955
|
yield effects.takeEvery(actions.deleteSSOConfiguration, deleteSSOConfiguration);
|
|
1942
1956
|
yield effects.takeEvery(actions.setSSOGroups, setSSOGroups);
|
|
1957
|
+
yield effects.takeEvery(actions.updateSSOGroups, updateSSOGroups);
|
|
1943
1958
|
yield effects.takeEvery(actions.setSSODefaultRoles, setSSODefaultRoles);
|
|
1944
1959
|
yield effects.takeEvery(actions.saveSSOConfigurationByMetadata, saveSSOConfigurationByMetadata);
|
|
1945
1960
|
yield effects.takeEvery(actions.updateSSOConfigurationByMetadata, updateSSOConfigurationByMetadata);
|
package/node/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var auth_index = require('./index-
|
|
5
|
+
var auth_index = require('./index-825aae6c.js');
|
|
6
6
|
var audits_index = require('./audits/index.js');
|
|
7
7
|
var connectivity_index = require('./connectivity/index.js');
|
|
8
8
|
var subscriptions_index = require('./subscriptions/index.js');
|
|
@@ -283,6 +283,7 @@ const planResponseMock = [
|
|
|
283
283
|
currency: 'usd',
|
|
284
284
|
amount: 10000,
|
|
285
285
|
},
|
|
286
|
+
slug: 'premium',
|
|
286
287
|
},
|
|
287
288
|
{
|
|
288
289
|
id: 'prod_J60duauCpXfcur',
|
|
@@ -295,6 +296,7 @@ const planResponseMock = [
|
|
|
295
296
|
currency: 'usd',
|
|
296
297
|
amount: 0,
|
|
297
298
|
},
|
|
299
|
+
slug: 'free',
|
|
298
300
|
},
|
|
299
301
|
];
|
|
300
302
|
const invoicesMock = [
|
|
@@ -480,6 +482,7 @@ function* loadSummaries(tenantId, forceActive) {
|
|
|
480
482
|
price: ((_a = planResponse.price) === null || _a === void 0 ? void 0 : _a.amount) || 0,
|
|
481
483
|
currency: ((_b = planResponse.price) === null || _b === void 0 ? void 0 : _b.currency) || 'usd',
|
|
482
484
|
recurringInterval: 'month',
|
|
485
|
+
slug: planResponse.slug,
|
|
483
486
|
},
|
|
484
487
|
}
|
|
485
488
|
: {}))));
|
|
@@ -761,6 +764,7 @@ function* loadPlans() {
|
|
|
761
764
|
price: ((_a = item.price) === null || _a === void 0 ? void 0 : _a.amount) || 0,
|
|
762
765
|
currency: ((_b = item.price) === null || _b === void 0 ? void 0 : _b.currency) || 'usd',
|
|
763
766
|
recurringInterval: 'month',
|
|
767
|
+
slug: item.slug,
|
|
764
768
|
});
|
|
765
769
|
});
|
|
766
770
|
yield effects.put(actions$8.setState({
|
package/node/toolkit/index.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var auth_index = require('../index-
|
|
5
|
+
var auth_index = require('../index-825aae6c.js');
|
|
6
6
|
var toolkit = require('@reduxjs/toolkit');
|
|
7
7
|
var createSagaMiddleware = require('redux-saga');
|
|
8
8
|
var effects = require('redux-saga/effects');
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@frontegg/redux-store",
|
|
3
3
|
"libName": "FronteggReduxStore",
|
|
4
|
-
"version": "5.
|
|
4
|
+
"version": "5.50.0",
|
|
5
5
|
"author": "Frontegg LTD",
|
|
6
6
|
"main": "./node/index.js",
|
|
7
7
|
"module": "./index.js",
|
|
8
8
|
"types": "./index.d.ts",
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@frontegg/rest-api": "2.10.
|
|
10
|
+
"@frontegg/rest-api": "2.10.67",
|
|
11
11
|
"@reduxjs/toolkit": "^1.5.0",
|
|
12
12
|
"redux-saga": "^1.1.0",
|
|
13
13
|
"tslib": "^2.3.1",
|
package/subscriptions/index.js
CHANGED
|
@@ -280,6 +280,7 @@ const planResponseMock = [
|
|
|
280
280
|
currency: 'usd',
|
|
281
281
|
amount: 10000,
|
|
282
282
|
},
|
|
283
|
+
slug: 'premium',
|
|
283
284
|
},
|
|
284
285
|
{
|
|
285
286
|
id: 'prod_J60duauCpXfcur',
|
|
@@ -292,6 +293,7 @@ const planResponseMock = [
|
|
|
292
293
|
currency: 'usd',
|
|
293
294
|
amount: 0,
|
|
294
295
|
},
|
|
296
|
+
slug: 'free',
|
|
295
297
|
},
|
|
296
298
|
];
|
|
297
299
|
const invoicesMock = [
|
|
@@ -477,6 +479,7 @@ function* loadSummaries(tenantId, forceActive) {
|
|
|
477
479
|
price: ((_a = planResponse.price) === null || _a === void 0 ? void 0 : _a.amount) || 0,
|
|
478
480
|
currency: ((_b = planResponse.price) === null || _b === void 0 ? void 0 : _b.currency) || 'usd',
|
|
479
481
|
recurringInterval: 'month',
|
|
482
|
+
slug: planResponse.slug,
|
|
480
483
|
},
|
|
481
484
|
}
|
|
482
485
|
: {}))));
|
|
@@ -758,6 +761,7 @@ function* loadPlans() {
|
|
|
758
761
|
price: ((_a = item.price) === null || _a === void 0 ? void 0 : _a.amount) || 0,
|
|
759
762
|
currency: ((_b = item.price) === null || _b === void 0 ? void 0 : _b.currency) || 'usd',
|
|
760
763
|
recurringInterval: 'month',
|
|
764
|
+
slug: item.slug,
|
|
761
765
|
});
|
|
762
766
|
});
|
|
763
767
|
yield put(actions$8.setState({
|