@flipdish/authorization 0.2.32 → 0.2.33

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/api.js CHANGED
@@ -84,7 +84,8 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
84
84
  return to.concat(ar || Array.prototype.slice.call(from));
85
85
  };
86
86
  Object.defineProperty(exports, "__esModule", { value: true });
87
- exports.UserPermissionsApi = exports.UserPermissionsApiFactory = exports.UserPermissionsApiFp = exports.UserPermissionsApiAxiosParamCreator = exports.UserManagementApi = exports.UserManagementApiFactory = exports.UserManagementApiFp = exports.UserManagementApiAxiosParamCreator = exports.RoleAssignmentApi = exports.RoleAssignmentApiFactory = exports.RoleAssignmentApiFp = exports.RoleAssignmentApiAxiosParamCreator = exports.ConfigurationDataApi = exports.ConfigurationDataApiFactory = exports.ConfigurationDataApiFp = exports.ConfigurationDataApiAxiosParamCreator = exports.AuthorizedEntitiesApi = exports.AuthorizedEntitiesApiFactory = exports.AuthorizedEntitiesApiFp = exports.AuthorizedEntitiesApiAxiosParamCreator = exports.AuthorizationApi = exports.AuthorizationApiFactory = exports.AuthorizationApiFp = exports.AuthorizationApiAxiosParamCreator = exports.AuthenticationApi = exports.AuthenticationApiFactory = exports.AuthenticationApiFp = exports.AuthenticationApiAxiosParamCreator = exports.RoleNames = exports.RevokeRoleRequestBodyRoleEnum = exports.RevokeForbiddenRoleRequestBodyCompensatingRoleEnum = exports.Permissions = exports.ListOrgRolesSuccessResponseValueValueRolesEnum = exports.ListOrgRolesSuccessResponseValueValueResourceTypeEnum = exports.IsInRoleRequestCheckModeEnum = exports.GetUserPermissionsSuccessResponseResourcesValueResourceTypeEnum = exports.GetPrincipalRolesSuccessResponseRolesInnerPrincipalTypeEnum = exports.GetPrincipalRolesSuccessResponseRolesInnerResourceTypeEnum = exports.GetPrincipalRolesSuccessResponseRolesInnerPolicyTypeEnum = exports.GetAuthorizedOrgsRequestPrincipalTypeEnum = exports.AuthorizationRequestResourceOneOf3TypeEnum = exports.AuthorizationRequestResourceOneOf2TypeEnum = exports.AuthorizationRequestResourceOneOf1TypeEnum = exports.AuthorizationRequestResourceOneOfTypeEnum = exports.AuthorizationRequestPrincipalTypeEnum = exports.AuthorizationRequestCheckModeEnum = exports.AuthenticateAndCheckIsInRoleRequestCheckModeEnum = exports.AuthenticateAndAuthorizeRequestCheckModeEnum = exports.AssignRoleRequestBodyRoleEnum = void 0;
87
+ exports.UserPermissionsApiFp = exports.UserPermissionsApiAxiosParamCreator = exports.UserManagementApi = exports.UserManagementApiFactory = exports.UserManagementApiFp = exports.UserManagementApiAxiosParamCreator = exports.RoleAssignmentApi = exports.RoleAssignmentApiFactory = exports.RoleAssignmentApiFp = exports.RoleAssignmentApiAxiosParamCreator = exports.ConfigurationDataApi = exports.ConfigurationDataApiFactory = exports.ConfigurationDataApiFp = exports.ConfigurationDataApiAxiosParamCreator = exports.AuthorizedEntitiesApi = exports.AuthorizedEntitiesApiFactory = exports.AuthorizedEntitiesApiFp = exports.AuthorizedEntitiesApiAxiosParamCreator = exports.AuthorizationApi = exports.AuthorizationApiFactory = exports.AuthorizationApiFp = exports.AuthorizationApiAxiosParamCreator = exports.AuthenticationApi = exports.AuthenticationApiFactory = exports.AuthenticationApiFp = exports.AuthenticationApiAxiosParamCreator = exports.UpdateTeammateAccessRequestBodyAppAccessLevelEnum = exports.RoleNames = exports.RevokeRoleRequestBodyRoleEnum = exports.RevokeForbiddenRoleRequestBodyCompensatingRoleEnum = exports.PrincipalInOrgWithTeammatePermissionSummaryTypeEnum = exports.Permissions = exports.ListOrgRolesSuccessResponseValueValueRolesEnum = exports.ListOrgRolesSuccessResponseValueValueResourceTypeEnum = exports.IsInRoleRequestCheckModeEnum = exports.GrantTeammateAccessRequestBodyAppAccessLevelEnum = exports.GetUserPermissionsSuccessResponseResourcesValueResourceTypeEnum = exports.GetPrincipalRolesSuccessResponseRolesInnerPrincipalTypeEnum = exports.GetPrincipalRolesSuccessResponseRolesInnerResourceTypeEnum = exports.GetPrincipalRolesSuccessResponseRolesInnerPolicyTypeEnum = exports.GetAuthorizedOrgsRequestPrincipalTypeEnum = exports.AuthorizationRequestResourceOneOf3TypeEnum = exports.AuthorizationRequestResourceOneOf2TypeEnum = exports.AuthorizationRequestResourceOneOf1TypeEnum = exports.AuthorizationRequestResourceOneOfTypeEnum = exports.AuthorizationRequestPrincipalTypeEnum = exports.AuthorizationRequestCheckModeEnum = exports.AuthenticateAndCheckIsInRoleRequestCheckModeEnum = exports.AuthenticateAndAuthorizeRequestCheckModeEnum = exports.AssignRoleRequestBodyRoleEnum = void 0;
88
+ exports.UserPermissionsApi = exports.UserPermissionsApiFactory = void 0;
88
89
  var axios_1 = require("axios");
89
90
  // Some imports not used depending on template conditions
90
91
  // @ts-ignore
@@ -220,6 +221,14 @@ exports.GetUserPermissionsSuccessResponseResourcesValueResourceTypeEnum = {
220
221
  Brand: 'Brand',
221
222
  SalesChannel: 'SalesChannel'
222
223
  };
224
+ exports.GrantTeammateAccessRequestBodyAppAccessLevelEnum = {
225
+ Owner: 'Owner',
226
+ ManagedOwner: 'ManagedOwner',
227
+ PropertyOwner: 'PropertyOwner',
228
+ PropertyManager: 'PropertyManager',
229
+ FinanceManager: 'FinanceManager',
230
+ Integrator: 'Integrator'
231
+ };
223
232
  exports.IsInRoleRequestCheckModeEnum = {
224
233
  Any: 'any',
225
234
  All: 'all'
@@ -540,6 +549,10 @@ exports.Permissions = {
540
549
  RoleFactory: 'RoleFactory',
541
550
  RoleAuthDeveloper: 'RoleAuthDeveloper'
542
551
  };
552
+ exports.PrincipalInOrgWithTeammatePermissionSummaryTypeEnum = {
553
+ User: 'User',
554
+ Automation: 'Automation'
555
+ };
543
556
  exports.RevokeForbiddenRoleRequestBodyCompensatingRoleEnum = {
544
557
  OwnerCompensating: 'OwnerCompensating',
545
558
  PropertyOwnerCompensating: 'PropertyOwnerCompensating',
@@ -632,6 +645,14 @@ exports.RoleNames = {
632
645
  Factory: 'Factory',
633
646
  AuthDeveloper: 'AuthDeveloper'
634
647
  };
648
+ exports.UpdateTeammateAccessRequestBodyAppAccessLevelEnum = {
649
+ Owner: 'Owner',
650
+ ManagedOwner: 'ManagedOwner',
651
+ PropertyOwner: 'PropertyOwner',
652
+ PropertyManager: 'PropertyManager',
653
+ FinanceManager: 'FinanceManager',
654
+ Integrator: 'Integrator'
655
+ };
635
656
  /**
636
657
  * AuthenticationApi - axios parameter creator
637
658
  * @export
@@ -2228,6 +2249,58 @@ var RoleAssignmentApiAxiosParamCreator = function (configuration) {
2228
2249
  });
2229
2250
  });
2230
2251
  },
2252
+ /**
2253
+ * Grant teammate app access and underlying permissions for a user being assigned within a brand for the first time. Email and name are persisted on first assignment only and must be supplied here.
2254
+ * @summary Grant teammate access to a new user
2255
+ * @param {string} orgId
2256
+ * @param {string} userId Target Flipdish user id (numeric string)
2257
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
2258
+ * @param {*} [options] Override http request option.
2259
+ * @throws {RequiredError}
2260
+ */
2261
+ grantTeammateAccess: function (orgId_1, userId_1, grantTeammateAccessRequestBody_1) {
2262
+ var args_1 = [];
2263
+ for (var _i = 3; _i < arguments.length; _i++) {
2264
+ args_1[_i - 3] = arguments[_i];
2265
+ }
2266
+ return __awaiter(_this, __spreadArray([orgId_1, userId_1, grantTeammateAccessRequestBody_1], args_1, true), void 0, function (orgId, userId, grantTeammateAccessRequestBody, options) {
2267
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
2268
+ if (options === void 0) { options = {}; }
2269
+ return __generator(this, function (_a) {
2270
+ switch (_a.label) {
2271
+ case 0:
2272
+ // verify required parameter 'orgId' is not null or undefined
2273
+ (0, common_1.assertParamExists)('grantTeammateAccess', 'orgId', orgId);
2274
+ // verify required parameter 'userId' is not null or undefined
2275
+ (0, common_1.assertParamExists)('grantTeammateAccess', 'userId', userId);
2276
+ localVarPath = "/orgs/{orgId}/users/{userId}/grantTeammateAccess"
2277
+ .replace("{".concat("orgId", "}"), encodeURIComponent(String(orgId)))
2278
+ .replace("{".concat("userId", "}"), encodeURIComponent(String(userId)));
2279
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
2280
+ if (configuration) {
2281
+ baseOptions = configuration.baseOptions;
2282
+ }
2283
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
2284
+ localVarHeaderParameter = {};
2285
+ localVarQueryParameter = {};
2286
+ // authentication ApiKeyAuth required
2287
+ return [4 /*yield*/, (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration)];
2288
+ case 1:
2289
+ // authentication ApiKeyAuth required
2290
+ _a.sent();
2291
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2292
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
2293
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2294
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
2295
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(grantTeammateAccessRequestBody, localVarRequestOptions, configuration);
2296
+ return [2 /*return*/, {
2297
+ url: (0, common_1.toPathString)(localVarUrlObj),
2298
+ options: localVarRequestOptions,
2299
+ }];
2300
+ }
2301
+ });
2302
+ });
2303
+ },
2231
2304
  /**
2232
2305
  * Revokes a forbidden role from a given principal (user, group, etc.)
2233
2306
  * @summary Revoke Forbidden Role from Principal
@@ -2324,6 +2397,58 @@ var RoleAssignmentApiAxiosParamCreator = function (configuration) {
2324
2397
  });
2325
2398
  });
2326
2399
  },
2400
+ /**
2401
+ * Update teammate app access and underlying permissions for an existing teammate. The user must already have been granted access for this brand. Email and name are not accepted on update; existing values are reused. Returns 404 if no existing assignment is found.
2402
+ * @summary Update teammate access for an existing user
2403
+ * @param {string} orgId
2404
+ * @param {string} userId Target Flipdish user id (numeric string)
2405
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
2406
+ * @param {*} [options] Override http request option.
2407
+ * @throws {RequiredError}
2408
+ */
2409
+ updateTeammateAccess: function (orgId_1, userId_1, updateTeammateAccessRequestBody_1) {
2410
+ var args_1 = [];
2411
+ for (var _i = 3; _i < arguments.length; _i++) {
2412
+ args_1[_i - 3] = arguments[_i];
2413
+ }
2414
+ return __awaiter(_this, __spreadArray([orgId_1, userId_1, updateTeammateAccessRequestBody_1], args_1, true), void 0, function (orgId, userId, updateTeammateAccessRequestBody, options) {
2415
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
2416
+ if (options === void 0) { options = {}; }
2417
+ return __generator(this, function (_a) {
2418
+ switch (_a.label) {
2419
+ case 0:
2420
+ // verify required parameter 'orgId' is not null or undefined
2421
+ (0, common_1.assertParamExists)('updateTeammateAccess', 'orgId', orgId);
2422
+ // verify required parameter 'userId' is not null or undefined
2423
+ (0, common_1.assertParamExists)('updateTeammateAccess', 'userId', userId);
2424
+ localVarPath = "/orgs/{orgId}/users/{userId}/updateTeammateAccess"
2425
+ .replace("{".concat("orgId", "}"), encodeURIComponent(String(orgId)))
2426
+ .replace("{".concat("userId", "}"), encodeURIComponent(String(userId)));
2427
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
2428
+ if (configuration) {
2429
+ baseOptions = configuration.baseOptions;
2430
+ }
2431
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
2432
+ localVarHeaderParameter = {};
2433
+ localVarQueryParameter = {};
2434
+ // authentication ApiKeyAuth required
2435
+ return [4 /*yield*/, (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration)];
2436
+ case 1:
2437
+ // authentication ApiKeyAuth required
2438
+ _a.sent();
2439
+ localVarHeaderParameter['Content-Type'] = 'application/json';
2440
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
2441
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2442
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
2443
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(updateTeammateAccessRequestBody, localVarRequestOptions, configuration);
2444
+ return [2 /*return*/, {
2445
+ url: (0, common_1.toPathString)(localVarUrlObj),
2446
+ options: localVarRequestOptions,
2447
+ }];
2448
+ }
2449
+ });
2450
+ });
2451
+ },
2327
2452
  };
2328
2453
  };
2329
2454
  exports.RoleAssignmentApiAxiosParamCreator = RoleAssignmentApiAxiosParamCreator;
@@ -2382,6 +2507,31 @@ var RoleAssignmentApiFp = function (configuration) {
2382
2507
  });
2383
2508
  });
2384
2509
  },
2510
+ /**
2511
+ * Grant teammate app access and underlying permissions for a user being assigned within a brand for the first time. Email and name are persisted on first assignment only and must be supplied here.
2512
+ * @summary Grant teammate access to a new user
2513
+ * @param {string} orgId
2514
+ * @param {string} userId Target Flipdish user id (numeric string)
2515
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
2516
+ * @param {*} [options] Override http request option.
2517
+ * @throws {RequiredError}
2518
+ */
2519
+ grantTeammateAccess: function (orgId, userId, grantTeammateAccessRequestBody, options) {
2520
+ return __awaiter(this, void 0, void 0, function () {
2521
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
2522
+ var _a, _b, _c;
2523
+ return __generator(this, function (_d) {
2524
+ switch (_d.label) {
2525
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.grantTeammateAccess(orgId, userId, grantTeammateAccessRequestBody, options)];
2526
+ case 1:
2527
+ localVarAxiosArgs = _d.sent();
2528
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
2529
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['RoleAssignmentApi.grantTeammateAccess']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
2530
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
2531
+ }
2532
+ });
2533
+ });
2534
+ },
2385
2535
  /**
2386
2536
  * Revokes a forbidden role from a given principal (user, group, etc.)
2387
2537
  * @summary Revoke Forbidden Role from Principal
@@ -2430,6 +2580,31 @@ var RoleAssignmentApiFp = function (configuration) {
2430
2580
  });
2431
2581
  });
2432
2582
  },
2583
+ /**
2584
+ * Update teammate app access and underlying permissions for an existing teammate. The user must already have been granted access for this brand. Email and name are not accepted on update; existing values are reused. Returns 404 if no existing assignment is found.
2585
+ * @summary Update teammate access for an existing user
2586
+ * @param {string} orgId
2587
+ * @param {string} userId Target Flipdish user id (numeric string)
2588
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
2589
+ * @param {*} [options] Override http request option.
2590
+ * @throws {RequiredError}
2591
+ */
2592
+ updateTeammateAccess: function (orgId, userId, updateTeammateAccessRequestBody, options) {
2593
+ return __awaiter(this, void 0, void 0, function () {
2594
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
2595
+ var _a, _b, _c;
2596
+ return __generator(this, function (_d) {
2597
+ switch (_d.label) {
2598
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.updateTeammateAccess(orgId, userId, updateTeammateAccessRequestBody, options)];
2599
+ case 1:
2600
+ localVarAxiosArgs = _d.sent();
2601
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
2602
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['RoleAssignmentApi.updateTeammateAccess']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
2603
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
2604
+ }
2605
+ });
2606
+ });
2607
+ },
2433
2608
  };
2434
2609
  };
2435
2610
  exports.RoleAssignmentApiFp = RoleAssignmentApiFp;
@@ -2462,6 +2637,18 @@ var RoleAssignmentApiFactory = function (configuration, basePath, axios) {
2462
2637
  getPrincipalRoles: function (orgId, getPrincipalRolesRequestBody, options) {
2463
2638
  return localVarFp.getPrincipalRoles(orgId, getPrincipalRolesRequestBody, options).then(function (request) { return request(axios, basePath); });
2464
2639
  },
2640
+ /**
2641
+ * Grant teammate app access and underlying permissions for a user being assigned within a brand for the first time. Email and name are persisted on first assignment only and must be supplied here.
2642
+ * @summary Grant teammate access to a new user
2643
+ * @param {string} orgId
2644
+ * @param {string} userId Target Flipdish user id (numeric string)
2645
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
2646
+ * @param {*} [options] Override http request option.
2647
+ * @throws {RequiredError}
2648
+ */
2649
+ grantTeammateAccess: function (orgId, userId, grantTeammateAccessRequestBody, options) {
2650
+ return localVarFp.grantTeammateAccess(orgId, userId, grantTeammateAccessRequestBody, options).then(function (request) { return request(axios, basePath); });
2651
+ },
2465
2652
  /**
2466
2653
  * Revokes a forbidden role from a given principal (user, group, etc.)
2467
2654
  * @summary Revoke Forbidden Role from Principal
@@ -2484,6 +2671,18 @@ var RoleAssignmentApiFactory = function (configuration, basePath, axios) {
2484
2671
  revokeRoleFromPrincipal: function (orgId, revokeRoleRequestBody, options) {
2485
2672
  return localVarFp.revokeRoleFromPrincipal(orgId, revokeRoleRequestBody, options).then(function (request) { return request(axios, basePath); });
2486
2673
  },
2674
+ /**
2675
+ * Update teammate app access and underlying permissions for an existing teammate. The user must already have been granted access for this brand. Email and name are not accepted on update; existing values are reused. Returns 404 if no existing assignment is found.
2676
+ * @summary Update teammate access for an existing user
2677
+ * @param {string} orgId
2678
+ * @param {string} userId Target Flipdish user id (numeric string)
2679
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
2680
+ * @param {*} [options] Override http request option.
2681
+ * @throws {RequiredError}
2682
+ */
2683
+ updateTeammateAccess: function (orgId, userId, updateTeammateAccessRequestBody, options) {
2684
+ return localVarFp.updateTeammateAccess(orgId, userId, updateTeammateAccessRequestBody, options).then(function (request) { return request(axios, basePath); });
2685
+ },
2487
2686
  };
2488
2687
  };
2489
2688
  exports.RoleAssignmentApiFactory = RoleAssignmentApiFactory;
@@ -2524,6 +2723,20 @@ var RoleAssignmentApi = /** @class */ (function (_super) {
2524
2723
  var _this = this;
2525
2724
  return (0, exports.RoleAssignmentApiFp)(this.configuration).getPrincipalRoles(orgId, getPrincipalRolesRequestBody, options).then(function (request) { return request(_this.axios, _this.basePath); });
2526
2725
  };
2726
+ /**
2727
+ * Grant teammate app access and underlying permissions for a user being assigned within a brand for the first time. Email and name are persisted on first assignment only and must be supplied here.
2728
+ * @summary Grant teammate access to a new user
2729
+ * @param {string} orgId
2730
+ * @param {string} userId Target Flipdish user id (numeric string)
2731
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
2732
+ * @param {*} [options] Override http request option.
2733
+ * @throws {RequiredError}
2734
+ * @memberof RoleAssignmentApi
2735
+ */
2736
+ RoleAssignmentApi.prototype.grantTeammateAccess = function (orgId, userId, grantTeammateAccessRequestBody, options) {
2737
+ var _this = this;
2738
+ return (0, exports.RoleAssignmentApiFp)(this.configuration).grantTeammateAccess(orgId, userId, grantTeammateAccessRequestBody, options).then(function (request) { return request(_this.axios, _this.basePath); });
2739
+ };
2527
2740
  /**
2528
2741
  * Revokes a forbidden role from a given principal (user, group, etc.)
2529
2742
  * @summary Revoke Forbidden Role from Principal
@@ -2550,6 +2763,20 @@ var RoleAssignmentApi = /** @class */ (function (_super) {
2550
2763
  var _this = this;
2551
2764
  return (0, exports.RoleAssignmentApiFp)(this.configuration).revokeRoleFromPrincipal(orgId, revokeRoleRequestBody, options).then(function (request) { return request(_this.axios, _this.basePath); });
2552
2765
  };
2766
+ /**
2767
+ * Update teammate app access and underlying permissions for an existing teammate. The user must already have been granted access for this brand. Email and name are not accepted on update; existing values are reused. Returns 404 if no existing assignment is found.
2768
+ * @summary Update teammate access for an existing user
2769
+ * @param {string} orgId
2770
+ * @param {string} userId Target Flipdish user id (numeric string)
2771
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
2772
+ * @param {*} [options] Override http request option.
2773
+ * @throws {RequiredError}
2774
+ * @memberof RoleAssignmentApi
2775
+ */
2776
+ RoleAssignmentApi.prototype.updateTeammateAccess = function (orgId, userId, updateTeammateAccessRequestBody, options) {
2777
+ var _this = this;
2778
+ return (0, exports.RoleAssignmentApiFp)(this.configuration).updateTeammateAccess(orgId, userId, updateTeammateAccessRequestBody, options).then(function (request) { return request(_this.axios, _this.basePath); });
2779
+ };
2553
2780
  return RoleAssignmentApi;
2554
2781
  }(base_1.BaseAPI));
2555
2782
  exports.RoleAssignmentApi = RoleAssignmentApi;
@@ -2605,6 +2832,51 @@ var UserManagementApiAxiosParamCreator = function (configuration) {
2605
2832
  });
2606
2833
  });
2607
2834
  },
2835
+ /**
2836
+ * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
2837
+ * @summary List Users in Org with teammate permission summary
2838
+ * @param {string} orgId
2839
+ * @param {*} [options] Override http request option.
2840
+ * @throws {RequiredError}
2841
+ */
2842
+ listUsersInOrgWithTeammatePermissionSummary: function (orgId_1) {
2843
+ var args_1 = [];
2844
+ for (var _i = 1; _i < arguments.length; _i++) {
2845
+ args_1[_i - 1] = arguments[_i];
2846
+ }
2847
+ return __awaiter(_this, __spreadArray([orgId_1], args_1, true), void 0, function (orgId, options) {
2848
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
2849
+ if (options === void 0) { options = {}; }
2850
+ return __generator(this, function (_a) {
2851
+ switch (_a.label) {
2852
+ case 0:
2853
+ // verify required parameter 'orgId' is not null or undefined
2854
+ (0, common_1.assertParamExists)('listUsersInOrgWithTeammatePermissionSummary', 'orgId', orgId);
2855
+ localVarPath = "/orgs/{orgId}/users/teammatePermissionSummary"
2856
+ .replace("{".concat("orgId", "}"), encodeURIComponent(String(orgId)));
2857
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
2858
+ if (configuration) {
2859
+ baseOptions = configuration.baseOptions;
2860
+ }
2861
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
2862
+ localVarHeaderParameter = {};
2863
+ localVarQueryParameter = {};
2864
+ // authentication ApiKeyAuth required
2865
+ return [4 /*yield*/, (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration)];
2866
+ case 1:
2867
+ // authentication ApiKeyAuth required
2868
+ _a.sent();
2869
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
2870
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
2871
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
2872
+ return [2 /*return*/, {
2873
+ url: (0, common_1.toPathString)(localVarUrlObj),
2874
+ options: localVarRequestOptions,
2875
+ }];
2876
+ }
2877
+ });
2878
+ });
2879
+ },
2608
2880
  };
2609
2881
  };
2610
2882
  exports.UserManagementApiAxiosParamCreator = UserManagementApiAxiosParamCreator;
@@ -2638,6 +2910,29 @@ var UserManagementApiFp = function (configuration) {
2638
2910
  });
2639
2911
  });
2640
2912
  },
2913
+ /**
2914
+ * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
2915
+ * @summary List Users in Org with teammate permission summary
2916
+ * @param {string} orgId
2917
+ * @param {*} [options] Override http request option.
2918
+ * @throws {RequiredError}
2919
+ */
2920
+ listUsersInOrgWithTeammatePermissionSummary: function (orgId, options) {
2921
+ return __awaiter(this, void 0, void 0, function () {
2922
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
2923
+ var _a, _b, _c;
2924
+ return __generator(this, function (_d) {
2925
+ switch (_d.label) {
2926
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.listUsersInOrgWithTeammatePermissionSummary(orgId, options)];
2927
+ case 1:
2928
+ localVarAxiosArgs = _d.sent();
2929
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
2930
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManagementApi.listUsersInOrgWithTeammatePermissionSummary']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
2931
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
2932
+ }
2933
+ });
2934
+ });
2935
+ },
2641
2936
  };
2642
2937
  };
2643
2938
  exports.UserManagementApiFp = UserManagementApiFp;
@@ -2658,6 +2953,16 @@ var UserManagementApiFactory = function (configuration, basePath, axios) {
2658
2953
  listUsersInOrg: function (orgId, options) {
2659
2954
  return localVarFp.listUsersInOrg(orgId, options).then(function (request) { return request(axios, basePath); });
2660
2955
  },
2956
+ /**
2957
+ * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
2958
+ * @summary List Users in Org with teammate permission summary
2959
+ * @param {string} orgId
2960
+ * @param {*} [options] Override http request option.
2961
+ * @throws {RequiredError}
2962
+ */
2963
+ listUsersInOrgWithTeammatePermissionSummary: function (orgId, options) {
2964
+ return localVarFp.listUsersInOrgWithTeammatePermissionSummary(orgId, options).then(function (request) { return request(axios, basePath); });
2965
+ },
2661
2966
  };
2662
2967
  };
2663
2968
  exports.UserManagementApiFactory = UserManagementApiFactory;
@@ -2684,6 +2989,18 @@ var UserManagementApi = /** @class */ (function (_super) {
2684
2989
  var _this = this;
2685
2990
  return (0, exports.UserManagementApiFp)(this.configuration).listUsersInOrg(orgId, options).then(function (request) { return request(_this.axios, _this.basePath); });
2686
2991
  };
2992
+ /**
2993
+ * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
2994
+ * @summary List Users in Org with teammate permission summary
2995
+ * @param {string} orgId
2996
+ * @param {*} [options] Override http request option.
2997
+ * @throws {RequiredError}
2998
+ * @memberof UserManagementApi
2999
+ */
3000
+ UserManagementApi.prototype.listUsersInOrgWithTeammatePermissionSummary = function (orgId, options) {
3001
+ var _this = this;
3002
+ return (0, exports.UserManagementApiFp)(this.configuration).listUsersInOrgWithTeammatePermissionSummary(orgId, options).then(function (request) { return request(_this.axios, _this.basePath); });
3003
+ };
2687
3004
  return UserManagementApi;
2688
3005
  }(base_1.BaseAPI));
2689
3006
  exports.UserManagementApi = UserManagementApi;
@@ -36,7 +36,7 @@ var Configuration = /** @class */ (function () {
36
36
  this.serverIndex = param.serverIndex;
37
37
  var extraHeaders = param.useDefaultUserAgent ? {} : {
38
38
  headers: {
39
- "user-agent": "Flipdish authorization typescript SDK / 0.2.32"
39
+ "user-agent": "Flipdish authorization typescript SDK / 0.2.33"
40
40
  }
41
41
  };
42
42
  this.baseOptions = __assign(__assign({}, extraHeaders), param.baseOptions);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flipdish/authorization",
3
- "version": "0.2.32",
3
+ "version": "0.2.33",
4
4
  "description": "OpenAPI client for @flipdish/authorization",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "repository": {