@tennac-booking/sdk 1.0.181 → 1.0.182

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/esm/api.js CHANGED
@@ -252,6 +252,26 @@ export const PaymentMethod = {
252
252
  OnsiteCash: 'onsite_cash',
253
253
  Free: 'free'
254
254
  };
255
+ /**
256
+ *
257
+ * @export
258
+ * @enum {string}
259
+ */
260
+ export const PaymentProviderType = {
261
+ Stripe: 'stripe',
262
+ Sumup: 'sumup'
263
+ };
264
+ /**
265
+ *
266
+ * @export
267
+ * @enum {string}
268
+ */
269
+ export const PaymentStatus = {
270
+ Pending: 'pending',
271
+ Succeeded: 'succeeded',
272
+ Failed: 'failed',
273
+ Cancelled: 'cancelled'
274
+ };
255
275
  /**
256
276
  *
257
277
  * @export
@@ -11332,6 +11352,185 @@ export class ImagesApi extends BaseAPI {
11332
11352
  return ImagesApiFp(this.configuration).cleanupImages(requestParameters.imageCleanupRequestBody, options).then((request) => request(this.axios, this.basePath));
11333
11353
  }
11334
11354
  }
11355
+ /**
11356
+ * PaymentsStaffApi - axios parameter creator
11357
+ * @export
11358
+ */
11359
+ export const PaymentsStaffApiAxiosParamCreator = function (configuration) {
11360
+ return {
11361
+ /**
11362
+ * Cancel a SumUp reader checkout.
11363
+ * @param {string} clubId
11364
+ * @param {string} paymentId
11365
+ * @param {SumupCancelPaymentRequest} [sumupCancelPaymentRequest]
11366
+ * @param {*} [options] Override http request option.
11367
+ * @throws {RequiredError}
11368
+ */
11369
+ cancelSumupPayment: (clubId_1, paymentId_1, sumupCancelPaymentRequest_1, ...args_1) => __awaiter(this, [clubId_1, paymentId_1, sumupCancelPaymentRequest_1, ...args_1], void 0, function* (clubId, paymentId, sumupCancelPaymentRequest, options = {}) {
11370
+ // verify required parameter 'clubId' is not null or undefined
11371
+ assertParamExists('cancelSumupPayment', 'clubId', clubId);
11372
+ // verify required parameter 'paymentId' is not null or undefined
11373
+ assertParamExists('cancelSumupPayment', 'paymentId', paymentId);
11374
+ const localVarPath = `/api/clubs/{clubId}/payments/sumup/{paymentId}/cancel`
11375
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)))
11376
+ .replace(`{${"paymentId"}}`, encodeURIComponent(String(paymentId)));
11377
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
11378
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
11379
+ let baseOptions;
11380
+ if (configuration) {
11381
+ baseOptions = configuration.baseOptions;
11382
+ }
11383
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
11384
+ const localVarHeaderParameter = {};
11385
+ const localVarQueryParameter = {};
11386
+ // authentication bearerAuth required
11387
+ // http bearer authentication required
11388
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
11389
+ localVarHeaderParameter['Content-Type'] = 'application/json';
11390
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
11391
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
11392
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
11393
+ localVarRequestOptions.data = serializeDataIfNeeded(sumupCancelPaymentRequest, localVarRequestOptions, configuration);
11394
+ return {
11395
+ url: toPathString(localVarUrlObj),
11396
+ options: localVarRequestOptions,
11397
+ };
11398
+ }),
11399
+ /**
11400
+ * Start a SumUp reader checkout (manual payment trigger).
11401
+ * @param {string} clubId
11402
+ * @param {SumupCreatePaymentRequest} sumupCreatePaymentRequest
11403
+ * @param {*} [options] Override http request option.
11404
+ * @throws {RequiredError}
11405
+ */
11406
+ createSumupPayment: (clubId_1, sumupCreatePaymentRequest_1, ...args_1) => __awaiter(this, [clubId_1, sumupCreatePaymentRequest_1, ...args_1], void 0, function* (clubId, sumupCreatePaymentRequest, options = {}) {
11407
+ // verify required parameter 'clubId' is not null or undefined
11408
+ assertParamExists('createSumupPayment', 'clubId', clubId);
11409
+ // verify required parameter 'sumupCreatePaymentRequest' is not null or undefined
11410
+ assertParamExists('createSumupPayment', 'sumupCreatePaymentRequest', sumupCreatePaymentRequest);
11411
+ const localVarPath = `/api/clubs/{clubId}/payments/sumup`
11412
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)));
11413
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
11414
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
11415
+ let baseOptions;
11416
+ if (configuration) {
11417
+ baseOptions = configuration.baseOptions;
11418
+ }
11419
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
11420
+ const localVarHeaderParameter = {};
11421
+ const localVarQueryParameter = {};
11422
+ // authentication bearerAuth required
11423
+ // http bearer authentication required
11424
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
11425
+ localVarHeaderParameter['Content-Type'] = 'application/json';
11426
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
11427
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
11428
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
11429
+ localVarRequestOptions.data = serializeDataIfNeeded(sumupCreatePaymentRequest, localVarRequestOptions, configuration);
11430
+ return {
11431
+ url: toPathString(localVarUrlObj),
11432
+ options: localVarRequestOptions,
11433
+ };
11434
+ }),
11435
+ };
11436
+ };
11437
+ /**
11438
+ * PaymentsStaffApi - functional programming interface
11439
+ * @export
11440
+ */
11441
+ export const PaymentsStaffApiFp = function (configuration) {
11442
+ const localVarAxiosParamCreator = PaymentsStaffApiAxiosParamCreator(configuration);
11443
+ return {
11444
+ /**
11445
+ * Cancel a SumUp reader checkout.
11446
+ * @param {string} clubId
11447
+ * @param {string} paymentId
11448
+ * @param {SumupCancelPaymentRequest} [sumupCancelPaymentRequest]
11449
+ * @param {*} [options] Override http request option.
11450
+ * @throws {RequiredError}
11451
+ */
11452
+ cancelSumupPayment(clubId, paymentId, sumupCancelPaymentRequest, options) {
11453
+ return __awaiter(this, void 0, void 0, function* () {
11454
+ var _a, _b, _c;
11455
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.cancelSumupPayment(clubId, paymentId, sumupCancelPaymentRequest, options);
11456
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
11457
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['PaymentsStaffApi.cancelSumupPayment']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
11458
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
11459
+ });
11460
+ },
11461
+ /**
11462
+ * Start a SumUp reader checkout (manual payment trigger).
11463
+ * @param {string} clubId
11464
+ * @param {SumupCreatePaymentRequest} sumupCreatePaymentRequest
11465
+ * @param {*} [options] Override http request option.
11466
+ * @throws {RequiredError}
11467
+ */
11468
+ createSumupPayment(clubId, sumupCreatePaymentRequest, options) {
11469
+ return __awaiter(this, void 0, void 0, function* () {
11470
+ var _a, _b, _c;
11471
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.createSumupPayment(clubId, sumupCreatePaymentRequest, options);
11472
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
11473
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['PaymentsStaffApi.createSumupPayment']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
11474
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
11475
+ });
11476
+ },
11477
+ };
11478
+ };
11479
+ /**
11480
+ * PaymentsStaffApi - factory interface
11481
+ * @export
11482
+ */
11483
+ export const PaymentsStaffApiFactory = function (configuration, basePath, axios) {
11484
+ const localVarFp = PaymentsStaffApiFp(configuration);
11485
+ return {
11486
+ /**
11487
+ * Cancel a SumUp reader checkout.
11488
+ * @param {PaymentsStaffApiCancelSumupPaymentRequest} requestParameters Request parameters.
11489
+ * @param {*} [options] Override http request option.
11490
+ * @throws {RequiredError}
11491
+ */
11492
+ cancelSumupPayment(requestParameters, options) {
11493
+ return localVarFp.cancelSumupPayment(requestParameters.clubId, requestParameters.paymentId, requestParameters.sumupCancelPaymentRequest, options).then((request) => request(axios, basePath));
11494
+ },
11495
+ /**
11496
+ * Start a SumUp reader checkout (manual payment trigger).
11497
+ * @param {PaymentsStaffApiCreateSumupPaymentRequest} requestParameters Request parameters.
11498
+ * @param {*} [options] Override http request option.
11499
+ * @throws {RequiredError}
11500
+ */
11501
+ createSumupPayment(requestParameters, options) {
11502
+ return localVarFp.createSumupPayment(requestParameters.clubId, requestParameters.sumupCreatePaymentRequest, options).then((request) => request(axios, basePath));
11503
+ },
11504
+ };
11505
+ };
11506
+ /**
11507
+ * PaymentsStaffApi - object-oriented interface
11508
+ * @export
11509
+ * @class PaymentsStaffApi
11510
+ * @extends {BaseAPI}
11511
+ */
11512
+ export class PaymentsStaffApi extends BaseAPI {
11513
+ /**
11514
+ * Cancel a SumUp reader checkout.
11515
+ * @param {PaymentsStaffApiCancelSumupPaymentRequest} requestParameters Request parameters.
11516
+ * @param {*} [options] Override http request option.
11517
+ * @throws {RequiredError}
11518
+ * @memberof PaymentsStaffApi
11519
+ */
11520
+ cancelSumupPayment(requestParameters, options) {
11521
+ return PaymentsStaffApiFp(this.configuration).cancelSumupPayment(requestParameters.clubId, requestParameters.paymentId, requestParameters.sumupCancelPaymentRequest, options).then((request) => request(this.axios, this.basePath));
11522
+ }
11523
+ /**
11524
+ * Start a SumUp reader checkout (manual payment trigger).
11525
+ * @param {PaymentsStaffApiCreateSumupPaymentRequest} requestParameters Request parameters.
11526
+ * @param {*} [options] Override http request option.
11527
+ * @throws {RequiredError}
11528
+ * @memberof PaymentsStaffApi
11529
+ */
11530
+ createSumupPayment(requestParameters, options) {
11531
+ return PaymentsStaffApiFp(this.configuration).createSumupPayment(requestParameters.clubId, requestParameters.sumupCreatePaymentRequest, options).then((request) => request(this.axios, this.basePath));
11532
+ }
11533
+ }
11335
11534
  /**
11336
11535
  * PublicEmailApi - axios parameter creator
11337
11536
  * @export
@@ -12728,6 +12927,475 @@ export class SubscriptionsUserApi extends BaseAPI {
12728
12927
  return SubscriptionsUserApiFp(this.configuration).subscribe(requestParameters.subscribeRequestBody, options).then((request) => request(this.axios, this.basePath));
12729
12928
  }
12730
12929
  }
12930
+ /**
12931
+ * SumUpApi - axios parameter creator
12932
+ * @export
12933
+ */
12934
+ export const SumUpApiAxiosParamCreator = function (configuration) {
12935
+ return {
12936
+ /**
12937
+ * OAuth callback for SumUp.
12938
+ * @param {string} code
12939
+ * @param {string} state
12940
+ * @param {*} [options] Override http request option.
12941
+ * @throws {RequiredError}
12942
+ */
12943
+ sumupOauthCallback: (code_1, state_1, ...args_1) => __awaiter(this, [code_1, state_1, ...args_1], void 0, function* (code, state, options = {}) {
12944
+ // verify required parameter 'code' is not null or undefined
12945
+ assertParamExists('sumupOauthCallback', 'code', code);
12946
+ // verify required parameter 'state' is not null or undefined
12947
+ assertParamExists('sumupOauthCallback', 'state', state);
12948
+ const localVarPath = `/api/sumup/oauth/callback`;
12949
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
12950
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
12951
+ let baseOptions;
12952
+ if (configuration) {
12953
+ baseOptions = configuration.baseOptions;
12954
+ }
12955
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
12956
+ const localVarHeaderParameter = {};
12957
+ const localVarQueryParameter = {};
12958
+ if (code !== undefined) {
12959
+ localVarQueryParameter['code'] = code;
12960
+ }
12961
+ if (state !== undefined) {
12962
+ localVarQueryParameter['state'] = state;
12963
+ }
12964
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
12965
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
12966
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
12967
+ return {
12968
+ url: toPathString(localVarUrlObj),
12969
+ options: localVarRequestOptions,
12970
+ };
12971
+ }),
12972
+ };
12973
+ };
12974
+ /**
12975
+ * SumUpApi - functional programming interface
12976
+ * @export
12977
+ */
12978
+ export const SumUpApiFp = function (configuration) {
12979
+ const localVarAxiosParamCreator = SumUpApiAxiosParamCreator(configuration);
12980
+ return {
12981
+ /**
12982
+ * OAuth callback for SumUp.
12983
+ * @param {string} code
12984
+ * @param {string} state
12985
+ * @param {*} [options] Override http request option.
12986
+ * @throws {RequiredError}
12987
+ */
12988
+ sumupOauthCallback(code, state, options) {
12989
+ return __awaiter(this, void 0, void 0, function* () {
12990
+ var _a, _b, _c;
12991
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.sumupOauthCallback(code, state, options);
12992
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
12993
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SumUpApi.sumupOauthCallback']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
12994
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
12995
+ });
12996
+ },
12997
+ };
12998
+ };
12999
+ /**
13000
+ * SumUpApi - factory interface
13001
+ * @export
13002
+ */
13003
+ export const SumUpApiFactory = function (configuration, basePath, axios) {
13004
+ const localVarFp = SumUpApiFp(configuration);
13005
+ return {
13006
+ /**
13007
+ * OAuth callback for SumUp.
13008
+ * @param {SumUpApiSumupOauthCallbackRequest} requestParameters Request parameters.
13009
+ * @param {*} [options] Override http request option.
13010
+ * @throws {RequiredError}
13011
+ */
13012
+ sumupOauthCallback(requestParameters, options) {
13013
+ return localVarFp.sumupOauthCallback(requestParameters.code, requestParameters.state, options).then((request) => request(axios, basePath));
13014
+ },
13015
+ };
13016
+ };
13017
+ /**
13018
+ * SumUpApi - object-oriented interface
13019
+ * @export
13020
+ * @class SumUpApi
13021
+ * @extends {BaseAPI}
13022
+ */
13023
+ export class SumUpApi extends BaseAPI {
13024
+ /**
13025
+ * OAuth callback for SumUp.
13026
+ * @param {SumUpApiSumupOauthCallbackRequest} requestParameters Request parameters.
13027
+ * @param {*} [options] Override http request option.
13028
+ * @throws {RequiredError}
13029
+ * @memberof SumUpApi
13030
+ */
13031
+ sumupOauthCallback(requestParameters, options) {
13032
+ return SumUpApiFp(this.configuration).sumupOauthCallback(requestParameters.code, requestParameters.state, options).then((request) => request(this.axios, this.basePath));
13033
+ }
13034
+ }
13035
+ /**
13036
+ * SumUpManagerApi - axios parameter creator
13037
+ * @export
13038
+ */
13039
+ export const SumUpManagerApiAxiosParamCreator = function (configuration) {
13040
+ return {
13041
+ /**
13042
+ * Disconnect SumUp account for a club.
13043
+ * @param {string} clubId
13044
+ * @param {*} [options] Override http request option.
13045
+ * @throws {RequiredError}
13046
+ */
13047
+ disconnectSumup: (clubId_1, ...args_1) => __awaiter(this, [clubId_1, ...args_1], void 0, function* (clubId, options = {}) {
13048
+ // verify required parameter 'clubId' is not null or undefined
13049
+ assertParamExists('disconnectSumup', 'clubId', clubId);
13050
+ const localVarPath = `/api/clubs/{clubId}/sumup/disconnect`
13051
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)));
13052
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13053
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13054
+ let baseOptions;
13055
+ if (configuration) {
13056
+ baseOptions = configuration.baseOptions;
13057
+ }
13058
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
13059
+ const localVarHeaderParameter = {};
13060
+ const localVarQueryParameter = {};
13061
+ // authentication bearerAuth required
13062
+ // http bearer authentication required
13063
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13064
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
13065
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
13066
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
13067
+ return {
13068
+ url: toPathString(localVarUrlObj),
13069
+ options: localVarRequestOptions,
13070
+ };
13071
+ }),
13072
+ /**
13073
+ * Start SumUp OAuth connection for a club.
13074
+ * @param {string} clubId
13075
+ * @param {*} [options] Override http request option.
13076
+ * @throws {RequiredError}
13077
+ */
13078
+ getSumupConnectUrl: (clubId_1, ...args_1) => __awaiter(this, [clubId_1, ...args_1], void 0, function* (clubId, options = {}) {
13079
+ // verify required parameter 'clubId' is not null or undefined
13080
+ assertParamExists('getSumupConnectUrl', 'clubId', clubId);
13081
+ const localVarPath = `/api/clubs/{clubId}/sumup/connect`
13082
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)));
13083
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13084
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13085
+ let baseOptions;
13086
+ if (configuration) {
13087
+ baseOptions = configuration.baseOptions;
13088
+ }
13089
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
13090
+ const localVarHeaderParameter = {};
13091
+ const localVarQueryParameter = {};
13092
+ // authentication bearerAuth required
13093
+ // http bearer authentication required
13094
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13095
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
13096
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
13097
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
13098
+ return {
13099
+ url: toPathString(localVarUrlObj),
13100
+ options: localVarRequestOptions,
13101
+ };
13102
+ }),
13103
+ /**
13104
+ * Get SumUp connection status for a club.
13105
+ * @param {string} clubId
13106
+ * @param {*} [options] Override http request option.
13107
+ * @throws {RequiredError}
13108
+ */
13109
+ getSumupStatus: (clubId_1, ...args_1) => __awaiter(this, [clubId_1, ...args_1], void 0, function* (clubId, options = {}) {
13110
+ // verify required parameter 'clubId' is not null or undefined
13111
+ assertParamExists('getSumupStatus', 'clubId', clubId);
13112
+ const localVarPath = `/api/clubs/{clubId}/sumup/status`
13113
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)));
13114
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13115
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13116
+ let baseOptions;
13117
+ if (configuration) {
13118
+ baseOptions = configuration.baseOptions;
13119
+ }
13120
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
13121
+ const localVarHeaderParameter = {};
13122
+ const localVarQueryParameter = {};
13123
+ // authentication bearerAuth required
13124
+ // http bearer authentication required
13125
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13126
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
13127
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
13128
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
13129
+ return {
13130
+ url: toPathString(localVarUrlObj),
13131
+ options: localVarRequestOptions,
13132
+ };
13133
+ }),
13134
+ /**
13135
+ * List SumUp readers for a club.
13136
+ * @param {string} clubId
13137
+ * @param {*} [options] Override http request option.
13138
+ * @throws {RequiredError}
13139
+ */
13140
+ listSumupReaders: (clubId_1, ...args_1) => __awaiter(this, [clubId_1, ...args_1], void 0, function* (clubId, options = {}) {
13141
+ // verify required parameter 'clubId' is not null or undefined
13142
+ assertParamExists('listSumupReaders', 'clubId', clubId);
13143
+ const localVarPath = `/api/clubs/{clubId}/sumup/readers`
13144
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)));
13145
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13146
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13147
+ let baseOptions;
13148
+ if (configuration) {
13149
+ baseOptions = configuration.baseOptions;
13150
+ }
13151
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
13152
+ const localVarHeaderParameter = {};
13153
+ const localVarQueryParameter = {};
13154
+ // authentication bearerAuth required
13155
+ // http bearer authentication required
13156
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13157
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
13158
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
13159
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
13160
+ return {
13161
+ url: toPathString(localVarUrlObj),
13162
+ options: localVarRequestOptions,
13163
+ };
13164
+ }),
13165
+ /**
13166
+ * Select a SumUp reader for a club.
13167
+ * @param {string} clubId
13168
+ * @param {string} readerId
13169
+ * @param {*} [options] Override http request option.
13170
+ * @throws {RequiredError}
13171
+ */
13172
+ selectSumupReader: (clubId_1, readerId_1, ...args_1) => __awaiter(this, [clubId_1, readerId_1, ...args_1], void 0, function* (clubId, readerId, options = {}) {
13173
+ // verify required parameter 'clubId' is not null or undefined
13174
+ assertParamExists('selectSumupReader', 'clubId', clubId);
13175
+ // verify required parameter 'readerId' is not null or undefined
13176
+ assertParamExists('selectSumupReader', 'readerId', readerId);
13177
+ const localVarPath = `/api/clubs/{clubId}/sumup/readers/{readerId}/select`
13178
+ .replace(`{${"clubId"}}`, encodeURIComponent(String(clubId)))
13179
+ .replace(`{${"readerId"}}`, encodeURIComponent(String(readerId)));
13180
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
13181
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
13182
+ let baseOptions;
13183
+ if (configuration) {
13184
+ baseOptions = configuration.baseOptions;
13185
+ }
13186
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
13187
+ const localVarHeaderParameter = {};
13188
+ const localVarQueryParameter = {};
13189
+ // authentication bearerAuth required
13190
+ // http bearer authentication required
13191
+ yield setBearerAuthToObject(localVarHeaderParameter, configuration);
13192
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
13193
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
13194
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
13195
+ return {
13196
+ url: toPathString(localVarUrlObj),
13197
+ options: localVarRequestOptions,
13198
+ };
13199
+ }),
13200
+ };
13201
+ };
13202
+ /**
13203
+ * SumUpManagerApi - functional programming interface
13204
+ * @export
13205
+ */
13206
+ export const SumUpManagerApiFp = function (configuration) {
13207
+ const localVarAxiosParamCreator = SumUpManagerApiAxiosParamCreator(configuration);
13208
+ return {
13209
+ /**
13210
+ * Disconnect SumUp account for a club.
13211
+ * @param {string} clubId
13212
+ * @param {*} [options] Override http request option.
13213
+ * @throws {RequiredError}
13214
+ */
13215
+ disconnectSumup(clubId, options) {
13216
+ return __awaiter(this, void 0, void 0, function* () {
13217
+ var _a, _b, _c;
13218
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.disconnectSumup(clubId, options);
13219
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
13220
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SumUpManagerApi.disconnectSumup']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
13221
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
13222
+ });
13223
+ },
13224
+ /**
13225
+ * Start SumUp OAuth connection for a club.
13226
+ * @param {string} clubId
13227
+ * @param {*} [options] Override http request option.
13228
+ * @throws {RequiredError}
13229
+ */
13230
+ getSumupConnectUrl(clubId, options) {
13231
+ return __awaiter(this, void 0, void 0, function* () {
13232
+ var _a, _b, _c;
13233
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getSumupConnectUrl(clubId, options);
13234
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
13235
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SumUpManagerApi.getSumupConnectUrl']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
13236
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
13237
+ });
13238
+ },
13239
+ /**
13240
+ * Get SumUp connection status for a club.
13241
+ * @param {string} clubId
13242
+ * @param {*} [options] Override http request option.
13243
+ * @throws {RequiredError}
13244
+ */
13245
+ getSumupStatus(clubId, options) {
13246
+ return __awaiter(this, void 0, void 0, function* () {
13247
+ var _a, _b, _c;
13248
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getSumupStatus(clubId, options);
13249
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
13250
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SumUpManagerApi.getSumupStatus']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
13251
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
13252
+ });
13253
+ },
13254
+ /**
13255
+ * List SumUp readers for a club.
13256
+ * @param {string} clubId
13257
+ * @param {*} [options] Override http request option.
13258
+ * @throws {RequiredError}
13259
+ */
13260
+ listSumupReaders(clubId, options) {
13261
+ return __awaiter(this, void 0, void 0, function* () {
13262
+ var _a, _b, _c;
13263
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.listSumupReaders(clubId, options);
13264
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
13265
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SumUpManagerApi.listSumupReaders']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
13266
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
13267
+ });
13268
+ },
13269
+ /**
13270
+ * Select a SumUp reader for a club.
13271
+ * @param {string} clubId
13272
+ * @param {string} readerId
13273
+ * @param {*} [options] Override http request option.
13274
+ * @throws {RequiredError}
13275
+ */
13276
+ selectSumupReader(clubId, readerId, options) {
13277
+ return __awaiter(this, void 0, void 0, function* () {
13278
+ var _a, _b, _c;
13279
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.selectSumupReader(clubId, readerId, options);
13280
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
13281
+ const localVarOperationServerBasePath = (_c = (_b = operationServerMap['SumUpManagerApi.selectSumupReader']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
13282
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
13283
+ });
13284
+ },
13285
+ };
13286
+ };
13287
+ /**
13288
+ * SumUpManagerApi - factory interface
13289
+ * @export
13290
+ */
13291
+ export const SumUpManagerApiFactory = function (configuration, basePath, axios) {
13292
+ const localVarFp = SumUpManagerApiFp(configuration);
13293
+ return {
13294
+ /**
13295
+ * Disconnect SumUp account for a club.
13296
+ * @param {SumUpManagerApiDisconnectSumupRequest} requestParameters Request parameters.
13297
+ * @param {*} [options] Override http request option.
13298
+ * @throws {RequiredError}
13299
+ */
13300
+ disconnectSumup(requestParameters, options) {
13301
+ return localVarFp.disconnectSumup(requestParameters.clubId, options).then((request) => request(axios, basePath));
13302
+ },
13303
+ /**
13304
+ * Start SumUp OAuth connection for a club.
13305
+ * @param {SumUpManagerApiGetSumupConnectUrlRequest} requestParameters Request parameters.
13306
+ * @param {*} [options] Override http request option.
13307
+ * @throws {RequiredError}
13308
+ */
13309
+ getSumupConnectUrl(requestParameters, options) {
13310
+ return localVarFp.getSumupConnectUrl(requestParameters.clubId, options).then((request) => request(axios, basePath));
13311
+ },
13312
+ /**
13313
+ * Get SumUp connection status for a club.
13314
+ * @param {SumUpManagerApiGetSumupStatusRequest} requestParameters Request parameters.
13315
+ * @param {*} [options] Override http request option.
13316
+ * @throws {RequiredError}
13317
+ */
13318
+ getSumupStatus(requestParameters, options) {
13319
+ return localVarFp.getSumupStatus(requestParameters.clubId, options).then((request) => request(axios, basePath));
13320
+ },
13321
+ /**
13322
+ * List SumUp readers for a club.
13323
+ * @param {SumUpManagerApiListSumupReadersRequest} requestParameters Request parameters.
13324
+ * @param {*} [options] Override http request option.
13325
+ * @throws {RequiredError}
13326
+ */
13327
+ listSumupReaders(requestParameters, options) {
13328
+ return localVarFp.listSumupReaders(requestParameters.clubId, options).then((request) => request(axios, basePath));
13329
+ },
13330
+ /**
13331
+ * Select a SumUp reader for a club.
13332
+ * @param {SumUpManagerApiSelectSumupReaderRequest} requestParameters Request parameters.
13333
+ * @param {*} [options] Override http request option.
13334
+ * @throws {RequiredError}
13335
+ */
13336
+ selectSumupReader(requestParameters, options) {
13337
+ return localVarFp.selectSumupReader(requestParameters.clubId, requestParameters.readerId, options).then((request) => request(axios, basePath));
13338
+ },
13339
+ };
13340
+ };
13341
+ /**
13342
+ * SumUpManagerApi - object-oriented interface
13343
+ * @export
13344
+ * @class SumUpManagerApi
13345
+ * @extends {BaseAPI}
13346
+ */
13347
+ export class SumUpManagerApi extends BaseAPI {
13348
+ /**
13349
+ * Disconnect SumUp account for a club.
13350
+ * @param {SumUpManagerApiDisconnectSumupRequest} requestParameters Request parameters.
13351
+ * @param {*} [options] Override http request option.
13352
+ * @throws {RequiredError}
13353
+ * @memberof SumUpManagerApi
13354
+ */
13355
+ disconnectSumup(requestParameters, options) {
13356
+ return SumUpManagerApiFp(this.configuration).disconnectSumup(requestParameters.clubId, options).then((request) => request(this.axios, this.basePath));
13357
+ }
13358
+ /**
13359
+ * Start SumUp OAuth connection for a club.
13360
+ * @param {SumUpManagerApiGetSumupConnectUrlRequest} requestParameters Request parameters.
13361
+ * @param {*} [options] Override http request option.
13362
+ * @throws {RequiredError}
13363
+ * @memberof SumUpManagerApi
13364
+ */
13365
+ getSumupConnectUrl(requestParameters, options) {
13366
+ return SumUpManagerApiFp(this.configuration).getSumupConnectUrl(requestParameters.clubId, options).then((request) => request(this.axios, this.basePath));
13367
+ }
13368
+ /**
13369
+ * Get SumUp connection status for a club.
13370
+ * @param {SumUpManagerApiGetSumupStatusRequest} requestParameters Request parameters.
13371
+ * @param {*} [options] Override http request option.
13372
+ * @throws {RequiredError}
13373
+ * @memberof SumUpManagerApi
13374
+ */
13375
+ getSumupStatus(requestParameters, options) {
13376
+ return SumUpManagerApiFp(this.configuration).getSumupStatus(requestParameters.clubId, options).then((request) => request(this.axios, this.basePath));
13377
+ }
13378
+ /**
13379
+ * List SumUp readers for a club.
13380
+ * @param {SumUpManagerApiListSumupReadersRequest} requestParameters Request parameters.
13381
+ * @param {*} [options] Override http request option.
13382
+ * @throws {RequiredError}
13383
+ * @memberof SumUpManagerApi
13384
+ */
13385
+ listSumupReaders(requestParameters, options) {
13386
+ return SumUpManagerApiFp(this.configuration).listSumupReaders(requestParameters.clubId, options).then((request) => request(this.axios, this.basePath));
13387
+ }
13388
+ /**
13389
+ * Select a SumUp reader for a club.
13390
+ * @param {SumUpManagerApiSelectSumupReaderRequest} requestParameters Request parameters.
13391
+ * @param {*} [options] Override http request option.
13392
+ * @throws {RequiredError}
13393
+ * @memberof SumUpManagerApi
13394
+ */
13395
+ selectSumupReader(requestParameters, options) {
13396
+ return SumUpManagerApiFp(this.configuration).selectSumupReader(requestParameters.clubId, requestParameters.readerId, options).then((request) => request(this.axios, this.basePath));
13397
+ }
13398
+ }
12731
13399
  /**
12732
13400
  * UserApi - axios parameter creator
12733
13401
  * @export