@tennac-booking/sdk 1.0.122 → 1.0.123

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.
@@ -281,6 +281,7 @@ docs/SubscribeRequestBody.md
281
281
  docs/SubscriberPrice.md
282
282
  docs/SubscriptionInfo.md
283
283
  docs/SubscriptionMutationResponse.md
284
+ docs/SubscriptionPlanDiscountResponse.md
284
285
  docs/SubscriptionPlanResponse.md
285
286
  docs/SubscriptionsManagerApi.md
286
287
  docs/SubscriptionsPublicApi.md
package/README.md CHANGED
@@ -171,6 +171,7 @@ Class | Method | HTTP request | Description
171
171
  *SportsManagerApi* | [**deleteSport**](docs/SportsManagerApi.md#deletesport) | **DELETE** /api/sports/{id} |
172
172
  *SportsManagerApi* | [**updateSport**](docs/SportsManagerApi.md#updatesport) | **PUT** /api/sports/{id} |
173
173
  *SportsPublicApi* | [**getVerifiedSports**](docs/SportsPublicApi.md#getverifiedsports) | **GET** /api/sports/verified |
174
+ *SubscriptionsManagerApi* | [**archivePlan**](docs/SubscriptionsManagerApi.md#archiveplan) | **POST** /api/subscriptions/plans/{productId}/archive |
174
175
  *SubscriptionsManagerApi* | [**createPlan**](docs/SubscriptionsManagerApi.md#createplan) | **POST** /api/subscriptions/plans |
175
176
  *SubscriptionsManagerApi* | [**deletePlan**](docs/SubscriptionsManagerApi.md#deleteplan) | **DELETE** /api/subscriptions/plans/{productId} |
176
177
  *SubscriptionsManagerApi* | [**updatePlan**](docs/SubscriptionsManagerApi.md#updateplan) | **PUT** /api/subscriptions/plans |
@@ -476,6 +477,7 @@ Class | Method | HTTP request | Description
476
477
  - [SubscriberPrice](docs/SubscriberPrice.md)
477
478
  - [SubscriptionInfo](docs/SubscriptionInfo.md)
478
479
  - [SubscriptionMutationResponse](docs/SubscriptionMutationResponse.md)
480
+ - [SubscriptionPlanDiscountResponse](docs/SubscriptionPlanDiscountResponse.md)
479
481
  - [SubscriptionPlanResponse](docs/SubscriptionPlanResponse.md)
480
482
  - [SurfaceType](docs/SurfaceType.md)
481
483
  - [Team](docs/Team.md)
package/api.ts CHANGED
@@ -4302,6 +4302,12 @@ export interface DeleteSubscriptionPlanResponse {
4302
4302
  * @memberof DeleteSubscriptionPlanResponse
4303
4303
  */
4304
4304
  'message': string;
4305
+ /**
4306
+ *
4307
+ * @type {boolean}
4308
+ * @memberof DeleteSubscriptionPlanResponse
4309
+ */
4310
+ 'archivedInstead'?: boolean;
4305
4311
  }
4306
4312
  /**
4307
4313
  *
@@ -6940,6 +6946,12 @@ export interface PublicSubscriptionPlanResponse {
6940
6946
  * @memberof PublicSubscriptionPlanResponse
6941
6947
  */
6942
6948
  'description'?: string;
6949
+ /**
6950
+ *
6951
+ * @type {SubscriptionPlanDiscountResponse}
6952
+ * @memberof PublicSubscriptionPlanResponse
6953
+ */
6954
+ 'discount'?: SubscriptionPlanDiscountResponse;
6943
6955
  }
6944
6956
 
6945
6957
 
@@ -9736,6 +9748,63 @@ export interface SubscriptionMutationResponse {
9736
9748
  */
9737
9749
  'subscription': { [key: string]: any; };
9738
9750
  }
9751
+ /**
9752
+ *
9753
+ * @export
9754
+ * @interface SubscriptionPlanDiscountResponse
9755
+ */
9756
+ export interface SubscriptionPlanDiscountResponse {
9757
+ /**
9758
+ *
9759
+ * @type {DiscountType}
9760
+ * @memberof SubscriptionPlanDiscountResponse
9761
+ */
9762
+ 'type': DiscountType;
9763
+ /**
9764
+ *
9765
+ * @type {number}
9766
+ * @memberof SubscriptionPlanDiscountResponse
9767
+ */
9768
+ 'percentage'?: number;
9769
+ /**
9770
+ *
9771
+ * @type {number}
9772
+ * @memberof SubscriptionPlanDiscountResponse
9773
+ */
9774
+ 'maxDiscountAmountInCents'?: number;
9775
+ /**
9776
+ *
9777
+ * @type {string}
9778
+ * @memberof SubscriptionPlanDiscountResponse
9779
+ */
9780
+ 'validFrom'?: string;
9781
+ /**
9782
+ *
9783
+ * @type {string}
9784
+ * @memberof SubscriptionPlanDiscountResponse
9785
+ */
9786
+ 'validTo'?: string;
9787
+ /**
9788
+ *
9789
+ * @type {Array<string>}
9790
+ * @memberof SubscriptionPlanDiscountResponse
9791
+ */
9792
+ 'offPeakRuleNames'?: Array<string>;
9793
+ /**
9794
+ *
9795
+ * @type {Array<OffPeakRule>}
9796
+ * @memberof SubscriptionPlanDiscountResponse
9797
+ */
9798
+ 'offPeakRules'?: Array<OffPeakRule>;
9799
+ /**
9800
+ *
9801
+ * @type {boolean}
9802
+ * @memberof SubscriptionPlanDiscountResponse
9803
+ */
9804
+ 'bookingFree'?: boolean;
9805
+ }
9806
+
9807
+
9739
9808
  /**
9740
9809
  *
9741
9810
  * @export
@@ -9790,6 +9859,18 @@ export interface SubscriptionPlanResponse {
9790
9859
  * @memberof SubscriptionPlanResponse
9791
9860
  */
9792
9861
  'priceActive': boolean;
9862
+ /**
9863
+ *
9864
+ * @type {string}
9865
+ * @memberof SubscriptionPlanResponse
9866
+ */
9867
+ 'description'?: string;
9868
+ /**
9869
+ *
9870
+ * @type {SubscriptionPlanDiscountResponse}
9871
+ * @memberof SubscriptionPlanResponse
9872
+ */
9873
+ 'discount'?: SubscriptionPlanDiscountResponse;
9793
9874
  }
9794
9875
 
9795
9876
 
@@ -22241,6 +22322,43 @@ export class SportsPublicApi extends BaseAPI {
22241
22322
  */
22242
22323
  export const SubscriptionsManagerApiAxiosParamCreator = function (configuration?: Configuration) {
22243
22324
  return {
22325
+ /**
22326
+ * Supprime (archive) un plan par productId (manager)
22327
+ * @param {string} productId
22328
+ * @param {*} [options] Override http request option.
22329
+ * @throws {RequiredError}
22330
+ */
22331
+ archivePlan: async (productId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
22332
+ // verify required parameter 'productId' is not null or undefined
22333
+ assertParamExists('archivePlan', 'productId', productId)
22334
+ const localVarPath = `/api/subscriptions/plans/{productId}/archive`
22335
+ .replace(`{${"productId"}}`, encodeURIComponent(String(productId)));
22336
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
22337
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
22338
+ let baseOptions;
22339
+ if (configuration) {
22340
+ baseOptions = configuration.baseOptions;
22341
+ }
22342
+
22343
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
22344
+ const localVarHeaderParameter = {} as any;
22345
+ const localVarQueryParameter = {} as any;
22346
+
22347
+ // authentication bearerAuth required
22348
+ // http bearer authentication required
22349
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
22350
+
22351
+
22352
+
22353
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
22354
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
22355
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
22356
+
22357
+ return {
22358
+ url: toPathString(localVarUrlObj),
22359
+ options: localVarRequestOptions,
22360
+ };
22361
+ },
22244
22362
  /**
22245
22363
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
22246
22364
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -22281,7 +22399,7 @@ export const SubscriptionsManagerApiAxiosParamCreator = function (configuration?
22281
22399
  };
22282
22400
  },
22283
22401
  /**
22284
- * Supprime (archive) un plan par productId (manager)
22402
+ * Supprime un plan par productId (manager)
22285
22403
  * @param {string} productId
22286
22404
  * @param {*} [options] Override http request option.
22287
22405
  * @throws {RequiredError}
@@ -22366,6 +22484,18 @@ export const SubscriptionsManagerApiAxiosParamCreator = function (configuration?
22366
22484
  export const SubscriptionsManagerApiFp = function(configuration?: Configuration) {
22367
22485
  const localVarAxiosParamCreator = SubscriptionsManagerApiAxiosParamCreator(configuration)
22368
22486
  return {
22487
+ /**
22488
+ * Supprime (archive) un plan par productId (manager)
22489
+ * @param {string} productId
22490
+ * @param {*} [options] Override http request option.
22491
+ * @throws {RequiredError}
22492
+ */
22493
+ async archivePlan(productId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DeleteSubscriptionPlanResponse>> {
22494
+ const localVarAxiosArgs = await localVarAxiosParamCreator.archivePlan(productId, options);
22495
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
22496
+ const localVarOperationServerBasePath = operationServerMap['SubscriptionsManagerApi.archivePlan']?.[localVarOperationServerIndex]?.url;
22497
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
22498
+ },
22369
22499
  /**
22370
22500
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
22371
22501
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -22379,7 +22509,7 @@ export const SubscriptionsManagerApiFp = function(configuration?: Configuration)
22379
22509
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
22380
22510
  },
22381
22511
  /**
22382
- * Supprime (archive) un plan par productId (manager)
22512
+ * Supprime un plan par productId (manager)
22383
22513
  * @param {string} productId
22384
22514
  * @param {*} [options] Override http request option.
22385
22515
  * @throws {RequiredError}
@@ -22412,6 +22542,15 @@ export const SubscriptionsManagerApiFp = function(configuration?: Configuration)
22412
22542
  export const SubscriptionsManagerApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
22413
22543
  const localVarFp = SubscriptionsManagerApiFp(configuration)
22414
22544
  return {
22545
+ /**
22546
+ * Supprime (archive) un plan par productId (manager)
22547
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
22548
+ * @param {*} [options] Override http request option.
22549
+ * @throws {RequiredError}
22550
+ */
22551
+ archivePlan(requestParameters: SubscriptionsManagerApiArchivePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<DeleteSubscriptionPlanResponse> {
22552
+ return localVarFp.archivePlan(requestParameters.productId, options).then((request) => request(axios, basePath));
22553
+ },
22415
22554
  /**
22416
22555
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
22417
22556
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -22422,7 +22561,7 @@ export const SubscriptionsManagerApiFactory = function (configuration?: Configur
22422
22561
  return localVarFp.createPlan(requestParameters.createSubscriptionPlanRequest, options).then((request) => request(axios, basePath));
22423
22562
  },
22424
22563
  /**
22425
- * Supprime (archive) un plan par productId (manager)
22564
+ * Supprime un plan par productId (manager)
22426
22565
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
22427
22566
  * @param {*} [options] Override http request option.
22428
22567
  * @throws {RequiredError}
@@ -22442,6 +22581,20 @@ export const SubscriptionsManagerApiFactory = function (configuration?: Configur
22442
22581
  };
22443
22582
  };
22444
22583
 
22584
+ /**
22585
+ * Request parameters for archivePlan operation in SubscriptionsManagerApi.
22586
+ * @export
22587
+ * @interface SubscriptionsManagerApiArchivePlanRequest
22588
+ */
22589
+ export interface SubscriptionsManagerApiArchivePlanRequest {
22590
+ /**
22591
+ *
22592
+ * @type {string}
22593
+ * @memberof SubscriptionsManagerApiArchivePlan
22594
+ */
22595
+ readonly productId: string
22596
+ }
22597
+
22445
22598
  /**
22446
22599
  * Request parameters for createPlan operation in SubscriptionsManagerApi.
22447
22600
  * @export
@@ -22491,6 +22644,17 @@ export interface SubscriptionsManagerApiUpdatePlanRequest {
22491
22644
  * @extends {BaseAPI}
22492
22645
  */
22493
22646
  export class SubscriptionsManagerApi extends BaseAPI {
22647
+ /**
22648
+ * Supprime (archive) un plan par productId (manager)
22649
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
22650
+ * @param {*} [options] Override http request option.
22651
+ * @throws {RequiredError}
22652
+ * @memberof SubscriptionsManagerApi
22653
+ */
22654
+ public archivePlan(requestParameters: SubscriptionsManagerApiArchivePlanRequest, options?: RawAxiosRequestConfig) {
22655
+ return SubscriptionsManagerApiFp(this.configuration).archivePlan(requestParameters.productId, options).then((request) => request(this.axios, this.basePath));
22656
+ }
22657
+
22494
22658
  /**
22495
22659
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
22496
22660
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -22503,7 +22667,7 @@ export class SubscriptionsManagerApi extends BaseAPI {
22503
22667
  }
22504
22668
 
22505
22669
  /**
22506
- * Supprime (archive) un plan par productId (manager)
22670
+ * Supprime un plan par productId (manager)
22507
22671
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
22508
22672
  * @param {*} [options] Override http request option.
22509
22673
  * @throws {RequiredError}
package/dist/api.d.ts CHANGED
@@ -4230,6 +4230,12 @@ export interface DeleteSubscriptionPlanResponse {
4230
4230
  * @memberof DeleteSubscriptionPlanResponse
4231
4231
  */
4232
4232
  'message': string;
4233
+ /**
4234
+ *
4235
+ * @type {boolean}
4236
+ * @memberof DeleteSubscriptionPlanResponse
4237
+ */
4238
+ 'archivedInstead'?: boolean;
4233
4239
  }
4234
4240
  /**
4235
4241
  *
@@ -6831,6 +6837,12 @@ export interface PublicSubscriptionPlanResponse {
6831
6837
  * @memberof PublicSubscriptionPlanResponse
6832
6838
  */
6833
6839
  'description'?: string;
6840
+ /**
6841
+ *
6842
+ * @type {SubscriptionPlanDiscountResponse}
6843
+ * @memberof PublicSubscriptionPlanResponse
6844
+ */
6845
+ 'discount'?: SubscriptionPlanDiscountResponse;
6834
6846
  }
6835
6847
  /**
6836
6848
  *
@@ -9564,6 +9576,61 @@ export interface SubscriptionMutationResponse {
9564
9576
  [key: string]: any;
9565
9577
  };
9566
9578
  }
9579
+ /**
9580
+ *
9581
+ * @export
9582
+ * @interface SubscriptionPlanDiscountResponse
9583
+ */
9584
+ export interface SubscriptionPlanDiscountResponse {
9585
+ /**
9586
+ *
9587
+ * @type {DiscountType}
9588
+ * @memberof SubscriptionPlanDiscountResponse
9589
+ */
9590
+ 'type': DiscountType;
9591
+ /**
9592
+ *
9593
+ * @type {number}
9594
+ * @memberof SubscriptionPlanDiscountResponse
9595
+ */
9596
+ 'percentage'?: number;
9597
+ /**
9598
+ *
9599
+ * @type {number}
9600
+ * @memberof SubscriptionPlanDiscountResponse
9601
+ */
9602
+ 'maxDiscountAmountInCents'?: number;
9603
+ /**
9604
+ *
9605
+ * @type {string}
9606
+ * @memberof SubscriptionPlanDiscountResponse
9607
+ */
9608
+ 'validFrom'?: string;
9609
+ /**
9610
+ *
9611
+ * @type {string}
9612
+ * @memberof SubscriptionPlanDiscountResponse
9613
+ */
9614
+ 'validTo'?: string;
9615
+ /**
9616
+ *
9617
+ * @type {Array<string>}
9618
+ * @memberof SubscriptionPlanDiscountResponse
9619
+ */
9620
+ 'offPeakRuleNames'?: Array<string>;
9621
+ /**
9622
+ *
9623
+ * @type {Array<OffPeakRule>}
9624
+ * @memberof SubscriptionPlanDiscountResponse
9625
+ */
9626
+ 'offPeakRules'?: Array<OffPeakRule>;
9627
+ /**
9628
+ *
9629
+ * @type {boolean}
9630
+ * @memberof SubscriptionPlanDiscountResponse
9631
+ */
9632
+ 'bookingFree'?: boolean;
9633
+ }
9567
9634
  /**
9568
9635
  *
9569
9636
  * @export
@@ -9618,6 +9685,18 @@ export interface SubscriptionPlanResponse {
9618
9685
  * @memberof SubscriptionPlanResponse
9619
9686
  */
9620
9687
  'priceActive': boolean;
9688
+ /**
9689
+ *
9690
+ * @type {string}
9691
+ * @memberof SubscriptionPlanResponse
9692
+ */
9693
+ 'description'?: string;
9694
+ /**
9695
+ *
9696
+ * @type {SubscriptionPlanDiscountResponse}
9697
+ * @memberof SubscriptionPlanResponse
9698
+ */
9699
+ 'discount'?: SubscriptionPlanDiscountResponse;
9621
9700
  }
9622
9701
  /**
9623
9702
  *
@@ -16672,6 +16751,13 @@ export declare class SportsPublicApi extends BaseAPI {
16672
16751
  * @export
16673
16752
  */
16674
16753
  export declare const SubscriptionsManagerApiAxiosParamCreator: (configuration?: Configuration) => {
16754
+ /**
16755
+ * Supprime (archive) un plan par productId (manager)
16756
+ * @param {string} productId
16757
+ * @param {*} [options] Override http request option.
16758
+ * @throws {RequiredError}
16759
+ */
16760
+ archivePlan: (productId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
16675
16761
  /**
16676
16762
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16677
16763
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -16680,7 +16766,7 @@ export declare const SubscriptionsManagerApiAxiosParamCreator: (configuration?:
16680
16766
  */
16681
16767
  createPlan: (createSubscriptionPlanRequest: CreateSubscriptionPlanRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
16682
16768
  /**
16683
- * Supprime (archive) un plan par productId (manager)
16769
+ * Supprime un plan par productId (manager)
16684
16770
  * @param {string} productId
16685
16771
  * @param {*} [options] Override http request option.
16686
16772
  * @throws {RequiredError}
@@ -16699,6 +16785,13 @@ export declare const SubscriptionsManagerApiAxiosParamCreator: (configuration?:
16699
16785
  * @export
16700
16786
  */
16701
16787
  export declare const SubscriptionsManagerApiFp: (configuration?: Configuration) => {
16788
+ /**
16789
+ * Supprime (archive) un plan par productId (manager)
16790
+ * @param {string} productId
16791
+ * @param {*} [options] Override http request option.
16792
+ * @throws {RequiredError}
16793
+ */
16794
+ archivePlan(productId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DeleteSubscriptionPlanResponse>>;
16702
16795
  /**
16703
16796
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16704
16797
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -16707,7 +16800,7 @@ export declare const SubscriptionsManagerApiFp: (configuration?: Configuration)
16707
16800
  */
16708
16801
  createPlan(createSubscriptionPlanRequest: CreateSubscriptionPlanRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePlan201Response>>;
16709
16802
  /**
16710
- * Supprime (archive) un plan par productId (manager)
16803
+ * Supprime un plan par productId (manager)
16711
16804
  * @param {string} productId
16712
16805
  * @param {*} [options] Override http request option.
16713
16806
  * @throws {RequiredError}
@@ -16726,6 +16819,13 @@ export declare const SubscriptionsManagerApiFp: (configuration?: Configuration)
16726
16819
  * @export
16727
16820
  */
16728
16821
  export declare const SubscriptionsManagerApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
16822
+ /**
16823
+ * Supprime (archive) un plan par productId (manager)
16824
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
16825
+ * @param {*} [options] Override http request option.
16826
+ * @throws {RequiredError}
16827
+ */
16828
+ archivePlan(requestParameters: SubscriptionsManagerApiArchivePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<DeleteSubscriptionPlanResponse>;
16729
16829
  /**
16730
16830
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16731
16831
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -16734,7 +16834,7 @@ export declare const SubscriptionsManagerApiFactory: (configuration?: Configurat
16734
16834
  */
16735
16835
  createPlan(requestParameters: SubscriptionsManagerApiCreatePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<CreatePlan201Response>;
16736
16836
  /**
16737
- * Supprime (archive) un plan par productId (manager)
16837
+ * Supprime un plan par productId (manager)
16738
16838
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
16739
16839
  * @param {*} [options] Override http request option.
16740
16840
  * @throws {RequiredError}
@@ -16748,6 +16848,19 @@ export declare const SubscriptionsManagerApiFactory: (configuration?: Configurat
16748
16848
  */
16749
16849
  updatePlan(requestParameters: SubscriptionsManagerApiUpdatePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<StripeStripeResponseStripeStripePrice>;
16750
16850
  };
16851
+ /**
16852
+ * Request parameters for archivePlan operation in SubscriptionsManagerApi.
16853
+ * @export
16854
+ * @interface SubscriptionsManagerApiArchivePlanRequest
16855
+ */
16856
+ export interface SubscriptionsManagerApiArchivePlanRequest {
16857
+ /**
16858
+ *
16859
+ * @type {string}
16860
+ * @memberof SubscriptionsManagerApiArchivePlan
16861
+ */
16862
+ readonly productId: string;
16863
+ }
16751
16864
  /**
16752
16865
  * Request parameters for createPlan operation in SubscriptionsManagerApi.
16753
16866
  * @export
@@ -16794,6 +16907,14 @@ export interface SubscriptionsManagerApiUpdatePlanRequest {
16794
16907
  * @extends {BaseAPI}
16795
16908
  */
16796
16909
  export declare class SubscriptionsManagerApi extends BaseAPI {
16910
+ /**
16911
+ * Supprime (archive) un plan par productId (manager)
16912
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
16913
+ * @param {*} [options] Override http request option.
16914
+ * @throws {RequiredError}
16915
+ * @memberof SubscriptionsManagerApi
16916
+ */
16917
+ archivePlan(requestParameters: SubscriptionsManagerApiArchivePlanRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<DeleteSubscriptionPlanResponse, any, {}>>;
16797
16918
  /**
16798
16919
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16799
16920
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -16803,7 +16924,7 @@ export declare class SubscriptionsManagerApi extends BaseAPI {
16803
16924
  */
16804
16925
  createPlan(requestParameters: SubscriptionsManagerApiCreatePlanRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<CreatePlan201Response, any, {}>>;
16805
16926
  /**
16806
- * Supprime (archive) un plan par productId (manager)
16927
+ * Supprime un plan par productId (manager)
16807
16928
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
16808
16929
  * @param {*} [options] Override http request option.
16809
16930
  * @throws {RequiredError}
package/dist/api.js CHANGED
@@ -9148,6 +9148,37 @@ exports.SportsPublicApi = SportsPublicApi;
9148
9148
  */
9149
9149
  const SubscriptionsManagerApiAxiosParamCreator = function (configuration) {
9150
9150
  return {
9151
+ /**
9152
+ * Supprime (archive) un plan par productId (manager)
9153
+ * @param {string} productId
9154
+ * @param {*} [options] Override http request option.
9155
+ * @throws {RequiredError}
9156
+ */
9157
+ archivePlan: (productId_1, ...args_1) => __awaiter(this, [productId_1, ...args_1], void 0, function* (productId, options = {}) {
9158
+ // verify required parameter 'productId' is not null or undefined
9159
+ (0, common_1.assertParamExists)('archivePlan', 'productId', productId);
9160
+ const localVarPath = `/api/subscriptions/plans/{productId}/archive`
9161
+ .replace(`{${"productId"}}`, encodeURIComponent(String(productId)));
9162
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
9163
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
9164
+ let baseOptions;
9165
+ if (configuration) {
9166
+ baseOptions = configuration.baseOptions;
9167
+ }
9168
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
9169
+ const localVarHeaderParameter = {};
9170
+ const localVarQueryParameter = {};
9171
+ // authentication bearerAuth required
9172
+ // http bearer authentication required
9173
+ yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
9174
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
9175
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
9176
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
9177
+ return {
9178
+ url: (0, common_1.toPathString)(localVarUrlObj),
9179
+ options: localVarRequestOptions,
9180
+ };
9181
+ }),
9151
9182
  /**
9152
9183
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9153
9184
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -9181,7 +9212,7 @@ const SubscriptionsManagerApiAxiosParamCreator = function (configuration) {
9181
9212
  };
9182
9213
  }),
9183
9214
  /**
9184
- * Supprime (archive) un plan par productId (manager)
9215
+ * Supprime un plan par productId (manager)
9185
9216
  * @param {string} productId
9186
9217
  * @param {*} [options] Override http request option.
9187
9218
  * @throws {RequiredError}
@@ -9253,6 +9284,21 @@ exports.SubscriptionsManagerApiAxiosParamCreator = SubscriptionsManagerApiAxiosP
9253
9284
  const SubscriptionsManagerApiFp = function (configuration) {
9254
9285
  const localVarAxiosParamCreator = (0, exports.SubscriptionsManagerApiAxiosParamCreator)(configuration);
9255
9286
  return {
9287
+ /**
9288
+ * Supprime (archive) un plan par productId (manager)
9289
+ * @param {string} productId
9290
+ * @param {*} [options] Override http request option.
9291
+ * @throws {RequiredError}
9292
+ */
9293
+ archivePlan(productId, options) {
9294
+ return __awaiter(this, void 0, void 0, function* () {
9295
+ var _a, _b, _c;
9296
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.archivePlan(productId, options);
9297
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
9298
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['SubscriptionsManagerApi.archivePlan']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
9299
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
9300
+ });
9301
+ },
9256
9302
  /**
9257
9303
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9258
9304
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -9269,7 +9315,7 @@ const SubscriptionsManagerApiFp = function (configuration) {
9269
9315
  });
9270
9316
  },
9271
9317
  /**
9272
- * Supprime (archive) un plan par productId (manager)
9318
+ * Supprime un plan par productId (manager)
9273
9319
  * @param {string} productId
9274
9320
  * @param {*} [options] Override http request option.
9275
9321
  * @throws {RequiredError}
@@ -9308,6 +9354,15 @@ exports.SubscriptionsManagerApiFp = SubscriptionsManagerApiFp;
9308
9354
  const SubscriptionsManagerApiFactory = function (configuration, basePath, axios) {
9309
9355
  const localVarFp = (0, exports.SubscriptionsManagerApiFp)(configuration);
9310
9356
  return {
9357
+ /**
9358
+ * Supprime (archive) un plan par productId (manager)
9359
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
9360
+ * @param {*} [options] Override http request option.
9361
+ * @throws {RequiredError}
9362
+ */
9363
+ archivePlan(requestParameters, options) {
9364
+ return localVarFp.archivePlan(requestParameters.productId, options).then((request) => request(axios, basePath));
9365
+ },
9311
9366
  /**
9312
9367
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9313
9368
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -9318,7 +9373,7 @@ const SubscriptionsManagerApiFactory = function (configuration, basePath, axios)
9318
9373
  return localVarFp.createPlan(requestParameters.createSubscriptionPlanRequest, options).then((request) => request(axios, basePath));
9319
9374
  },
9320
9375
  /**
9321
- * Supprime (archive) un plan par productId (manager)
9376
+ * Supprime un plan par productId (manager)
9322
9377
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
9323
9378
  * @param {*} [options] Override http request option.
9324
9379
  * @throws {RequiredError}
@@ -9345,6 +9400,16 @@ exports.SubscriptionsManagerApiFactory = SubscriptionsManagerApiFactory;
9345
9400
  * @extends {BaseAPI}
9346
9401
  */
9347
9402
  class SubscriptionsManagerApi extends base_1.BaseAPI {
9403
+ /**
9404
+ * Supprime (archive) un plan par productId (manager)
9405
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
9406
+ * @param {*} [options] Override http request option.
9407
+ * @throws {RequiredError}
9408
+ * @memberof SubscriptionsManagerApi
9409
+ */
9410
+ archivePlan(requestParameters, options) {
9411
+ return (0, exports.SubscriptionsManagerApiFp)(this.configuration).archivePlan(requestParameters.productId, options).then((request) => request(this.axios, this.basePath));
9412
+ }
9348
9413
  /**
9349
9414
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9350
9415
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -9356,7 +9421,7 @@ class SubscriptionsManagerApi extends base_1.BaseAPI {
9356
9421
  return (0, exports.SubscriptionsManagerApiFp)(this.configuration).createPlan(requestParameters.createSubscriptionPlanRequest, options).then((request) => request(this.axios, this.basePath));
9357
9422
  }
9358
9423
  /**
9359
- * Supprime (archive) un plan par productId (manager)
9424
+ * Supprime un plan par productId (manager)
9360
9425
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
9361
9426
  * @param {*} [options] Override http request option.
9362
9427
  * @throws {RequiredError}
package/dist/esm/api.d.ts CHANGED
@@ -4230,6 +4230,12 @@ export interface DeleteSubscriptionPlanResponse {
4230
4230
  * @memberof DeleteSubscriptionPlanResponse
4231
4231
  */
4232
4232
  'message': string;
4233
+ /**
4234
+ *
4235
+ * @type {boolean}
4236
+ * @memberof DeleteSubscriptionPlanResponse
4237
+ */
4238
+ 'archivedInstead'?: boolean;
4233
4239
  }
4234
4240
  /**
4235
4241
  *
@@ -6831,6 +6837,12 @@ export interface PublicSubscriptionPlanResponse {
6831
6837
  * @memberof PublicSubscriptionPlanResponse
6832
6838
  */
6833
6839
  'description'?: string;
6840
+ /**
6841
+ *
6842
+ * @type {SubscriptionPlanDiscountResponse}
6843
+ * @memberof PublicSubscriptionPlanResponse
6844
+ */
6845
+ 'discount'?: SubscriptionPlanDiscountResponse;
6834
6846
  }
6835
6847
  /**
6836
6848
  *
@@ -9564,6 +9576,61 @@ export interface SubscriptionMutationResponse {
9564
9576
  [key: string]: any;
9565
9577
  };
9566
9578
  }
9579
+ /**
9580
+ *
9581
+ * @export
9582
+ * @interface SubscriptionPlanDiscountResponse
9583
+ */
9584
+ export interface SubscriptionPlanDiscountResponse {
9585
+ /**
9586
+ *
9587
+ * @type {DiscountType}
9588
+ * @memberof SubscriptionPlanDiscountResponse
9589
+ */
9590
+ 'type': DiscountType;
9591
+ /**
9592
+ *
9593
+ * @type {number}
9594
+ * @memberof SubscriptionPlanDiscountResponse
9595
+ */
9596
+ 'percentage'?: number;
9597
+ /**
9598
+ *
9599
+ * @type {number}
9600
+ * @memberof SubscriptionPlanDiscountResponse
9601
+ */
9602
+ 'maxDiscountAmountInCents'?: number;
9603
+ /**
9604
+ *
9605
+ * @type {string}
9606
+ * @memberof SubscriptionPlanDiscountResponse
9607
+ */
9608
+ 'validFrom'?: string;
9609
+ /**
9610
+ *
9611
+ * @type {string}
9612
+ * @memberof SubscriptionPlanDiscountResponse
9613
+ */
9614
+ 'validTo'?: string;
9615
+ /**
9616
+ *
9617
+ * @type {Array<string>}
9618
+ * @memberof SubscriptionPlanDiscountResponse
9619
+ */
9620
+ 'offPeakRuleNames'?: Array<string>;
9621
+ /**
9622
+ *
9623
+ * @type {Array<OffPeakRule>}
9624
+ * @memberof SubscriptionPlanDiscountResponse
9625
+ */
9626
+ 'offPeakRules'?: Array<OffPeakRule>;
9627
+ /**
9628
+ *
9629
+ * @type {boolean}
9630
+ * @memberof SubscriptionPlanDiscountResponse
9631
+ */
9632
+ 'bookingFree'?: boolean;
9633
+ }
9567
9634
  /**
9568
9635
  *
9569
9636
  * @export
@@ -9618,6 +9685,18 @@ export interface SubscriptionPlanResponse {
9618
9685
  * @memberof SubscriptionPlanResponse
9619
9686
  */
9620
9687
  'priceActive': boolean;
9688
+ /**
9689
+ *
9690
+ * @type {string}
9691
+ * @memberof SubscriptionPlanResponse
9692
+ */
9693
+ 'description'?: string;
9694
+ /**
9695
+ *
9696
+ * @type {SubscriptionPlanDiscountResponse}
9697
+ * @memberof SubscriptionPlanResponse
9698
+ */
9699
+ 'discount'?: SubscriptionPlanDiscountResponse;
9621
9700
  }
9622
9701
  /**
9623
9702
  *
@@ -16672,6 +16751,13 @@ export declare class SportsPublicApi extends BaseAPI {
16672
16751
  * @export
16673
16752
  */
16674
16753
  export declare const SubscriptionsManagerApiAxiosParamCreator: (configuration?: Configuration) => {
16754
+ /**
16755
+ * Supprime (archive) un plan par productId (manager)
16756
+ * @param {string} productId
16757
+ * @param {*} [options] Override http request option.
16758
+ * @throws {RequiredError}
16759
+ */
16760
+ archivePlan: (productId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
16675
16761
  /**
16676
16762
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16677
16763
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -16680,7 +16766,7 @@ export declare const SubscriptionsManagerApiAxiosParamCreator: (configuration?:
16680
16766
  */
16681
16767
  createPlan: (createSubscriptionPlanRequest: CreateSubscriptionPlanRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
16682
16768
  /**
16683
- * Supprime (archive) un plan par productId (manager)
16769
+ * Supprime un plan par productId (manager)
16684
16770
  * @param {string} productId
16685
16771
  * @param {*} [options] Override http request option.
16686
16772
  * @throws {RequiredError}
@@ -16699,6 +16785,13 @@ export declare const SubscriptionsManagerApiAxiosParamCreator: (configuration?:
16699
16785
  * @export
16700
16786
  */
16701
16787
  export declare const SubscriptionsManagerApiFp: (configuration?: Configuration) => {
16788
+ /**
16789
+ * Supprime (archive) un plan par productId (manager)
16790
+ * @param {string} productId
16791
+ * @param {*} [options] Override http request option.
16792
+ * @throws {RequiredError}
16793
+ */
16794
+ archivePlan(productId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DeleteSubscriptionPlanResponse>>;
16702
16795
  /**
16703
16796
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16704
16797
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -16707,7 +16800,7 @@ export declare const SubscriptionsManagerApiFp: (configuration?: Configuration)
16707
16800
  */
16708
16801
  createPlan(createSubscriptionPlanRequest: CreateSubscriptionPlanRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CreatePlan201Response>>;
16709
16802
  /**
16710
- * Supprime (archive) un plan par productId (manager)
16803
+ * Supprime un plan par productId (manager)
16711
16804
  * @param {string} productId
16712
16805
  * @param {*} [options] Override http request option.
16713
16806
  * @throws {RequiredError}
@@ -16726,6 +16819,13 @@ export declare const SubscriptionsManagerApiFp: (configuration?: Configuration)
16726
16819
  * @export
16727
16820
  */
16728
16821
  export declare const SubscriptionsManagerApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
16822
+ /**
16823
+ * Supprime (archive) un plan par productId (manager)
16824
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
16825
+ * @param {*} [options] Override http request option.
16826
+ * @throws {RequiredError}
16827
+ */
16828
+ archivePlan(requestParameters: SubscriptionsManagerApiArchivePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<DeleteSubscriptionPlanResponse>;
16729
16829
  /**
16730
16830
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16731
16831
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -16734,7 +16834,7 @@ export declare const SubscriptionsManagerApiFactory: (configuration?: Configurat
16734
16834
  */
16735
16835
  createPlan(requestParameters: SubscriptionsManagerApiCreatePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<CreatePlan201Response>;
16736
16836
  /**
16737
- * Supprime (archive) un plan par productId (manager)
16837
+ * Supprime un plan par productId (manager)
16738
16838
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
16739
16839
  * @param {*} [options] Override http request option.
16740
16840
  * @throws {RequiredError}
@@ -16748,6 +16848,19 @@ export declare const SubscriptionsManagerApiFactory: (configuration?: Configurat
16748
16848
  */
16749
16849
  updatePlan(requestParameters: SubscriptionsManagerApiUpdatePlanRequest, options?: RawAxiosRequestConfig): AxiosPromise<StripeStripeResponseStripeStripePrice>;
16750
16850
  };
16851
+ /**
16852
+ * Request parameters for archivePlan operation in SubscriptionsManagerApi.
16853
+ * @export
16854
+ * @interface SubscriptionsManagerApiArchivePlanRequest
16855
+ */
16856
+ export interface SubscriptionsManagerApiArchivePlanRequest {
16857
+ /**
16858
+ *
16859
+ * @type {string}
16860
+ * @memberof SubscriptionsManagerApiArchivePlan
16861
+ */
16862
+ readonly productId: string;
16863
+ }
16751
16864
  /**
16752
16865
  * Request parameters for createPlan operation in SubscriptionsManagerApi.
16753
16866
  * @export
@@ -16794,6 +16907,14 @@ export interface SubscriptionsManagerApiUpdatePlanRequest {
16794
16907
  * @extends {BaseAPI}
16795
16908
  */
16796
16909
  export declare class SubscriptionsManagerApi extends BaseAPI {
16910
+ /**
16911
+ * Supprime (archive) un plan par productId (manager)
16912
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
16913
+ * @param {*} [options] Override http request option.
16914
+ * @throws {RequiredError}
16915
+ * @memberof SubscriptionsManagerApi
16916
+ */
16917
+ archivePlan(requestParameters: SubscriptionsManagerApiArchivePlanRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<DeleteSubscriptionPlanResponse, any, {}>>;
16797
16918
  /**
16798
16919
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
16799
16920
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -16803,7 +16924,7 @@ export declare class SubscriptionsManagerApi extends BaseAPI {
16803
16924
  */
16804
16925
  createPlan(requestParameters: SubscriptionsManagerApiCreatePlanRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<CreatePlan201Response, any, {}>>;
16805
16926
  /**
16806
- * Supprime (archive) un plan par productId (manager)
16927
+ * Supprime un plan par productId (manager)
16807
16928
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
16808
16929
  * @param {*} [options] Override http request option.
16809
16930
  * @throws {RequiredError}
package/dist/esm/api.js CHANGED
@@ -9058,6 +9058,37 @@ export class SportsPublicApi extends BaseAPI {
9058
9058
  */
9059
9059
  export const SubscriptionsManagerApiAxiosParamCreator = function (configuration) {
9060
9060
  return {
9061
+ /**
9062
+ * Supprime (archive) un plan par productId (manager)
9063
+ * @param {string} productId
9064
+ * @param {*} [options] Override http request option.
9065
+ * @throws {RequiredError}
9066
+ */
9067
+ archivePlan: (productId_1, ...args_1) => __awaiter(this, [productId_1, ...args_1], void 0, function* (productId, options = {}) {
9068
+ // verify required parameter 'productId' is not null or undefined
9069
+ assertParamExists('archivePlan', 'productId', productId);
9070
+ const localVarPath = `/api/subscriptions/plans/{productId}/archive`
9071
+ .replace(`{${"productId"}}`, encodeURIComponent(String(productId)));
9072
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
9073
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
9074
+ let baseOptions;
9075
+ if (configuration) {
9076
+ baseOptions = configuration.baseOptions;
9077
+ }
9078
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
9079
+ const localVarHeaderParameter = {};
9080
+ const localVarQueryParameter = {};
9081
+ // authentication bearerAuth required
9082
+ // http bearer authentication required
9083
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
9084
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
9085
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
9086
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
9087
+ return {
9088
+ url: toPathString(localVarUrlObj),
9089
+ options: localVarRequestOptions,
9090
+ };
9091
+ }),
9061
9092
  /**
9062
9093
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9063
9094
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -9091,7 +9122,7 @@ export const SubscriptionsManagerApiAxiosParamCreator = function (configuration)
9091
9122
  };
9092
9123
  }),
9093
9124
  /**
9094
- * Supprime (archive) un plan par productId (manager)
9125
+ * Supprime un plan par productId (manager)
9095
9126
  * @param {string} productId
9096
9127
  * @param {*} [options] Override http request option.
9097
9128
  * @throws {RequiredError}
@@ -9162,6 +9193,21 @@ export const SubscriptionsManagerApiAxiosParamCreator = function (configuration)
9162
9193
  export const SubscriptionsManagerApiFp = function (configuration) {
9163
9194
  const localVarAxiosParamCreator = SubscriptionsManagerApiAxiosParamCreator(configuration);
9164
9195
  return {
9196
+ /**
9197
+ * Supprime (archive) un plan par productId (manager)
9198
+ * @param {string} productId
9199
+ * @param {*} [options] Override http request option.
9200
+ * @throws {RequiredError}
9201
+ */
9202
+ archivePlan(productId, options) {
9203
+ return __awaiter(this, void 0, void 0, function* () {
9204
+ var _a, _b, _c;
9205
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.archivePlan(productId, options);
9206
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
9207
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SubscriptionsManagerApi.archivePlan']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
9208
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
9209
+ });
9210
+ },
9165
9211
  /**
9166
9212
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9167
9213
  * @param {CreateSubscriptionPlanRequest} createSubscriptionPlanRequest
@@ -9178,7 +9224,7 @@ export const SubscriptionsManagerApiFp = function (configuration) {
9178
9224
  });
9179
9225
  },
9180
9226
  /**
9181
- * Supprime (archive) un plan par productId (manager)
9227
+ * Supprime un plan par productId (manager)
9182
9228
  * @param {string} productId
9183
9229
  * @param {*} [options] Override http request option.
9184
9230
  * @throws {RequiredError}
@@ -9216,6 +9262,15 @@ export const SubscriptionsManagerApiFp = function (configuration) {
9216
9262
  export const SubscriptionsManagerApiFactory = function (configuration, basePath, axios) {
9217
9263
  const localVarFp = SubscriptionsManagerApiFp(configuration);
9218
9264
  return {
9265
+ /**
9266
+ * Supprime (archive) un plan par productId (manager)
9267
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
9268
+ * @param {*} [options] Override http request option.
9269
+ * @throws {RequiredError}
9270
+ */
9271
+ archivePlan(requestParameters, options) {
9272
+ return localVarFp.archivePlan(requestParameters.productId, options).then((request) => request(axios, basePath));
9273
+ },
9219
9274
  /**
9220
9275
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9221
9276
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -9226,7 +9281,7 @@ export const SubscriptionsManagerApiFactory = function (configuration, basePath,
9226
9281
  return localVarFp.createPlan(requestParameters.createSubscriptionPlanRequest, options).then((request) => request(axios, basePath));
9227
9282
  },
9228
9283
  /**
9229
- * Supprime (archive) un plan par productId (manager)
9284
+ * Supprime un plan par productId (manager)
9230
9285
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
9231
9286
  * @param {*} [options] Override http request option.
9232
9287
  * @throws {RequiredError}
@@ -9252,6 +9307,16 @@ export const SubscriptionsManagerApiFactory = function (configuration, basePath,
9252
9307
  * @extends {BaseAPI}
9253
9308
  */
9254
9309
  export class SubscriptionsManagerApi extends BaseAPI {
9310
+ /**
9311
+ * Supprime (archive) un plan par productId (manager)
9312
+ * @param {SubscriptionsManagerApiArchivePlanRequest} requestParameters Request parameters.
9313
+ * @param {*} [options] Override http request option.
9314
+ * @throws {RequiredError}
9315
+ * @memberof SubscriptionsManagerApi
9316
+ */
9317
+ archivePlan(requestParameters, options) {
9318
+ return SubscriptionsManagerApiFp(this.configuration).archivePlan(requestParameters.productId, options).then((request) => request(this.axios, this.basePath));
9319
+ }
9255
9320
  /**
9256
9321
  * Crée un nouveau plan d\'abonnement (produit + price) pour le club (manager)
9257
9322
  * @param {SubscriptionsManagerApiCreatePlanRequest} requestParameters Request parameters.
@@ -9263,7 +9328,7 @@ export class SubscriptionsManagerApi extends BaseAPI {
9263
9328
  return SubscriptionsManagerApiFp(this.configuration).createPlan(requestParameters.createSubscriptionPlanRequest, options).then((request) => request(this.axios, this.basePath));
9264
9329
  }
9265
9330
  /**
9266
- * Supprime (archive) un plan par productId (manager)
9331
+ * Supprime un plan par productId (manager)
9267
9332
  * @param {SubscriptionsManagerApiDeletePlanRequest} requestParameters Request parameters.
9268
9333
  * @param {*} [options] Override http request option.
9269
9334
  * @throws {RequiredError}
@@ -6,6 +6,7 @@
6
6
  Name | Type | Description | Notes
7
7
  ------------ | ------------- | ------------- | -------------
8
8
  **message** | **string** | | [default to undefined]
9
+ **archivedInstead** | **boolean** | | [optional] [default to undefined]
9
10
 
10
11
  ## Example
11
12
 
@@ -14,6 +15,7 @@ import { DeleteSubscriptionPlanResponse } from '@tennac-booking/sdk';
14
15
 
15
16
  const instance: DeleteSubscriptionPlanResponse = {
16
17
  message,
18
+ archivedInstead,
17
19
  };
18
20
  ```
19
21
 
@@ -11,6 +11,7 @@ Name | Type | Description | Notes
11
11
  **currency** | **string** | | [default to undefined]
12
12
  **interval** | [**PlanInterval**](PlanInterval.md) | | [optional] [default to undefined]
13
13
  **description** | **string** | | [optional] [default to undefined]
14
+ **discount** | [**SubscriptionPlanDiscountResponse**](SubscriptionPlanDiscountResponse.md) | | [optional] [default to undefined]
14
15
 
15
16
  ## Example
16
17
 
@@ -24,6 +25,7 @@ const instance: PublicSubscriptionPlanResponse = {
24
25
  currency,
25
26
  interval,
26
27
  description,
28
+ discount,
27
29
  };
28
30
  ```
29
31
 
@@ -0,0 +1,34 @@
1
+ # SubscriptionPlanDiscountResponse
2
+
3
+
4
+ ## Properties
5
+
6
+ Name | Type | Description | Notes
7
+ ------------ | ------------- | ------------- | -------------
8
+ **type** | [**DiscountType**](DiscountType.md) | | [default to undefined]
9
+ **percentage** | **number** | | [optional] [default to undefined]
10
+ **maxDiscountAmountInCents** | **number** | | [optional] [default to undefined]
11
+ **validFrom** | **string** | | [optional] [default to undefined]
12
+ **validTo** | **string** | | [optional] [default to undefined]
13
+ **offPeakRuleNames** | **Array&lt;string&gt;** | | [optional] [default to undefined]
14
+ **offPeakRules** | [**Array&lt;OffPeakRule&gt;**](OffPeakRule.md) | | [optional] [default to undefined]
15
+ **bookingFree** | **boolean** | | [optional] [default to undefined]
16
+
17
+ ## Example
18
+
19
+ ```typescript
20
+ import { SubscriptionPlanDiscountResponse } from '@tennac-booking/sdk';
21
+
22
+ const instance: SubscriptionPlanDiscountResponse = {
23
+ type,
24
+ percentage,
25
+ maxDiscountAmountInCents,
26
+ validFrom,
27
+ validTo,
28
+ offPeakRuleNames,
29
+ offPeakRules,
30
+ bookingFree,
31
+ };
32
+ ```
33
+
34
+ [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
@@ -13,6 +13,8 @@ Name | Type | Description | Notes
13
13
  **currency** | **string** | | [default to undefined]
14
14
  **interval** | [**PlanInterval**](PlanInterval.md) | | [optional] [default to undefined]
15
15
  **priceActive** | **boolean** | | [default to undefined]
16
+ **description** | **string** | | [optional] [default to undefined]
17
+ **discount** | [**SubscriptionPlanDiscountResponse**](SubscriptionPlanDiscountResponse.md) | | [optional] [default to undefined]
16
18
 
17
19
  ## Example
18
20
 
@@ -28,6 +30,8 @@ const instance: SubscriptionPlanResponse = {
28
30
  currency,
29
31
  interval,
30
32
  priceActive,
33
+ description,
34
+ discount,
31
35
  };
32
36
  ```
33
37
 
@@ -4,10 +4,64 @@ All URIs are relative to *http://localhost*
4
4
 
5
5
  |Method | HTTP request | Description|
6
6
  |------------- | ------------- | -------------|
7
+ |[**archivePlan**](#archiveplan) | **POST** /api/subscriptions/plans/{productId}/archive | |
7
8
  |[**createPlan**](#createplan) | **POST** /api/subscriptions/plans | |
8
9
  |[**deletePlan**](#deleteplan) | **DELETE** /api/subscriptions/plans/{productId} | |
9
10
  |[**updatePlan**](#updateplan) | **PUT** /api/subscriptions/plans | |
10
11
 
12
+ # **archivePlan**
13
+ > DeleteSubscriptionPlanResponse archivePlan()
14
+
15
+ Supprime (archive) un plan par productId (manager)
16
+
17
+ ### Example
18
+
19
+ ```typescript
20
+ import {
21
+ SubscriptionsManagerApi,
22
+ Configuration
23
+ } from '@tennac-booking/sdk';
24
+
25
+ const configuration = new Configuration();
26
+ const apiInstance = new SubscriptionsManagerApi(configuration);
27
+
28
+ let productId: string; // (default to undefined)
29
+
30
+ const { status, data } = await apiInstance.archivePlan(
31
+ productId
32
+ );
33
+ ```
34
+
35
+ ### Parameters
36
+
37
+ |Name | Type | Description | Notes|
38
+ |------------- | ------------- | ------------- | -------------|
39
+ | **productId** | [**string**] | | defaults to undefined|
40
+
41
+
42
+ ### Return type
43
+
44
+ **DeleteSubscriptionPlanResponse**
45
+
46
+ ### Authorization
47
+
48
+ [bearerAuth](../README.md#bearerAuth)
49
+
50
+ ### HTTP request headers
51
+
52
+ - **Content-Type**: Not defined
53
+ - **Accept**: application/json
54
+
55
+
56
+ ### HTTP response details
57
+ | Status code | Description | Response headers |
58
+ |-------------|-------------|------------------|
59
+ |**200** | Plan archivé | - |
60
+ |**400** | Bad Request | - |
61
+ |**401** | Unauthorized | - |
62
+
63
+ [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
64
+
11
65
  # **createPlan**
12
66
  > CreatePlan201Response createPlan(createSubscriptionPlanRequest)
13
67
 
@@ -65,7 +119,7 @@ const { status, data } = await apiInstance.createPlan(
65
119
  # **deletePlan**
66
120
  > DeleteSubscriptionPlanResponse deletePlan()
67
121
 
68
- Supprime (archive) un plan par productId (manager)
122
+ Supprime un plan par productId (manager)
69
123
 
70
124
  ### Example
71
125
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tennac-booking/sdk",
3
- "version": "1.0.122",
3
+ "version": "1.0.123",
4
4
  "description": "OpenAPI client for @tennac-booking/sdk",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "repository": {