ch-api-client-typescript2 5.15.0 → 5.16.3

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.
Files changed (106) hide show
  1. package/lib/api/doctor-affiliations-api.d.ts +3 -12
  2. package/lib/api/doctor-affiliations-api.d.ts.map +1 -1
  3. package/lib/api/doctor-affiliations-api.js +6 -12
  4. package/lib/api.d.ts +0 -3
  5. package/lib/api.d.ts.map +1 -1
  6. package/lib/api.js +0 -3
  7. package/lib/models/index.d.ts +0 -20
  8. package/lib/models/index.d.ts.map +1 -1
  9. package/lib/models/index.js +0 -20
  10. package/package.json +1 -1
  11. package/src/.openapi-generator/FILES +0 -23
  12. package/src/api/doctor-affiliations-api.ts +6 -20
  13. package/src/api.ts +0 -3
  14. package/src/models/index.ts +0 -20
  15. package/lib/api/bookings-api.d.ts +0 -439
  16. package/lib/api/bookings-api.d.ts.map +0 -1
  17. package/lib/api/bookings-api.js +0 -665
  18. package/lib/api/consultations-api.d.ts +0 -421
  19. package/lib/api/consultations-api.d.ts.map +0 -1
  20. package/lib/api/consultations-api.js +0 -653
  21. package/lib/api/hospitals-consultation-timetables-api.d.ts +0 -124
  22. package/lib/api/hospitals-consultation-timetables-api.d.ts.map +0 -1
  23. package/lib/api/hospitals-consultation-timetables-api.js +0 -240
  24. package/lib/models/booking-change-log-model.d.ts +0 -44
  25. package/lib/models/booking-change-log-model.d.ts.map +0 -1
  26. package/lib/models/booking-change-log-model.js +0 -15
  27. package/lib/models/booking-item-model.d.ts +0 -233
  28. package/lib/models/booking-item-model.d.ts.map +0 -1
  29. package/lib/models/booking-item-model.js +0 -15
  30. package/lib/models/booking-model.d.ts +0 -240
  31. package/lib/models/booking-model.d.ts.map +0 -1
  32. package/lib/models/booking-model.js +0 -15
  33. package/lib/models/booking-status.d.ts +0 -27
  34. package/lib/models/booking-status.d.ts.map +0 -1
  35. package/lib/models/booking-status.js +0 -30
  36. package/lib/models/bookings-model.d.ts +0 -33
  37. package/lib/models/bookings-model.d.ts.map +0 -1
  38. package/lib/models/bookings-model.js +0 -15
  39. package/lib/models/consultation-change-log-model.d.ts +0 -44
  40. package/lib/models/consultation-change-log-model.d.ts.map +0 -1
  41. package/lib/models/consultation-change-log-model.js +0 -15
  42. package/lib/models/consultation-item-model.d.ts +0 -275
  43. package/lib/models/consultation-item-model.d.ts.map +0 -1
  44. package/lib/models/consultation-item-model.js +0 -15
  45. package/lib/models/consultation-model.d.ts +0 -282
  46. package/lib/models/consultation-model.d.ts.map +0 -1
  47. package/lib/models/consultation-model.js +0 -15
  48. package/lib/models/consultation-status.d.ts +0 -27
  49. package/lib/models/consultation-status.d.ts.map +0 -1
  50. package/lib/models/consultation-status.js +0 -30
  51. package/lib/models/consultation-timetable-date-model.d.ts +0 -58
  52. package/lib/models/consultation-timetable-date-model.d.ts.map +0 -1
  53. package/lib/models/consultation-timetable-date-model.js +0 -15
  54. package/lib/models/consultation-timetable-model.d.ts +0 -44
  55. package/lib/models/consultation-timetable-model.d.ts.map +0 -1
  56. package/lib/models/consultation-timetable-model.js +0 -15
  57. package/lib/models/consultation-timetable-status.d.ts +0 -22
  58. package/lib/models/consultation-timetable-status.d.ts.map +0 -1
  59. package/lib/models/consultation-timetable-status.js +0 -25
  60. package/lib/models/consultation-timetable-time-slot-model.d.ts +0 -56
  61. package/lib/models/consultation-timetable-time-slot-model.d.ts.map +0 -1
  62. package/lib/models/consultation-timetable-time-slot-model.js +0 -15
  63. package/lib/models/consultation-type.d.ts +0 -23
  64. package/lib/models/consultation-type.d.ts.map +0 -1
  65. package/lib/models/consultation-type.js +0 -26
  66. package/lib/models/consultations-model.d.ts +0 -33
  67. package/lib/models/consultations-model.d.ts.map +0 -1
  68. package/lib/models/consultations-model.js +0 -15
  69. package/lib/models/create-booking-command.d.ts +0 -104
  70. package/lib/models/create-booking-command.d.ts.map +0 -1
  71. package/lib/models/create-booking-command.js +0 -15
  72. package/lib/models/create-consultation-command.d.ts +0 -135
  73. package/lib/models/create-consultation-command.d.ts.map +0 -1
  74. package/lib/models/create-consultation-command.js +0 -15
  75. package/lib/models/sorting-order.d.ts +0 -22
  76. package/lib/models/sorting-order.d.ts.map +0 -1
  77. package/lib/models/sorting-order.js +0 -25
  78. package/lib/models/update-booking-command.d.ts +0 -86
  79. package/lib/models/update-booking-command.d.ts.map +0 -1
  80. package/lib/models/update-booking-command.js +0 -15
  81. package/lib/models/update-consultation-command.d.ts +0 -110
  82. package/lib/models/update-consultation-command.d.ts.map +0 -1
  83. package/lib/models/update-consultation-command.js +0 -15
  84. package/src/api/bookings-api.ts +0 -748
  85. package/src/api/consultations-api.ts +0 -720
  86. package/src/api/hospitals-consultation-timetables-api.ts +0 -201
  87. package/src/models/booking-change-log-model.ts +0 -51
  88. package/src/models/booking-item-model.ts +0 -246
  89. package/src/models/booking-model.ts +0 -255
  90. package/src/models/booking-status.ts +0 -36
  91. package/src/models/bookings-model.ts +0 -42
  92. package/src/models/consultation-change-log-model.ts +0 -51
  93. package/src/models/consultation-item-model.ts +0 -288
  94. package/src/models/consultation-model.ts +0 -297
  95. package/src/models/consultation-status.ts +0 -36
  96. package/src/models/consultation-timetable-date-model.ts +0 -69
  97. package/src/models/consultation-timetable-model.ts +0 -51
  98. package/src/models/consultation-timetable-status.ts +0 -31
  99. package/src/models/consultation-timetable-time-slot-model.ts +0 -63
  100. package/src/models/consultation-type.ts +0 -32
  101. package/src/models/consultations-model.ts +0 -42
  102. package/src/models/create-booking-command.ts +0 -111
  103. package/src/models/create-consultation-command.ts +0 -144
  104. package/src/models/sorting-order.ts +0 -31
  105. package/src/models/update-booking-command.ts +0 -93
  106. package/src/models/update-consultation-command.ts +0 -117
@@ -1,665 +0,0 @@
1
- "use strict";
2
- /* tslint:disable */
3
- /* eslint-disable */
4
- /**
5
- * Swagger UI - Cloud Hospital Api-INT
6
- * Cloud Hospital application with Swagger, Swashbuckle, and API versioning.
7
- *
8
- * The version of the OpenAPI document: 2
9
- * Contact: hyounoosung@icloudhospital.com
10
- *
11
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
- * https://openapi-generator.tech
13
- * Do not edit the class manually.
14
- */
15
- var __extends = (this && this.__extends) || (function () {
16
- var extendStatics = function (d, b) {
17
- extendStatics = Object.setPrototypeOf ||
18
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
19
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
20
- return extendStatics(d, b);
21
- };
22
- return function (d, b) {
23
- if (typeof b !== "function" && b !== null)
24
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
25
- extendStatics(d, b);
26
- function __() { this.constructor = d; }
27
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
28
- };
29
- })();
30
- var __assign = (this && this.__assign) || function () {
31
- __assign = Object.assign || function(t) {
32
- for (var s, i = 1, n = arguments.length; i < n; i++) {
33
- s = arguments[i];
34
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
35
- t[p] = s[p];
36
- }
37
- return t;
38
- };
39
- return __assign.apply(this, arguments);
40
- };
41
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
42
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
43
- return new (P || (P = Promise))(function (resolve, reject) {
44
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
45
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
46
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
47
- step((generator = generator.apply(thisArg, _arguments || [])).next());
48
- });
49
- };
50
- var __generator = (this && this.__generator) || function (thisArg, body) {
51
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
52
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
53
- function verb(n) { return function (v) { return step([n, v]); }; }
54
- function step(op) {
55
- if (f) throw new TypeError("Generator is already executing.");
56
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
57
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
58
- if (y = 0, t) op = [op[0] & 2, t.value];
59
- switch (op[0]) {
60
- case 0: case 1: t = op; break;
61
- case 4: _.label++; return { value: op[1], done: false };
62
- case 5: _.label++; y = op[1]; op = [0]; continue;
63
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
64
- default:
65
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
66
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
67
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
68
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
69
- if (t[2]) _.ops.pop();
70
- _.trys.pop(); continue;
71
- }
72
- op = body.call(thisArg, _);
73
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
74
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
75
- }
76
- };
77
- var __importDefault = (this && this.__importDefault) || function (mod) {
78
- return (mod && mod.__esModule) ? mod : { "default": mod };
79
- };
80
- Object.defineProperty(exports, "__esModule", { value: true });
81
- exports.BookingsApi = exports.BookingsApiFactory = exports.BookingsApiFp = exports.BookingsApiAxiosParamCreator = void 0;
82
- var axios_1 = __importDefault(require("axios"));
83
- // Some imports not used depending on template conditions
84
- // @ts-ignore
85
- var common_1 = require("../common");
86
- // @ts-ignore
87
- var base_1 = require("../base");
88
- /**
89
- * BookingsApi - axios parameter creator
90
- * @export
91
- */
92
- var BookingsApiAxiosParamCreator = function (configuration) {
93
- var _this = this;
94
- return {
95
- /**
96
- *
97
- * @summary Get booking.
98
- * @param {string} bookingId
99
- * @param {string} [languageCode]
100
- * @param {*} [options] Override http request option.
101
- * @throws {RequiredError}
102
- */
103
- apiV2BookingsBookingIdGet: function (bookingId, languageCode, options) {
104
- if (options === void 0) { options = {}; }
105
- return __awaiter(_this, void 0, void 0, function () {
106
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
107
- return __generator(this, function (_a) {
108
- switch (_a.label) {
109
- case 0:
110
- // verify required parameter 'bookingId' is not null or undefined
111
- (0, common_1.assertParamExists)('apiV2BookingsBookingIdGet', 'bookingId', bookingId);
112
- localVarPath = "/api/v2/bookings/{bookingId}"
113
- .replace("{".concat("bookingId", "}"), encodeURIComponent(String(bookingId)));
114
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
115
- if (configuration) {
116
- baseOptions = configuration.baseOptions;
117
- }
118
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
119
- localVarHeaderParameter = {};
120
- localVarQueryParameter = {};
121
- // authentication oauth2 required
122
- // oauth required
123
- return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
124
- case 1:
125
- // authentication oauth2 required
126
- // oauth required
127
- _a.sent();
128
- if (languageCode !== undefined) {
129
- localVarQueryParameter['languageCode'] = languageCode;
130
- }
131
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
132
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
133
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
134
- return [2 /*return*/, {
135
- url: (0, common_1.toPathString)(localVarUrlObj),
136
- options: localVarRequestOptions,
137
- }];
138
- }
139
- });
140
- });
141
- },
142
- /**
143
- *
144
- * @summary Pay booking.
145
- * @param {string} bookingId
146
- * @param {*} [options] Override http request option.
147
- * @throws {RequiredError}
148
- */
149
- apiV2BookingsBookingIdPayPost: function (bookingId, options) {
150
- if (options === void 0) { options = {}; }
151
- return __awaiter(_this, void 0, void 0, function () {
152
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
153
- return __generator(this, function (_a) {
154
- switch (_a.label) {
155
- case 0:
156
- // verify required parameter 'bookingId' is not null or undefined
157
- (0, common_1.assertParamExists)('apiV2BookingsBookingIdPayPost', 'bookingId', bookingId);
158
- localVarPath = "/api/v2/bookings/{bookingId}/pay"
159
- .replace("{".concat("bookingId", "}"), encodeURIComponent(String(bookingId)));
160
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
161
- if (configuration) {
162
- baseOptions = configuration.baseOptions;
163
- }
164
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
165
- localVarHeaderParameter = {};
166
- localVarQueryParameter = {};
167
- // authentication oauth2 required
168
- // oauth required
169
- return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
170
- case 1:
171
- // authentication oauth2 required
172
- // oauth required
173
- _a.sent();
174
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
175
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
176
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
177
- return [2 /*return*/, {
178
- url: (0, common_1.toPathString)(localVarUrlObj),
179
- options: localVarRequestOptions,
180
- }];
181
- }
182
- });
183
- });
184
- },
185
- /**
186
- *
187
- * @summary Update booking.
188
- * @param {string} bookingId
189
- * @param {UpdateBookingCommand} [updateBookingCommand]
190
- * @param {*} [options] Override http request option.
191
- * @throws {RequiredError}
192
- */
193
- apiV2BookingsBookingIdPut: function (bookingId, updateBookingCommand, options) {
194
- if (options === void 0) { options = {}; }
195
- return __awaiter(_this, void 0, void 0, function () {
196
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
197
- return __generator(this, function (_a) {
198
- switch (_a.label) {
199
- case 0:
200
- // verify required parameter 'bookingId' is not null or undefined
201
- (0, common_1.assertParamExists)('apiV2BookingsBookingIdPut', 'bookingId', bookingId);
202
- localVarPath = "/api/v2/bookings/{bookingId}"
203
- .replace("{".concat("bookingId", "}"), encodeURIComponent(String(bookingId)));
204
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
205
- if (configuration) {
206
- baseOptions = configuration.baseOptions;
207
- }
208
- localVarRequestOptions = __assign(__assign({ method: 'PUT' }, baseOptions), options);
209
- localVarHeaderParameter = {};
210
- localVarQueryParameter = {};
211
- // authentication oauth2 required
212
- // oauth required
213
- return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
214
- case 1:
215
- // authentication oauth2 required
216
- // oauth required
217
- _a.sent();
218
- localVarHeaderParameter['Content-Type'] = 'application/json';
219
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
220
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
221
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
222
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(updateBookingCommand, localVarRequestOptions, configuration);
223
- return [2 /*return*/, {
224
- url: (0, common_1.toPathString)(localVarUrlObj),
225
- options: localVarRequestOptions,
226
- }];
227
- }
228
- });
229
- });
230
- },
231
- /**
232
- *
233
- * @summary Get all bookings.
234
- * @param {string} [hospitalId]
235
- * @param {string} [hospitalName]
236
- * @param {string} [dealId]
237
- * @param {string} [dealName]
238
- * @param {boolean} [isOpen]
239
- * @param {boolean} [isCompleted]
240
- * @param {BookingStatus} [status]
241
- * @param {string} [dealPackageId]
242
- * @param {SortingOrder} [sortRequestDate]
243
- * @param {SortingOrder} [sortConfirmedDateStart]
244
- * @param {boolean} [isExternal]
245
- * @param {boolean} [paymentEnabled]
246
- * @param {string} [languageCode]
247
- * @param {number} [page]
248
- * @param {number} [limit]
249
- * @param {Date} [lastRetrieved]
250
- * @param {*} [options] Override http request option.
251
- * @throws {RequiredError}
252
- */
253
- apiV2BookingsGet: function (hospitalId, hospitalName, dealId, dealName, isOpen, isCompleted, status, dealPackageId, sortRequestDate, sortConfirmedDateStart, isExternal, paymentEnabled, languageCode, page, limit, lastRetrieved, options) {
254
- if (options === void 0) { options = {}; }
255
- return __awaiter(_this, void 0, void 0, function () {
256
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
257
- return __generator(this, function (_a) {
258
- switch (_a.label) {
259
- case 0:
260
- localVarPath = "/api/v2/bookings";
261
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
262
- if (configuration) {
263
- baseOptions = configuration.baseOptions;
264
- }
265
- localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
266
- localVarHeaderParameter = {};
267
- localVarQueryParameter = {};
268
- // authentication oauth2 required
269
- // oauth required
270
- return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
271
- case 1:
272
- // authentication oauth2 required
273
- // oauth required
274
- _a.sent();
275
- if (hospitalId !== undefined) {
276
- localVarQueryParameter['HospitalId'] = hospitalId;
277
- }
278
- if (hospitalName !== undefined) {
279
- localVarQueryParameter['HospitalName'] = hospitalName;
280
- }
281
- if (dealId !== undefined) {
282
- localVarQueryParameter['DealId'] = dealId;
283
- }
284
- if (dealName !== undefined) {
285
- localVarQueryParameter['DealName'] = dealName;
286
- }
287
- if (isOpen !== undefined) {
288
- localVarQueryParameter['IsOpen'] = isOpen;
289
- }
290
- if (isCompleted !== undefined) {
291
- localVarQueryParameter['IsCompleted'] = isCompleted;
292
- }
293
- if (status !== undefined) {
294
- localVarQueryParameter['Status'] = status;
295
- }
296
- if (dealPackageId !== undefined) {
297
- localVarQueryParameter['DealPackageId'] = dealPackageId;
298
- }
299
- if (sortRequestDate !== undefined) {
300
- localVarQueryParameter['SortRequestDate'] = sortRequestDate;
301
- }
302
- if (sortConfirmedDateStart !== undefined) {
303
- localVarQueryParameter['SortConfirmedDateStart'] = sortConfirmedDateStart;
304
- }
305
- if (isExternal !== undefined) {
306
- localVarQueryParameter['IsExternal'] = isExternal;
307
- }
308
- if (paymentEnabled !== undefined) {
309
- localVarQueryParameter['PaymentEnabled'] = paymentEnabled;
310
- }
311
- if (languageCode !== undefined) {
312
- localVarQueryParameter['LanguageCode'] = languageCode;
313
- }
314
- if (page !== undefined) {
315
- localVarQueryParameter['page'] = page;
316
- }
317
- if (limit !== undefined) {
318
- localVarQueryParameter['limit'] = limit;
319
- }
320
- if (lastRetrieved !== undefined) {
321
- localVarQueryParameter['lastRetrieved'] = (lastRetrieved instanceof Date) ?
322
- lastRetrieved.toISOString() :
323
- lastRetrieved;
324
- }
325
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
326
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
327
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
328
- return [2 /*return*/, {
329
- url: (0, common_1.toPathString)(localVarUrlObj),
330
- options: localVarRequestOptions,
331
- }];
332
- }
333
- });
334
- });
335
- },
336
- /**
337
- *
338
- * @summary Create booking.
339
- * @param {string} requestId
340
- * @param {CreateBookingCommand} [createBookingCommand]
341
- * @param {*} [options] Override http request option.
342
- * @throws {RequiredError}
343
- */
344
- apiV2BookingsRequestIdPost: function (requestId, createBookingCommand, options) {
345
- if (options === void 0) { options = {}; }
346
- return __awaiter(_this, void 0, void 0, function () {
347
- var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
348
- return __generator(this, function (_a) {
349
- switch (_a.label) {
350
- case 0:
351
- // verify required parameter 'requestId' is not null or undefined
352
- (0, common_1.assertParamExists)('apiV2BookingsRequestIdPost', 'requestId', requestId);
353
- localVarPath = "/api/v2/bookings/{requestId}"
354
- .replace("{".concat("requestId", "}"), encodeURIComponent(String(requestId)));
355
- localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
356
- if (configuration) {
357
- baseOptions = configuration.baseOptions;
358
- }
359
- localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
360
- localVarHeaderParameter = {};
361
- localVarQueryParameter = {};
362
- // authentication oauth2 required
363
- // oauth required
364
- return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
365
- case 1:
366
- // authentication oauth2 required
367
- // oauth required
368
- _a.sent();
369
- localVarHeaderParameter['Content-Type'] = 'application/json';
370
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
371
- headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
372
- localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
373
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createBookingCommand, localVarRequestOptions, configuration);
374
- return [2 /*return*/, {
375
- url: (0, common_1.toPathString)(localVarUrlObj),
376
- options: localVarRequestOptions,
377
- }];
378
- }
379
- });
380
- });
381
- },
382
- };
383
- };
384
- exports.BookingsApiAxiosParamCreator = BookingsApiAxiosParamCreator;
385
- /**
386
- * BookingsApi - functional programming interface
387
- * @export
388
- */
389
- var BookingsApiFp = function (configuration) {
390
- var localVarAxiosParamCreator = (0, exports.BookingsApiAxiosParamCreator)(configuration);
391
- return {
392
- /**
393
- *
394
- * @summary Get booking.
395
- * @param {string} bookingId
396
- * @param {string} [languageCode]
397
- * @param {*} [options] Override http request option.
398
- * @throws {RequiredError}
399
- */
400
- apiV2BookingsBookingIdGet: function (bookingId, languageCode, options) {
401
- return __awaiter(this, void 0, void 0, function () {
402
- var localVarAxiosArgs;
403
- return __generator(this, function (_a) {
404
- switch (_a.label) {
405
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2BookingsBookingIdGet(bookingId, languageCode, options)];
406
- case 1:
407
- localVarAxiosArgs = _a.sent();
408
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
409
- }
410
- });
411
- });
412
- },
413
- /**
414
- *
415
- * @summary Pay booking.
416
- * @param {string} bookingId
417
- * @param {*} [options] Override http request option.
418
- * @throws {RequiredError}
419
- */
420
- apiV2BookingsBookingIdPayPost: function (bookingId, options) {
421
- return __awaiter(this, void 0, void 0, function () {
422
- var localVarAxiosArgs;
423
- return __generator(this, function (_a) {
424
- switch (_a.label) {
425
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2BookingsBookingIdPayPost(bookingId, options)];
426
- case 1:
427
- localVarAxiosArgs = _a.sent();
428
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
429
- }
430
- });
431
- });
432
- },
433
- /**
434
- *
435
- * @summary Update booking.
436
- * @param {string} bookingId
437
- * @param {UpdateBookingCommand} [updateBookingCommand]
438
- * @param {*} [options] Override http request option.
439
- * @throws {RequiredError}
440
- */
441
- apiV2BookingsBookingIdPut: function (bookingId, updateBookingCommand, options) {
442
- return __awaiter(this, void 0, void 0, function () {
443
- var localVarAxiosArgs;
444
- return __generator(this, function (_a) {
445
- switch (_a.label) {
446
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2BookingsBookingIdPut(bookingId, updateBookingCommand, options)];
447
- case 1:
448
- localVarAxiosArgs = _a.sent();
449
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
450
- }
451
- });
452
- });
453
- },
454
- /**
455
- *
456
- * @summary Get all bookings.
457
- * @param {string} [hospitalId]
458
- * @param {string} [hospitalName]
459
- * @param {string} [dealId]
460
- * @param {string} [dealName]
461
- * @param {boolean} [isOpen]
462
- * @param {boolean} [isCompleted]
463
- * @param {BookingStatus} [status]
464
- * @param {string} [dealPackageId]
465
- * @param {SortingOrder} [sortRequestDate]
466
- * @param {SortingOrder} [sortConfirmedDateStart]
467
- * @param {boolean} [isExternal]
468
- * @param {boolean} [paymentEnabled]
469
- * @param {string} [languageCode]
470
- * @param {number} [page]
471
- * @param {number} [limit]
472
- * @param {Date} [lastRetrieved]
473
- * @param {*} [options] Override http request option.
474
- * @throws {RequiredError}
475
- */
476
- apiV2BookingsGet: function (hospitalId, hospitalName, dealId, dealName, isOpen, isCompleted, status, dealPackageId, sortRequestDate, sortConfirmedDateStart, isExternal, paymentEnabled, languageCode, page, limit, lastRetrieved, options) {
477
- return __awaiter(this, void 0, void 0, function () {
478
- var localVarAxiosArgs;
479
- return __generator(this, function (_a) {
480
- switch (_a.label) {
481
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2BookingsGet(hospitalId, hospitalName, dealId, dealName, isOpen, isCompleted, status, dealPackageId, sortRequestDate, sortConfirmedDateStart, isExternal, paymentEnabled, languageCode, page, limit, lastRetrieved, options)];
482
- case 1:
483
- localVarAxiosArgs = _a.sent();
484
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
485
- }
486
- });
487
- });
488
- },
489
- /**
490
- *
491
- * @summary Create booking.
492
- * @param {string} requestId
493
- * @param {CreateBookingCommand} [createBookingCommand]
494
- * @param {*} [options] Override http request option.
495
- * @throws {RequiredError}
496
- */
497
- apiV2BookingsRequestIdPost: function (requestId, createBookingCommand, options) {
498
- return __awaiter(this, void 0, void 0, function () {
499
- var localVarAxiosArgs;
500
- return __generator(this, function (_a) {
501
- switch (_a.label) {
502
- case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2BookingsRequestIdPost(requestId, createBookingCommand, options)];
503
- case 1:
504
- localVarAxiosArgs = _a.sent();
505
- return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
506
- }
507
- });
508
- });
509
- },
510
- };
511
- };
512
- exports.BookingsApiFp = BookingsApiFp;
513
- /**
514
- * BookingsApi - factory interface
515
- * @export
516
- */
517
- var BookingsApiFactory = function (configuration, basePath, axios) {
518
- var localVarFp = (0, exports.BookingsApiFp)(configuration);
519
- return {
520
- /**
521
- *
522
- * @summary Get booking.
523
- * @param {string} bookingId
524
- * @param {string} [languageCode]
525
- * @param {*} [options] Override http request option.
526
- * @throws {RequiredError}
527
- */
528
- apiV2BookingsBookingIdGet: function (bookingId, languageCode, options) {
529
- return localVarFp.apiV2BookingsBookingIdGet(bookingId, languageCode, options).then(function (request) { return request(axios, basePath); });
530
- },
531
- /**
532
- *
533
- * @summary Pay booking.
534
- * @param {string} bookingId
535
- * @param {*} [options] Override http request option.
536
- * @throws {RequiredError}
537
- */
538
- apiV2BookingsBookingIdPayPost: function (bookingId, options) {
539
- return localVarFp.apiV2BookingsBookingIdPayPost(bookingId, options).then(function (request) { return request(axios, basePath); });
540
- },
541
- /**
542
- *
543
- * @summary Update booking.
544
- * @param {string} bookingId
545
- * @param {UpdateBookingCommand} [updateBookingCommand]
546
- * @param {*} [options] Override http request option.
547
- * @throws {RequiredError}
548
- */
549
- apiV2BookingsBookingIdPut: function (bookingId, updateBookingCommand, options) {
550
- return localVarFp.apiV2BookingsBookingIdPut(bookingId, updateBookingCommand, options).then(function (request) { return request(axios, basePath); });
551
- },
552
- /**
553
- *
554
- * @summary Get all bookings.
555
- * @param {string} [hospitalId]
556
- * @param {string} [hospitalName]
557
- * @param {string} [dealId]
558
- * @param {string} [dealName]
559
- * @param {boolean} [isOpen]
560
- * @param {boolean} [isCompleted]
561
- * @param {BookingStatus} [status]
562
- * @param {string} [dealPackageId]
563
- * @param {SortingOrder} [sortRequestDate]
564
- * @param {SortingOrder} [sortConfirmedDateStart]
565
- * @param {boolean} [isExternal]
566
- * @param {boolean} [paymentEnabled]
567
- * @param {string} [languageCode]
568
- * @param {number} [page]
569
- * @param {number} [limit]
570
- * @param {Date} [lastRetrieved]
571
- * @param {*} [options] Override http request option.
572
- * @throws {RequiredError}
573
- */
574
- apiV2BookingsGet: function (hospitalId, hospitalName, dealId, dealName, isOpen, isCompleted, status, dealPackageId, sortRequestDate, sortConfirmedDateStart, isExternal, paymentEnabled, languageCode, page, limit, lastRetrieved, options) {
575
- return localVarFp.apiV2BookingsGet(hospitalId, hospitalName, dealId, dealName, isOpen, isCompleted, status, dealPackageId, sortRequestDate, sortConfirmedDateStart, isExternal, paymentEnabled, languageCode, page, limit, lastRetrieved, options).then(function (request) { return request(axios, basePath); });
576
- },
577
- /**
578
- *
579
- * @summary Create booking.
580
- * @param {string} requestId
581
- * @param {CreateBookingCommand} [createBookingCommand]
582
- * @param {*} [options] Override http request option.
583
- * @throws {RequiredError}
584
- */
585
- apiV2BookingsRequestIdPost: function (requestId, createBookingCommand, options) {
586
- return localVarFp.apiV2BookingsRequestIdPost(requestId, createBookingCommand, options).then(function (request) { return request(axios, basePath); });
587
- },
588
- };
589
- };
590
- exports.BookingsApiFactory = BookingsApiFactory;
591
- /**
592
- * BookingsApi - object-oriented interface
593
- * @export
594
- * @class BookingsApi
595
- * @extends {BaseAPI}
596
- */
597
- var BookingsApi = /** @class */ (function (_super) {
598
- __extends(BookingsApi, _super);
599
- function BookingsApi() {
600
- return _super !== null && _super.apply(this, arguments) || this;
601
- }
602
- /**
603
- *
604
- * @summary Get booking.
605
- * @param {BookingsApiApiV2BookingsBookingIdGetRequest} requestParameters Request parameters.
606
- * @param {*} [options] Override http request option.
607
- * @throws {RequiredError}
608
- * @memberof BookingsApi
609
- */
610
- BookingsApi.prototype.apiV2BookingsBookingIdGet = function (requestParameters, options) {
611
- var _this = this;
612
- return (0, exports.BookingsApiFp)(this.configuration).apiV2BookingsBookingIdGet(requestParameters.bookingId, requestParameters.languageCode, options).then(function (request) { return request(_this.axios, _this.basePath); });
613
- };
614
- /**
615
- *
616
- * @summary Pay booking.
617
- * @param {BookingsApiApiV2BookingsBookingIdPayPostRequest} requestParameters Request parameters.
618
- * @param {*} [options] Override http request option.
619
- * @throws {RequiredError}
620
- * @memberof BookingsApi
621
- */
622
- BookingsApi.prototype.apiV2BookingsBookingIdPayPost = function (requestParameters, options) {
623
- var _this = this;
624
- return (0, exports.BookingsApiFp)(this.configuration).apiV2BookingsBookingIdPayPost(requestParameters.bookingId, options).then(function (request) { return request(_this.axios, _this.basePath); });
625
- };
626
- /**
627
- *
628
- * @summary Update booking.
629
- * @param {BookingsApiApiV2BookingsBookingIdPutRequest} requestParameters Request parameters.
630
- * @param {*} [options] Override http request option.
631
- * @throws {RequiredError}
632
- * @memberof BookingsApi
633
- */
634
- BookingsApi.prototype.apiV2BookingsBookingIdPut = function (requestParameters, options) {
635
- var _this = this;
636
- return (0, exports.BookingsApiFp)(this.configuration).apiV2BookingsBookingIdPut(requestParameters.bookingId, requestParameters.updateBookingCommand, options).then(function (request) { return request(_this.axios, _this.basePath); });
637
- };
638
- /**
639
- *
640
- * @summary Get all bookings.
641
- * @param {BookingsApiApiV2BookingsGetRequest} requestParameters Request parameters.
642
- * @param {*} [options] Override http request option.
643
- * @throws {RequiredError}
644
- * @memberof BookingsApi
645
- */
646
- BookingsApi.prototype.apiV2BookingsGet = function (requestParameters, options) {
647
- var _this = this;
648
- if (requestParameters === void 0) { requestParameters = {}; }
649
- return (0, exports.BookingsApiFp)(this.configuration).apiV2BookingsGet(requestParameters.hospitalId, requestParameters.hospitalName, requestParameters.dealId, requestParameters.dealName, requestParameters.isOpen, requestParameters.isCompleted, requestParameters.status, requestParameters.dealPackageId, requestParameters.sortRequestDate, requestParameters.sortConfirmedDateStart, requestParameters.isExternal, requestParameters.paymentEnabled, requestParameters.languageCode, requestParameters.page, requestParameters.limit, requestParameters.lastRetrieved, options).then(function (request) { return request(_this.axios, _this.basePath); });
650
- };
651
- /**
652
- *
653
- * @summary Create booking.
654
- * @param {BookingsApiApiV2BookingsRequestIdPostRequest} requestParameters Request parameters.
655
- * @param {*} [options] Override http request option.
656
- * @throws {RequiredError}
657
- * @memberof BookingsApi
658
- */
659
- BookingsApi.prototype.apiV2BookingsRequestIdPost = function (requestParameters, options) {
660
- var _this = this;
661
- return (0, exports.BookingsApiFp)(this.configuration).apiV2BookingsRequestIdPost(requestParameters.requestId, requestParameters.createBookingCommand, options).then(function (request) { return request(_this.axios, _this.basePath); });
662
- };
663
- return BookingsApi;
664
- }(base_1.BaseAPI));
665
- exports.BookingsApi = BookingsApi;