@flipdish/authorization 0.0.552-rc.1790679260 → 0.0.554-rc.1790701085

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
@@ -1952,6 +1952,19 @@ export const JoinAccessErrorResponseCodeEnum = {
1952
1952
 
1953
1953
  export type JoinAccessErrorResponseCodeEnum = typeof JoinAccessErrorResponseCodeEnum[keyof typeof JoinAccessErrorResponseCodeEnum];
1954
1954
 
1955
+ /**
1956
+ * Caller removed from org
1957
+ * @export
1958
+ * @interface LeaveOrgSuccessResponse
1959
+ */
1960
+ export interface LeaveOrgSuccessResponse {
1961
+ /**
1962
+ *
1963
+ * @type {string}
1964
+ * @memberof LeaveOrgSuccessResponse
1965
+ */
1966
+ 'message': string;
1967
+ }
1955
1968
  /**
1956
1969
  * An org\'s expired timed access grants, most recent first
1957
1970
  * @export
@@ -2482,6 +2495,7 @@ export const Permissions = {
2482
2495
  ViewWebhooks: 'ViewWebhooks',
2483
2496
  EditWebhooks: 'EditWebhooks',
2484
2497
  ViewOwnPermissions: 'ViewOwnPermissions',
2498
+ LeaveOrg: 'LeaveOrg',
2485
2499
  CreatePosSale: 'CreatePosSale',
2486
2500
  ComplimentPosItems: 'ComplimentPosItems',
2487
2501
  ApplyPosDiscounts: 'ApplyPosDiscounts',
@@ -6266,6 +6280,43 @@ export const RoleAssignmentApiAxiosParamCreator = function (configuration?: Conf
6266
6280
  options: localVarRequestOptions,
6267
6281
  };
6268
6282
  },
6283
+ /**
6284
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
6285
+ * @summary Leave org
6286
+ * @param {string} orgId
6287
+ * @param {*} [options] Override http request option.
6288
+ * @throws {RequiredError}
6289
+ */
6290
+ leaveOrg: async (orgId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
6291
+ // verify required parameter 'orgId' is not null or undefined
6292
+ assertParamExists('leaveOrg', 'orgId', orgId)
6293
+ const localVarPath = `/orgs/{orgId}/leave`
6294
+ .replace(`{${"orgId"}}`, encodeURIComponent(String(orgId)));
6295
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
6296
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
6297
+ let baseOptions;
6298
+ if (configuration) {
6299
+ baseOptions = configuration.baseOptions;
6300
+ }
6301
+
6302
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
6303
+ const localVarHeaderParameter = {} as any;
6304
+ const localVarQueryParameter = {} as any;
6305
+
6306
+ // authentication ApiKeyAuth required
6307
+ await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
6308
+
6309
+
6310
+
6311
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
6312
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
6313
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
6314
+
6315
+ return {
6316
+ url: toPathString(localVarUrlObj),
6317
+ options: localVarRequestOptions,
6318
+ };
6319
+ },
6269
6320
  /**
6270
6321
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
6271
6322
  * @summary Rematerialize Role Assignment
@@ -6372,6 +6423,19 @@ export const RoleAssignmentApiFp = function(configuration?: Configuration) {
6372
6423
  const localVarOperationServerBasePath = operationServerMap['RoleAssignmentApi.applyRoleAssignment']?.[localVarOperationServerIndex]?.url;
6373
6424
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
6374
6425
  },
6426
+ /**
6427
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
6428
+ * @summary Leave org
6429
+ * @param {string} orgId
6430
+ * @param {*} [options] Override http request option.
6431
+ * @throws {RequiredError}
6432
+ */
6433
+ async leaveOrg(orgId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<LeaveOrgSuccessResponse>> {
6434
+ const localVarAxiosArgs = await localVarAxiosParamCreator.leaveOrg(orgId, options);
6435
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
6436
+ const localVarOperationServerBasePath = operationServerMap['RoleAssignmentApi.leaveOrg']?.[localVarOperationServerIndex]?.url;
6437
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
6438
+ },
6375
6439
  /**
6376
6440
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
6377
6441
  * @summary Rematerialize Role Assignment
@@ -6421,6 +6485,16 @@ export const RoleAssignmentApiFactory = function (configuration?: Configuration,
6421
6485
  applyRoleAssignment(orgId: string, roleAssignmentRequestBody?: RoleAssignmentRequestBody, options?: RawAxiosRequestConfig): AxiosPromise<RoleAssignmentSuccessResponse> {
6422
6486
  return localVarFp.applyRoleAssignment(orgId, roleAssignmentRequestBody, options).then((request) => request(axios, basePath));
6423
6487
  },
6488
+ /**
6489
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
6490
+ * @summary Leave org
6491
+ * @param {string} orgId
6492
+ * @param {*} [options] Override http request option.
6493
+ * @throws {RequiredError}
6494
+ */
6495
+ leaveOrg(orgId: string, options?: RawAxiosRequestConfig): AxiosPromise<LeaveOrgSuccessResponse> {
6496
+ return localVarFp.leaveOrg(orgId, options).then((request) => request(axios, basePath));
6497
+ },
6424
6498
  /**
6425
6499
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
6426
6500
  * @summary Rematerialize Role Assignment
@@ -6466,6 +6540,18 @@ export class RoleAssignmentApi extends BaseAPI {
6466
6540
  return RoleAssignmentApiFp(this.configuration).applyRoleAssignment(orgId, roleAssignmentRequestBody, options).then((request) => request(this.axios, this.basePath));
6467
6541
  }
6468
6542
 
6543
+ /**
6544
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
6545
+ * @summary Leave org
6546
+ * @param {string} orgId
6547
+ * @param {*} [options] Override http request option.
6548
+ * @throws {RequiredError}
6549
+ * @memberof RoleAssignmentApi
6550
+ */
6551
+ public leaveOrg(orgId: string, options?: RawAxiosRequestConfig) {
6552
+ return RoleAssignmentApiFp(this.configuration).leaveOrg(orgId, options).then((request) => request(this.axios, this.basePath));
6553
+ }
6554
+
6469
6555
  /**
6470
6556
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
6471
6557
  * @summary Rematerialize Role Assignment
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.552-rc.1790679260"
103
+ "user-agent": "Flipdish authorization typescript SDK / 0.0.554-rc.1790701085"
104
104
  }
105
105
  };
106
106
 
package/dist/api.d.ts CHANGED
@@ -1866,6 +1866,19 @@ export declare const JoinAccessErrorResponseCodeEnum: {
1866
1866
  readonly AlreadyMember: "ALREADY_MEMBER";
1867
1867
  };
1868
1868
  export type JoinAccessErrorResponseCodeEnum = typeof JoinAccessErrorResponseCodeEnum[keyof typeof JoinAccessErrorResponseCodeEnum];
1869
+ /**
1870
+ * Caller removed from org
1871
+ * @export
1872
+ * @interface LeaveOrgSuccessResponse
1873
+ */
1874
+ export interface LeaveOrgSuccessResponse {
1875
+ /**
1876
+ *
1877
+ * @type {string}
1878
+ * @memberof LeaveOrgSuccessResponse
1879
+ */
1880
+ 'message': string;
1881
+ }
1869
1882
  /**
1870
1883
  * An org\'s expired timed access grants, most recent first
1871
1884
  * @export
@@ -2387,6 +2400,7 @@ export declare const Permissions: {
2387
2400
  readonly ViewWebhooks: "ViewWebhooks";
2388
2401
  readonly EditWebhooks: "EditWebhooks";
2389
2402
  readonly ViewOwnPermissions: "ViewOwnPermissions";
2403
+ readonly LeaveOrg: "LeaveOrg";
2390
2404
  readonly CreatePosSale: "CreatePosSale";
2391
2405
  readonly ComplimentPosItems: "ComplimentPosItems";
2392
2406
  readonly ApplyPosDiscounts: "ApplyPosDiscounts";
@@ -4654,6 +4668,14 @@ export declare const RoleAssignmentApiAxiosParamCreator: (configuration?: Config
4654
4668
  * @throws {RequiredError}
4655
4669
  */
4656
4670
  applyRoleAssignment: (orgId: string, roleAssignmentRequestBody?: RoleAssignmentRequestBody, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
4671
+ /**
4672
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4673
+ * @summary Leave org
4674
+ * @param {string} orgId
4675
+ * @param {*} [options] Override http request option.
4676
+ * @throws {RequiredError}
4677
+ */
4678
+ leaveOrg: (orgId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
4657
4679
  /**
4658
4680
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4659
4681
  * @summary Rematerialize Role Assignment
@@ -4687,6 +4709,14 @@ export declare const RoleAssignmentApiFp: (configuration?: Configuration) => {
4687
4709
  * @throws {RequiredError}
4688
4710
  */
4689
4711
  applyRoleAssignment(orgId: string, roleAssignmentRequestBody?: RoleAssignmentRequestBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RoleAssignmentSuccessResponse>>;
4712
+ /**
4713
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4714
+ * @summary Leave org
4715
+ * @param {string} orgId
4716
+ * @param {*} [options] Override http request option.
4717
+ * @throws {RequiredError}
4718
+ */
4719
+ leaveOrg(orgId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<LeaveOrgSuccessResponse>>;
4690
4720
  /**
4691
4721
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4692
4722
  * @summary Rematerialize Role Assignment
@@ -4720,6 +4750,14 @@ export declare const RoleAssignmentApiFactory: (configuration?: Configuration, b
4720
4750
  * @throws {RequiredError}
4721
4751
  */
4722
4752
  applyRoleAssignment(orgId: string, roleAssignmentRequestBody?: RoleAssignmentRequestBody, options?: RawAxiosRequestConfig): AxiosPromise<RoleAssignmentSuccessResponse>;
4753
+ /**
4754
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4755
+ * @summary Leave org
4756
+ * @param {string} orgId
4757
+ * @param {*} [options] Override http request option.
4758
+ * @throws {RequiredError}
4759
+ */
4760
+ leaveOrg(orgId: string, options?: RawAxiosRequestConfig): AxiosPromise<LeaveOrgSuccessResponse>;
4723
4761
  /**
4724
4762
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4725
4763
  * @summary Rematerialize Role Assignment
@@ -4756,6 +4794,15 @@ export declare class RoleAssignmentApi extends BaseAPI {
4756
4794
  * @memberof RoleAssignmentApi
4757
4795
  */
4758
4796
  applyRoleAssignment(orgId: string, roleAssignmentRequestBody?: RoleAssignmentRequestBody, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<RoleAssignmentSuccessResponse, any, {}, any>>;
4797
+ /**
4798
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4799
+ * @summary Leave org
4800
+ * @param {string} orgId
4801
+ * @param {*} [options] Override http request option.
4802
+ * @throws {RequiredError}
4803
+ * @memberof RoleAssignmentApi
4804
+ */
4805
+ leaveOrg(orgId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<LeaveOrgSuccessResponse, any, {}, any>>;
4759
4806
  /**
4760
4807
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4761
4808
  * @summary Rematerialize Role Assignment
package/dist/api.js CHANGED
@@ -506,6 +506,7 @@ exports.Permissions = {
506
506
  ViewWebhooks: 'ViewWebhooks',
507
507
  EditWebhooks: 'EditWebhooks',
508
508
  ViewOwnPermissions: 'ViewOwnPermissions',
509
+ LeaveOrg: 'LeaveOrg',
509
510
  CreatePosSale: 'CreatePosSale',
510
511
  ComplimentPosItems: 'ComplimentPosItems',
511
512
  ApplyPosDiscounts: 'ApplyPosDiscounts',
@@ -4100,6 +4101,51 @@ var RoleAssignmentApiAxiosParamCreator = function (configuration) {
4100
4101
  });
4101
4102
  });
4102
4103
  },
4104
+ /**
4105
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4106
+ * @summary Leave org
4107
+ * @param {string} orgId
4108
+ * @param {*} [options] Override http request option.
4109
+ * @throws {RequiredError}
4110
+ */
4111
+ leaveOrg: function (orgId_1) {
4112
+ var args_1 = [];
4113
+ for (var _i = 1; _i < arguments.length; _i++) {
4114
+ args_1[_i - 1] = arguments[_i];
4115
+ }
4116
+ return __awaiter(_this, __spreadArray([orgId_1], args_1, true), void 0, function (orgId, options) {
4117
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
4118
+ if (options === void 0) { options = {}; }
4119
+ return __generator(this, function (_a) {
4120
+ switch (_a.label) {
4121
+ case 0:
4122
+ // verify required parameter 'orgId' is not null or undefined
4123
+ (0, common_1.assertParamExists)('leaveOrg', 'orgId', orgId);
4124
+ localVarPath = "/orgs/{orgId}/leave"
4125
+ .replace("{".concat("orgId", "}"), encodeURIComponent(String(orgId)));
4126
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
4127
+ if (configuration) {
4128
+ baseOptions = configuration.baseOptions;
4129
+ }
4130
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
4131
+ localVarHeaderParameter = {};
4132
+ localVarQueryParameter = {};
4133
+ // authentication ApiKeyAuth required
4134
+ return [4 /*yield*/, (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration)];
4135
+ case 1:
4136
+ // authentication ApiKeyAuth required
4137
+ _a.sent();
4138
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
4139
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
4140
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
4141
+ return [2 /*return*/, {
4142
+ url: (0, common_1.toPathString)(localVarUrlObj),
4143
+ options: localVarRequestOptions,
4144
+ }];
4145
+ }
4146
+ });
4147
+ });
4148
+ },
4103
4149
  /**
4104
4150
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4105
4151
  * @summary Rematerialize Role Assignment
@@ -4230,6 +4276,29 @@ var RoleAssignmentApiFp = function (configuration) {
4230
4276
  });
4231
4277
  });
4232
4278
  },
4279
+ /**
4280
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4281
+ * @summary Leave org
4282
+ * @param {string} orgId
4283
+ * @param {*} [options] Override http request option.
4284
+ * @throws {RequiredError}
4285
+ */
4286
+ leaveOrg: function (orgId, options) {
4287
+ return __awaiter(this, void 0, void 0, function () {
4288
+ var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
4289
+ var _a, _b, _c;
4290
+ return __generator(this, function (_d) {
4291
+ switch (_d.label) {
4292
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.leaveOrg(orgId, options)];
4293
+ case 1:
4294
+ localVarAxiosArgs = _d.sent();
4295
+ localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
4296
+ localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['RoleAssignmentApi.leaveOrg']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
4297
+ return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
4298
+ }
4299
+ });
4300
+ });
4301
+ },
4233
4302
  /**
4234
4303
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4235
4304
  * @summary Rematerialize Role Assignment
@@ -4299,6 +4368,16 @@ var RoleAssignmentApiFactory = function (configuration, basePath, axios) {
4299
4368
  applyRoleAssignment: function (orgId, roleAssignmentRequestBody, options) {
4300
4369
  return localVarFp.applyRoleAssignment(orgId, roleAssignmentRequestBody, options).then(function (request) { return request(axios, basePath); });
4301
4370
  },
4371
+ /**
4372
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4373
+ * @summary Leave org
4374
+ * @param {string} orgId
4375
+ * @param {*} [options] Override http request option.
4376
+ * @throws {RequiredError}
4377
+ */
4378
+ leaveOrg: function (orgId, options) {
4379
+ return localVarFp.leaveOrg(orgId, options).then(function (request) { return request(axios, basePath); });
4380
+ },
4302
4381
  /**
4303
4382
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4304
4383
  * @summary Rematerialize Role Assignment
@@ -4348,6 +4427,18 @@ var RoleAssignmentApi = /** @class */ (function (_super) {
4348
4427
  var _this = this;
4349
4428
  return (0, exports.RoleAssignmentApiFp)(this.configuration).applyRoleAssignment(orgId, roleAssignmentRequestBody, options).then(function (request) { return request(_this.axios, _this.basePath); });
4350
4429
  };
4430
+ /**
4431
+ * Removes the caller from the org: revokes all of their V2 role assignments, reconciles away their policies, and removes them from the org user list. Does not change their Zeus teammate record.
4432
+ * @summary Leave org
4433
+ * @param {string} orgId
4434
+ * @param {*} [options] Override http request option.
4435
+ * @throws {RequiredError}
4436
+ * @memberof RoleAssignmentApi
4437
+ */
4438
+ RoleAssignmentApi.prototype.leaveOrg = function (orgId, options) {
4439
+ var _this = this;
4440
+ return (0, exports.RoleAssignmentApiFp)(this.configuration).leaveOrg(orgId, options).then(function (request) { return request(_this.axios, _this.basePath); });
4441
+ };
4351
4442
  /**
4352
4443
  * Reconciles policy assignments for the role assignment principal: creates missing policies and revokes leftovers that materialize no longer emits
4353
4444
  * @summary Rematerialize Role Assignment
@@ -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.0.552-rc.1790679260"
39
+ "user-agent": "Flipdish authorization typescript SDK / 0.0.554-rc.1790701085"
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.0.552-rc.1790679260",
3
+ "version": "0.0.554-rc.1790701085",
4
4
  "description": "OpenAPI client for @flipdish/authorization",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "repository": {