@flipdish/authorization 0.0.72-rc.1776933211 → 0.0.74-rc.1776934397

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/api.ts CHANGED
@@ -1009,6 +1009,61 @@ export type GetUserPermissionsSuccessResponseResourcesValueResourceTypeEnum = ty
1009
1009
  */
1010
1010
  export interface GetUserPermissionsSuccessResponseResourcesValueResourceId {
1011
1011
  }
1012
+ /**
1013
+ * Grant teammate app access to a user being assigned within a brand for the first time.
1014
+ * @export
1015
+ * @interface GrantTeammateAccessRequestBody
1016
+ */
1017
+ export interface GrantTeammateAccessRequestBody {
1018
+ /**
1019
+ * Teammate app access level (role)
1020
+ * @type {string}
1021
+ * @memberof GrantTeammateAccessRequestBody
1022
+ */
1023
+ 'appAccessLevel': GrantTeammateAccessRequestBodyAppAccessLevelEnum;
1024
+ /**
1025
+ * Brand identifier (AppId); normalized to lowercase when stored
1026
+ * @type {string}
1027
+ * @memberof GrantTeammateAccessRequestBody
1028
+ */
1029
+ 'brandId': string;
1030
+ /**
1031
+ * Org-wide store access; when false, propertyIds are required for property-scoped roles
1032
+ * @type {boolean}
1033
+ * @memberof GrantTeammateAccessRequestBody
1034
+ */
1035
+ 'hasAccessToAllStores': boolean;
1036
+ /**
1037
+ * Property resource ids (e.g. p123) when scoped to properties
1038
+ * @type {Array<string>}
1039
+ * @memberof GrantTeammateAccessRequestBody
1040
+ */
1041
+ 'propertyIds'?: Array<string>;
1042
+ /**
1043
+ * Target user email; persisted on first assignment only
1044
+ * @type {string}
1045
+ * @memberof GrantTeammateAccessRequestBody
1046
+ */
1047
+ 'userEmail': string;
1048
+ /**
1049
+ * Target user display name; persisted on first assignment only
1050
+ * @type {string}
1051
+ * @memberof GrantTeammateAccessRequestBody
1052
+ */
1053
+ 'userName'?: string;
1054
+ }
1055
+
1056
+ export const GrantTeammateAccessRequestBodyAppAccessLevelEnum = {
1057
+ Owner: 'Owner',
1058
+ ManagedOwner: 'ManagedOwner',
1059
+ PropertyOwner: 'PropertyOwner',
1060
+ PropertyManager: 'PropertyManager',
1061
+ FinanceManager: 'FinanceManager',
1062
+ Integrator: 'Integrator'
1063
+ } as const;
1064
+
1065
+ export type GrantTeammateAccessRequestBodyAppAccessLevelEnum = typeof GrantTeammateAccessRequestBodyAppAccessLevelEnum[keyof typeof GrantTeammateAccessRequestBodyAppAccessLevelEnum];
1066
+
1012
1067
  /**
1013
1068
  *
1014
1069
  * @export
@@ -1446,63 +1501,6 @@ export const Permissions = {
1446
1501
  export type Permissions = typeof Permissions[keyof typeof Permissions];
1447
1502
 
1448
1503
 
1449
- /**
1450
- * Principal with teammate permission summary
1451
- * @export
1452
- * @interface PrincipalInOrgWithTeammatePermissionSummary
1453
- */
1454
- export interface PrincipalInOrgWithTeammatePermissionSummary {
1455
- /**
1456
- *
1457
- * @type {string}
1458
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1459
- */
1460
- 'type': PrincipalInOrgWithTeammatePermissionSummaryTypeEnum;
1461
- /**
1462
- *
1463
- * @type {string}
1464
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1465
- */
1466
- 'id': string;
1467
- /**
1468
- *
1469
- * @type {string}
1470
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1471
- */
1472
- 'name'?: string;
1473
- /**
1474
- *
1475
- * @type {string}
1476
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1477
- */
1478
- 'email'?: string;
1479
- /**
1480
- *
1481
- * @type {string}
1482
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1483
- */
1484
- 'phone'?: string;
1485
- /**
1486
- * Teammate role label; null when no compensating role or unknown
1487
- * @type {string}
1488
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1489
- */
1490
- 'roleDisplay': string;
1491
- /**
1492
- * True when granular roles differ from default for the compensating role
1493
- * @type {boolean}
1494
- * @memberof PrincipalInOrgWithTeammatePermissionSummary
1495
- */
1496
- 'isCustomised': boolean;
1497
- }
1498
-
1499
- export const PrincipalInOrgWithTeammatePermissionSummaryTypeEnum = {
1500
- User: 'User',
1501
- Automation: 'Automation'
1502
- } as const;
1503
-
1504
- export type PrincipalInOrgWithTeammatePermissionSummaryTypeEnum = typeof PrincipalInOrgWithTeammatePermissionSummaryTypeEnum[keyof typeof PrincipalInOrgWithTeammatePermissionSummaryTypeEnum];
1505
-
1506
1504
  /**
1507
1505
  * Principals in org
1508
1506
  * @export
@@ -1522,25 +1520,6 @@ export interface PrincipalsInOrgResponse {
1522
1520
  */
1523
1521
  'principals': Array<AuthorizationRequestPrincipal>;
1524
1522
  }
1525
- /**
1526
- * Principals in org including teammate permission summary per principal
1527
- * @export
1528
- * @interface PrincipalsInOrgWithTeammatePermissionSummaryResponse
1529
- */
1530
- export interface PrincipalsInOrgWithTeammatePermissionSummaryResponse {
1531
- /**
1532
- *
1533
- * @type {string}
1534
- * @memberof PrincipalsInOrgWithTeammatePermissionSummaryResponse
1535
- */
1536
- 'orgId': string;
1537
- /**
1538
- * List of principals with roleDisplay and isCustomised
1539
- * @type {Array<PrincipalInOrgWithTeammatePermissionSummary>}
1540
- * @memberof PrincipalsInOrgWithTeammatePermissionSummaryResponse
1541
- */
1542
- 'principals': Array<PrincipalInOrgWithTeammatePermissionSummary>;
1543
- }
1544
1523
  /**
1545
1524
  * Details for revoking a forbidden role from a principal
1546
1525
  * @export
@@ -1715,6 +1694,62 @@ export const RoleNames = {
1715
1694
  export type RoleNames = typeof RoleNames[keyof typeof RoleNames];
1716
1695
 
1717
1696
 
1697
+ /**
1698
+ * Teammate access applied
1699
+ * @export
1700
+ * @interface TeammateAccessSuccessResponse
1701
+ */
1702
+ export interface TeammateAccessSuccessResponse {
1703
+ /**
1704
+ *
1705
+ * @type {string}
1706
+ * @memberof TeammateAccessSuccessResponse
1707
+ */
1708
+ 'message': string;
1709
+ }
1710
+ /**
1711
+ * Update teammate app access for an existing teammate. Email and name are not accepted on update; the existing values stored against the user id are reused.
1712
+ * @export
1713
+ * @interface UpdateTeammateAccessRequestBody
1714
+ */
1715
+ export interface UpdateTeammateAccessRequestBody {
1716
+ /**
1717
+ * Teammate app access level (role)
1718
+ * @type {string}
1719
+ * @memberof UpdateTeammateAccessRequestBody
1720
+ */
1721
+ 'appAccessLevel': UpdateTeammateAccessRequestBodyAppAccessLevelEnum;
1722
+ /**
1723
+ * Brand identifier (AppId); normalized to lowercase when stored
1724
+ * @type {string}
1725
+ * @memberof UpdateTeammateAccessRequestBody
1726
+ */
1727
+ 'brandId': string;
1728
+ /**
1729
+ * Org-wide store access; when false, propertyIds are required for property-scoped roles
1730
+ * @type {boolean}
1731
+ * @memberof UpdateTeammateAccessRequestBody
1732
+ */
1733
+ 'hasAccessToAllStores': boolean;
1734
+ /**
1735
+ * Property resource ids (e.g. p123) when scoped to properties
1736
+ * @type {Array<string>}
1737
+ * @memberof UpdateTeammateAccessRequestBody
1738
+ */
1739
+ 'propertyIds'?: Array<string>;
1740
+ }
1741
+
1742
+ export const UpdateTeammateAccessRequestBodyAppAccessLevelEnum = {
1743
+ Owner: 'Owner',
1744
+ ManagedOwner: 'ManagedOwner',
1745
+ PropertyOwner: 'PropertyOwner',
1746
+ PropertyManager: 'PropertyManager',
1747
+ FinanceManager: 'FinanceManager',
1748
+ Integrator: 'Integrator'
1749
+ } as const;
1750
+
1751
+ export type UpdateTeammateAccessRequestBodyAppAccessLevelEnum = typeof UpdateTeammateAccessRequestBodyAppAccessLevelEnum[keyof typeof UpdateTeammateAccessRequestBodyAppAccessLevelEnum];
1752
+
1718
1753
  /**
1719
1754
  *
1720
1755
  * @export
@@ -3042,6 +3077,51 @@ export const RoleAssignmentApiAxiosParamCreator = function (configuration?: Conf
3042
3077
  options: localVarRequestOptions,
3043
3078
  };
3044
3079
  },
3080
+ /**
3081
+ * 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.
3082
+ * @summary Grant teammate access to a new user
3083
+ * @param {string} orgId
3084
+ * @param {string} userId Target Flipdish user id (numeric string)
3085
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
3086
+ * @param {*} [options] Override http request option.
3087
+ * @throws {RequiredError}
3088
+ */
3089
+ grantTeammateAccess: async (orgId: string, userId: string, grantTeammateAccessRequestBody?: GrantTeammateAccessRequestBody, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
3090
+ // verify required parameter 'orgId' is not null or undefined
3091
+ assertParamExists('grantTeammateAccess', 'orgId', orgId)
3092
+ // verify required parameter 'userId' is not null or undefined
3093
+ assertParamExists('grantTeammateAccess', 'userId', userId)
3094
+ const localVarPath = `/orgs/{orgId}/users/{userId}/grantTeammateAccess`
3095
+ .replace(`{${"orgId"}}`, encodeURIComponent(String(orgId)))
3096
+ .replace(`{${"userId"}}`, encodeURIComponent(String(userId)));
3097
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
3098
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
3099
+ let baseOptions;
3100
+ if (configuration) {
3101
+ baseOptions = configuration.baseOptions;
3102
+ }
3103
+
3104
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
3105
+ const localVarHeaderParameter = {} as any;
3106
+ const localVarQueryParameter = {} as any;
3107
+
3108
+ // authentication ApiKeyAuth required
3109
+ await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
3110
+
3111
+
3112
+
3113
+ localVarHeaderParameter['Content-Type'] = 'application/json';
3114
+
3115
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
3116
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
3117
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
3118
+ localVarRequestOptions.data = serializeDataIfNeeded(grantTeammateAccessRequestBody, localVarRequestOptions, configuration)
3119
+
3120
+ return {
3121
+ url: toPathString(localVarUrlObj),
3122
+ options: localVarRequestOptions,
3123
+ };
3124
+ },
3045
3125
  /**
3046
3126
  * Revokes a forbidden role from a given principal (user, group, etc.)
3047
3127
  * @summary Revoke Forbidden Role from Principal
@@ -3119,6 +3199,51 @@ export const RoleAssignmentApiAxiosParamCreator = function (configuration?: Conf
3119
3199
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
3120
3200
  localVarRequestOptions.data = serializeDataIfNeeded(revokeRoleRequestBody, localVarRequestOptions, configuration)
3121
3201
 
3202
+ return {
3203
+ url: toPathString(localVarUrlObj),
3204
+ options: localVarRequestOptions,
3205
+ };
3206
+ },
3207
+ /**
3208
+ * 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.
3209
+ * @summary Update teammate access for an existing user
3210
+ * @param {string} orgId
3211
+ * @param {string} userId Target Flipdish user id (numeric string)
3212
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
3213
+ * @param {*} [options] Override http request option.
3214
+ * @throws {RequiredError}
3215
+ */
3216
+ updateTeammateAccess: async (orgId: string, userId: string, updateTeammateAccessRequestBody?: UpdateTeammateAccessRequestBody, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
3217
+ // verify required parameter 'orgId' is not null or undefined
3218
+ assertParamExists('updateTeammateAccess', 'orgId', orgId)
3219
+ // verify required parameter 'userId' is not null or undefined
3220
+ assertParamExists('updateTeammateAccess', 'userId', userId)
3221
+ const localVarPath = `/orgs/{orgId}/users/{userId}/updateTeammateAccess`
3222
+ .replace(`{${"orgId"}}`, encodeURIComponent(String(orgId)))
3223
+ .replace(`{${"userId"}}`, encodeURIComponent(String(userId)));
3224
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
3225
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
3226
+ let baseOptions;
3227
+ if (configuration) {
3228
+ baseOptions = configuration.baseOptions;
3229
+ }
3230
+
3231
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
3232
+ const localVarHeaderParameter = {} as any;
3233
+ const localVarQueryParameter = {} as any;
3234
+
3235
+ // authentication ApiKeyAuth required
3236
+ await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
3237
+
3238
+
3239
+
3240
+ localVarHeaderParameter['Content-Type'] = 'application/json';
3241
+
3242
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
3243
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
3244
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
3245
+ localVarRequestOptions.data = serializeDataIfNeeded(updateTeammateAccessRequestBody, localVarRequestOptions, configuration)
3246
+
3122
3247
  return {
3123
3248
  url: toPathString(localVarUrlObj),
3124
3249
  options: localVarRequestOptions,
@@ -3162,6 +3287,21 @@ export const RoleAssignmentApiFp = function(configuration?: Configuration) {
3162
3287
  const localVarOperationServerBasePath = operationServerMap['RoleAssignmentApi.getPrincipalRoles']?.[localVarOperationServerIndex]?.url;
3163
3288
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3164
3289
  },
3290
+ /**
3291
+ * 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.
3292
+ * @summary Grant teammate access to a new user
3293
+ * @param {string} orgId
3294
+ * @param {string} userId Target Flipdish user id (numeric string)
3295
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
3296
+ * @param {*} [options] Override http request option.
3297
+ * @throws {RequiredError}
3298
+ */
3299
+ async grantTeammateAccess(orgId: string, userId: string, grantTeammateAccessRequestBody?: GrantTeammateAccessRequestBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TeammateAccessSuccessResponse>> {
3300
+ const localVarAxiosArgs = await localVarAxiosParamCreator.grantTeammateAccess(orgId, userId, grantTeammateAccessRequestBody, options);
3301
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3302
+ const localVarOperationServerBasePath = operationServerMap['RoleAssignmentApi.grantTeammateAccess']?.[localVarOperationServerIndex]?.url;
3303
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3304
+ },
3165
3305
  /**
3166
3306
  * Revokes a forbidden role from a given principal (user, group, etc.)
3167
3307
  * @summary Revoke Forbidden Role from Principal
@@ -3190,6 +3330,21 @@ export const RoleAssignmentApiFp = function(configuration?: Configuration) {
3190
3330
  const localVarOperationServerBasePath = operationServerMap['RoleAssignmentApi.revokeRoleFromPrincipal']?.[localVarOperationServerIndex]?.url;
3191
3331
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3192
3332
  },
3333
+ /**
3334
+ * 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.
3335
+ * @summary Update teammate access for an existing user
3336
+ * @param {string} orgId
3337
+ * @param {string} userId Target Flipdish user id (numeric string)
3338
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
3339
+ * @param {*} [options] Override http request option.
3340
+ * @throws {RequiredError}
3341
+ */
3342
+ async updateTeammateAccess(orgId: string, userId: string, updateTeammateAccessRequestBody?: UpdateTeammateAccessRequestBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TeammateAccessSuccessResponse>> {
3343
+ const localVarAxiosArgs = await localVarAxiosParamCreator.updateTeammateAccess(orgId, userId, updateTeammateAccessRequestBody, options);
3344
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3345
+ const localVarOperationServerBasePath = operationServerMap['RoleAssignmentApi.updateTeammateAccess']?.[localVarOperationServerIndex]?.url;
3346
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3347
+ },
3193
3348
  }
3194
3349
  };
3195
3350
 
@@ -3222,6 +3377,18 @@ export const RoleAssignmentApiFactory = function (configuration?: Configuration,
3222
3377
  getPrincipalRoles(orgId: string, getPrincipalRolesRequestBody?: GetPrincipalRolesRequestBody, options?: RawAxiosRequestConfig): AxiosPromise<GetPrincipalRolesSuccessResponse> {
3223
3378
  return localVarFp.getPrincipalRoles(orgId, getPrincipalRolesRequestBody, options).then((request) => request(axios, basePath));
3224
3379
  },
3380
+ /**
3381
+ * 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.
3382
+ * @summary Grant teammate access to a new user
3383
+ * @param {string} orgId
3384
+ * @param {string} userId Target Flipdish user id (numeric string)
3385
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
3386
+ * @param {*} [options] Override http request option.
3387
+ * @throws {RequiredError}
3388
+ */
3389
+ grantTeammateAccess(orgId: string, userId: string, grantTeammateAccessRequestBody?: GrantTeammateAccessRequestBody, options?: RawAxiosRequestConfig): AxiosPromise<TeammateAccessSuccessResponse> {
3390
+ return localVarFp.grantTeammateAccess(orgId, userId, grantTeammateAccessRequestBody, options).then((request) => request(axios, basePath));
3391
+ },
3225
3392
  /**
3226
3393
  * Revokes a forbidden role from a given principal (user, group, etc.)
3227
3394
  * @summary Revoke Forbidden Role from Principal
@@ -3244,6 +3411,18 @@ export const RoleAssignmentApiFactory = function (configuration?: Configuration,
3244
3411
  revokeRoleFromPrincipal(orgId: string, revokeRoleRequestBody?: RevokeRoleRequestBody, options?: RawAxiosRequestConfig): AxiosPromise<RevokeRoleSuccessResponse> {
3245
3412
  return localVarFp.revokeRoleFromPrincipal(orgId, revokeRoleRequestBody, options).then((request) => request(axios, basePath));
3246
3413
  },
3414
+ /**
3415
+ * 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.
3416
+ * @summary Update teammate access for an existing user
3417
+ * @param {string} orgId
3418
+ * @param {string} userId Target Flipdish user id (numeric string)
3419
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
3420
+ * @param {*} [options] Override http request option.
3421
+ * @throws {RequiredError}
3422
+ */
3423
+ updateTeammateAccess(orgId: string, userId: string, updateTeammateAccessRequestBody?: UpdateTeammateAccessRequestBody, options?: RawAxiosRequestConfig): AxiosPromise<TeammateAccessSuccessResponse> {
3424
+ return localVarFp.updateTeammateAccess(orgId, userId, updateTeammateAccessRequestBody, options).then((request) => request(axios, basePath));
3425
+ },
3247
3426
  };
3248
3427
  };
3249
3428
 
@@ -3280,6 +3459,20 @@ export class RoleAssignmentApi extends BaseAPI {
3280
3459
  return RoleAssignmentApiFp(this.configuration).getPrincipalRoles(orgId, getPrincipalRolesRequestBody, options).then((request) => request(this.axios, this.basePath));
3281
3460
  }
3282
3461
 
3462
+ /**
3463
+ * 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.
3464
+ * @summary Grant teammate access to a new user
3465
+ * @param {string} orgId
3466
+ * @param {string} userId Target Flipdish user id (numeric string)
3467
+ * @param {GrantTeammateAccessRequestBody} [grantTeammateAccessRequestBody]
3468
+ * @param {*} [options] Override http request option.
3469
+ * @throws {RequiredError}
3470
+ * @memberof RoleAssignmentApi
3471
+ */
3472
+ public grantTeammateAccess(orgId: string, userId: string, grantTeammateAccessRequestBody?: GrantTeammateAccessRequestBody, options?: RawAxiosRequestConfig) {
3473
+ return RoleAssignmentApiFp(this.configuration).grantTeammateAccess(orgId, userId, grantTeammateAccessRequestBody, options).then((request) => request(this.axios, this.basePath));
3474
+ }
3475
+
3283
3476
  /**
3284
3477
  * Revokes a forbidden role from a given principal (user, group, etc.)
3285
3478
  * @summary Revoke Forbidden Role from Principal
@@ -3305,6 +3498,20 @@ export class RoleAssignmentApi extends BaseAPI {
3305
3498
  public revokeRoleFromPrincipal(orgId: string, revokeRoleRequestBody?: RevokeRoleRequestBody, options?: RawAxiosRequestConfig) {
3306
3499
  return RoleAssignmentApiFp(this.configuration).revokeRoleFromPrincipal(orgId, revokeRoleRequestBody, options).then((request) => request(this.axios, this.basePath));
3307
3500
  }
3501
+
3502
+ /**
3503
+ * 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.
3504
+ * @summary Update teammate access for an existing user
3505
+ * @param {string} orgId
3506
+ * @param {string} userId Target Flipdish user id (numeric string)
3507
+ * @param {UpdateTeammateAccessRequestBody} [updateTeammateAccessRequestBody]
3508
+ * @param {*} [options] Override http request option.
3509
+ * @throws {RequiredError}
3510
+ * @memberof RoleAssignmentApi
3511
+ */
3512
+ public updateTeammateAccess(orgId: string, userId: string, updateTeammateAccessRequestBody?: UpdateTeammateAccessRequestBody, options?: RawAxiosRequestConfig) {
3513
+ return RoleAssignmentApiFp(this.configuration).updateTeammateAccess(orgId, userId, updateTeammateAccessRequestBody, options).then((request) => request(this.axios, this.basePath));
3514
+ }
3308
3515
  }
3309
3516
 
3310
3517
 
@@ -3343,43 +3550,6 @@ export const UserManagementApiAxiosParamCreator = function (configuration?: Conf
3343
3550
 
3344
3551
 
3345
3552
 
3346
- setSearchParams(localVarUrlObj, localVarQueryParameter);
3347
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
3348
- localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
3349
-
3350
- return {
3351
- url: toPathString(localVarUrlObj),
3352
- options: localVarRequestOptions,
3353
- };
3354
- },
3355
- /**
3356
- * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
3357
- * @summary List Users in Org with teammate permission summary
3358
- * @param {string} orgId
3359
- * @param {*} [options] Override http request option.
3360
- * @throws {RequiredError}
3361
- */
3362
- listUsersInOrgWithTeammatePermissionSummary: async (orgId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
3363
- // verify required parameter 'orgId' is not null or undefined
3364
- assertParamExists('listUsersInOrgWithTeammatePermissionSummary', 'orgId', orgId)
3365
- const localVarPath = `/orgs/{orgId}/users/teammatePermissionSummary`
3366
- .replace(`{${"orgId"}}`, encodeURIComponent(String(orgId)));
3367
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
3368
- const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
3369
- let baseOptions;
3370
- if (configuration) {
3371
- baseOptions = configuration.baseOptions;
3372
- }
3373
-
3374
- const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
3375
- const localVarHeaderParameter = {} as any;
3376
- const localVarQueryParameter = {} as any;
3377
-
3378
- // authentication ApiKeyAuth required
3379
- await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
3380
-
3381
-
3382
-
3383
3553
  setSearchParams(localVarUrlObj, localVarQueryParameter);
3384
3554
  let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
3385
3555
  localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
@@ -3412,19 +3582,6 @@ export const UserManagementApiFp = function(configuration?: Configuration) {
3412
3582
  const localVarOperationServerBasePath = operationServerMap['UserManagementApi.listUsersInOrg']?.[localVarOperationServerIndex]?.url;
3413
3583
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3414
3584
  },
3415
- /**
3416
- * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
3417
- * @summary List Users in Org with teammate permission summary
3418
- * @param {string} orgId
3419
- * @param {*} [options] Override http request option.
3420
- * @throws {RequiredError}
3421
- */
3422
- async listUsersInOrgWithTeammatePermissionSummary(orgId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PrincipalsInOrgWithTeammatePermissionSummaryResponse>> {
3423
- const localVarAxiosArgs = await localVarAxiosParamCreator.listUsersInOrgWithTeammatePermissionSummary(orgId, options);
3424
- const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
3425
- const localVarOperationServerBasePath = operationServerMap['UserManagementApi.listUsersInOrgWithTeammatePermissionSummary']?.[localVarOperationServerIndex]?.url;
3426
- return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
3427
- },
3428
3585
  }
3429
3586
  };
3430
3587
 
@@ -3445,16 +3602,6 @@ export const UserManagementApiFactory = function (configuration?: Configuration,
3445
3602
  listUsersInOrg(orgId: string, options?: RawAxiosRequestConfig): AxiosPromise<PrincipalsInOrgResponse> {
3446
3603
  return localVarFp.listUsersInOrg(orgId, options).then((request) => request(axios, basePath));
3447
3604
  },
3448
- /**
3449
- * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
3450
- * @summary List Users in Org with teammate permission summary
3451
- * @param {string} orgId
3452
- * @param {*} [options] Override http request option.
3453
- * @throws {RequiredError}
3454
- */
3455
- listUsersInOrgWithTeammatePermissionSummary(orgId: string, options?: RawAxiosRequestConfig): AxiosPromise<PrincipalsInOrgWithTeammatePermissionSummaryResponse> {
3456
- return localVarFp.listUsersInOrgWithTeammatePermissionSummary(orgId, options).then((request) => request(axios, basePath));
3457
- },
3458
3605
  };
3459
3606
  };
3460
3607
 
@@ -3476,18 +3623,6 @@ export class UserManagementApi extends BaseAPI {
3476
3623
  public listUsersInOrg(orgId: string, options?: RawAxiosRequestConfig) {
3477
3624
  return UserManagementApiFp(this.configuration).listUsersInOrg(orgId, options).then((request) => request(this.axios, this.basePath));
3478
3625
  }
3479
-
3480
- /**
3481
- * Same principals as list users, plus roleDisplay and isCustomised per principal (extra Dynamo reads for compensating roles and granular assignments).
3482
- * @summary List Users in Org with teammate permission summary
3483
- * @param {string} orgId
3484
- * @param {*} [options] Override http request option.
3485
- * @throws {RequiredError}
3486
- * @memberof UserManagementApi
3487
- */
3488
- public listUsersInOrgWithTeammatePermissionSummary(orgId: string, options?: RawAxiosRequestConfig) {
3489
- return UserManagementApiFp(this.configuration).listUsersInOrgWithTeammatePermissionSummary(orgId, options).then((request) => request(this.axios, this.basePath));
3490
- }
3491
3626
  }
3492
3627
 
3493
3628
 
package/configuration.ts CHANGED
@@ -100,7 +100,7 @@ export class Configuration {
100
100
 
101
101
  const extraHeaders = param.useDefaultUserAgent ? {} : {
102
102
  headers: {
103
- "user-agent": "Flipdish authorization typescript SDK / 0.0.72-rc.1776933211"
103
+ "user-agent": "Flipdish authorization typescript SDK / 0.0.74-rc.1776934397"
104
104
  }
105
105
  };
106
106