ch-api-client-typescript2 4.9.4 → 4.9.6

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 (118) hide show
  1. package/lib/api/appointments-api.d.ts +296 -0
  2. package/lib/api/appointments-api.d.ts.map +1 -0
  3. package/lib/api/appointments-api.js +703 -0
  4. package/lib/api/deals-api.d.ts +103 -0
  5. package/lib/api/deals-api.d.ts.map +1 -1
  6. package/lib/api/deals-api.js +233 -0
  7. package/lib/api/doctor-affiliations-api.d.ts +50 -0
  8. package/lib/api/doctor-affiliations-api.d.ts.map +1 -1
  9. package/lib/api/doctor-affiliations-api.js +113 -0
  10. package/lib/api/hospitals-api.d.ts +160 -0
  11. package/lib/api/hospitals-api.d.ts.map +1 -1
  12. package/lib/api/hospitals-api.js +360 -0
  13. package/lib/api.d.ts +1 -0
  14. package/lib/api.d.ts.map +1 -1
  15. package/lib/api.js +1 -0
  16. package/lib/models/appointment-change-log-model.d.ts +44 -0
  17. package/lib/models/appointment-change-log-model.d.ts.map +1 -0
  18. package/lib/models/appointment-change-log-model.js +15 -0
  19. package/lib/models/appointment-item-model.d.ts +305 -0
  20. package/lib/models/appointment-item-model.d.ts.map +1 -0
  21. package/lib/models/appointment-item-model.js +15 -0
  22. package/lib/models/appointment-model.d.ts +325 -0
  23. package/lib/models/appointment-model.d.ts.map +1 -0
  24. package/lib/models/appointment-model.js +15 -0
  25. package/lib/models/appointment-option-model.d.ts +49 -0
  26. package/lib/models/appointment-option-model.d.ts.map +1 -0
  27. package/lib/models/appointment-option-model.js +15 -0
  28. package/lib/models/appointment-status.d.ts +27 -0
  29. package/lib/models/appointment-status.d.ts.map +1 -0
  30. package/lib/models/appointment-status.js +30 -0
  31. package/lib/models/appointment-timetable-date-model.d.ts +58 -0
  32. package/lib/models/appointment-timetable-date-model.d.ts.map +1 -0
  33. package/lib/models/appointment-timetable-date-model.js +15 -0
  34. package/lib/models/appointment-timetable-status.d.ts +22 -0
  35. package/lib/models/appointment-timetable-status.d.ts.map +1 -0
  36. package/lib/models/appointment-timetable-status.js +25 -0
  37. package/lib/models/appointment-timetable-time-slot-model.d.ts +56 -0
  38. package/lib/models/appointment-timetable-time-slot-model.d.ts.map +1 -0
  39. package/lib/models/appointment-timetable-time-slot-model.js +15 -0
  40. package/lib/models/appointment-timetables-model.d.ts +44 -0
  41. package/lib/models/appointment-timetables-model.d.ts.map +1 -0
  42. package/lib/models/appointment-timetables-model.js +15 -0
  43. package/lib/models/appointment-type.d.ts +26 -0
  44. package/lib/models/appointment-type.d.ts.map +1 -0
  45. package/lib/models/appointment-type.js +29 -0
  46. package/lib/models/appointments-model.d.ts +33 -0
  47. package/lib/models/appointments-model.d.ts.map +1 -0
  48. package/lib/models/appointments-model.js +15 -0
  49. package/lib/models/create-appointment-command.d.ts +153 -0
  50. package/lib/models/create-appointment-command.d.ts.map +1 -0
  51. package/lib/models/create-appointment-command.js +15 -0
  52. package/lib/models/deal-item-model.d.ts +7 -0
  53. package/lib/models/deal-item-model.d.ts.map +1 -1
  54. package/lib/models/deal-model.d.ts +7 -0
  55. package/lib/models/deal-model.d.ts.map +1 -1
  56. package/lib/models/deal-package-item-model.d.ts +7 -0
  57. package/lib/models/deal-package-item-model.d.ts.map +1 -1
  58. package/lib/models/deal-package-model.d.ts +7 -0
  59. package/lib/models/deal-package-model.d.ts.map +1 -1
  60. package/lib/models/doctor-affiliation-item-model.d.ts +7 -0
  61. package/lib/models/doctor-affiliation-item-model.d.ts.map +1 -1
  62. package/lib/models/doctor-affiliation-model.d.ts +7 -0
  63. package/lib/models/doctor-affiliation-model.d.ts.map +1 -1
  64. package/lib/models/hospital-item-model.d.ts +7 -0
  65. package/lib/models/hospital-item-model.d.ts.map +1 -1
  66. package/lib/models/hospital-model.d.ts +7 -0
  67. package/lib/models/hospital-model.d.ts.map +1 -1
  68. package/lib/models/hospital-service-item-model.d.ts +7 -0
  69. package/lib/models/hospital-service-item-model.d.ts.map +1 -1
  70. package/lib/models/hospital-service-model.d.ts +7 -0
  71. package/lib/models/hospital-service-model.d.ts.map +1 -1
  72. package/lib/models/hospital-specialty-item-model.d.ts +7 -0
  73. package/lib/models/hospital-specialty-item-model.d.ts.map +1 -1
  74. package/lib/models/hospital-specialty-model.d.ts +7 -0
  75. package/lib/models/hospital-specialty-model.d.ts.map +1 -1
  76. package/lib/models/index.d.ts +13 -0
  77. package/lib/models/index.d.ts.map +1 -1
  78. package/lib/models/index.js +13 -0
  79. package/lib/models/notification-code.d.ts +9 -0
  80. package/lib/models/notification-code.d.ts.map +1 -1
  81. package/lib/models/notification-code.js +10 -1
  82. package/lib/models/update-appointment-command.d.ts +98 -0
  83. package/lib/models/update-appointment-command.d.ts.map +1 -0
  84. package/lib/models/update-appointment-command.js +15 -0
  85. package/package.json +1 -1
  86. package/src/.openapi-generator/FILES +14 -0
  87. package/src/api/appointments-api.ts +594 -0
  88. package/src/api/deals-api.ts +215 -0
  89. package/src/api/doctor-affiliations-api.ts +105 -0
  90. package/src/api/hospitals-api.ts +332 -0
  91. package/src/api.ts +1 -0
  92. package/src/models/appointment-change-log-model.ts +51 -0
  93. package/src/models/appointment-item-model.ts +318 -0
  94. package/src/models/appointment-model.ts +342 -0
  95. package/src/models/appointment-option-model.ts +54 -0
  96. package/src/models/appointment-status.ts +36 -0
  97. package/src/models/appointment-timetable-date-model.ts +69 -0
  98. package/src/models/appointment-timetable-status.ts +31 -0
  99. package/src/models/appointment-timetable-time-slot-model.ts +63 -0
  100. package/src/models/appointment-timetables-model.ts +51 -0
  101. package/src/models/appointment-type.ts +35 -0
  102. package/src/models/appointments-model.ts +42 -0
  103. package/src/models/create-appointment-command.ts +162 -0
  104. package/src/models/deal-item-model.ts +9 -0
  105. package/src/models/deal-model.ts +9 -0
  106. package/src/models/deal-package-item-model.ts +9 -0
  107. package/src/models/deal-package-model.ts +9 -0
  108. package/src/models/doctor-affiliation-item-model.ts +9 -0
  109. package/src/models/doctor-affiliation-model.ts +9 -0
  110. package/src/models/hospital-item-model.ts +9 -0
  111. package/src/models/hospital-model.ts +9 -0
  112. package/src/models/hospital-service-item-model.ts +9 -0
  113. package/src/models/hospital-service-model.ts +9 -0
  114. package/src/models/hospital-specialty-item-model.ts +9 -0
  115. package/src/models/hospital-specialty-model.ts +9 -0
  116. package/src/models/index.ts +13 -0
  117. package/src/models/notification-code.ts +10 -1
  118. package/src/models/update-appointment-command.ts +105 -0
@@ -0,0 +1,703 @@
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.AppointmentsApi = exports.AppointmentsApiFactory = exports.AppointmentsApiFp = exports.AppointmentsApiAxiosParamCreator = 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
+ * AppointmentsApi - axios parameter creator
90
+ * @export
91
+ */
92
+ var AppointmentsApiAxiosParamCreator = function (configuration) {
93
+ var _this = this;
94
+ return {
95
+ /**
96
+ *
97
+ * @summary Get appointment by id
98
+ * @param {string} appointmentId
99
+ * @param {string} [languageCode]
100
+ * @param {*} [options] Override http request option.
101
+ * @throws {RequiredError}
102
+ */
103
+ apiV2AppointmentsAppointmentIdGet: function (appointmentId, 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 'appointmentId' is not null or undefined
111
+ (0, common_1.assertParamExists)('apiV2AppointmentsAppointmentIdGet', 'appointmentId', appointmentId);
112
+ localVarPath = "/api/v2/appointments/{appointmentId}"
113
+ .replace("{".concat("appointmentId", "}"), encodeURIComponent(String(appointmentId)));
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 appointment
145
+ * @param {string} appointmentId
146
+ * @param {*} [options] Override http request option.
147
+ * @throws {RequiredError}
148
+ */
149
+ apiV2AppointmentsAppointmentIdPayPost: function (appointmentId, 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 'appointmentId' is not null or undefined
157
+ (0, common_1.assertParamExists)('apiV2AppointmentsAppointmentIdPayPost', 'appointmentId', appointmentId);
158
+ localVarPath = "/api/v2/appointments/{appointmentId}/pay"
159
+ .replace("{".concat("appointmentId", "}"), encodeURIComponent(String(appointmentId)));
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 appointment
188
+ * @param {string} appointmentId
189
+ * @param {UpdateAppointmentCommand} [updateAppointmentCommand]
190
+ * @param {*} [options] Override http request option.
191
+ * @throws {RequiredError}
192
+ */
193
+ apiV2AppointmentsAppointmentIdPut: function (appointmentId, updateAppointmentCommand, 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 'appointmentId' is not null or undefined
201
+ (0, common_1.assertParamExists)('apiV2AppointmentsAppointmentIdPut', 'appointmentId', appointmentId);
202
+ localVarPath = "/api/v2/appointments/{appointmentId}"
203
+ .replace("{".concat("appointmentId", "}"), encodeURIComponent(String(appointmentId)));
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)(updateAppointmentCommand, 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 appointments
234
+ * @param {string} [hospitalId]
235
+ * @param {string} [hospitalName]
236
+ * @param {string} [doctorAffiliationId]
237
+ * @param {string} [doctorId]
238
+ * @param {string} [doctorName]
239
+ * @param {string} [dealId]
240
+ * @param {string} [dealName]
241
+ * @param {string} [dealPackageId]
242
+ * @param {string} [hospitalSpecialtyId]
243
+ * @param {string} [serviceId]
244
+ * @param {boolean} [isOpen]
245
+ * @param {boolean} [isCompleted]
246
+ * @param {AppointmentStatus} [status]
247
+ * @param {AppointmentType} [appointmentType]
248
+ * @param {string} [languageCode]
249
+ * @param {boolean} [isExternal]
250
+ * @param {number} [page]
251
+ * @param {number} [limit]
252
+ * @param {Date} [lastRetrieved]
253
+ * @param {*} [options] Override http request option.
254
+ * @throws {RequiredError}
255
+ */
256
+ apiV2AppointmentsGet: function (hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options) {
257
+ if (options === void 0) { options = {}; }
258
+ return __awaiter(_this, void 0, void 0, function () {
259
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
260
+ return __generator(this, function (_a) {
261
+ switch (_a.label) {
262
+ case 0:
263
+ localVarPath = "/api/v2/appointments";
264
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
265
+ if (configuration) {
266
+ baseOptions = configuration.baseOptions;
267
+ }
268
+ localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
269
+ localVarHeaderParameter = {};
270
+ localVarQueryParameter = {};
271
+ // authentication oauth2 required
272
+ // oauth required
273
+ return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
274
+ case 1:
275
+ // authentication oauth2 required
276
+ // oauth required
277
+ _a.sent();
278
+ if (hospitalId !== undefined) {
279
+ localVarQueryParameter['HospitalId'] = hospitalId;
280
+ }
281
+ if (hospitalName !== undefined) {
282
+ localVarQueryParameter['HospitalName'] = hospitalName;
283
+ }
284
+ if (doctorAffiliationId !== undefined) {
285
+ localVarQueryParameter['DoctorAffiliationId'] = doctorAffiliationId;
286
+ }
287
+ if (doctorId !== undefined) {
288
+ localVarQueryParameter['DoctorId'] = doctorId;
289
+ }
290
+ if (doctorName !== undefined) {
291
+ localVarQueryParameter['DoctorName'] = doctorName;
292
+ }
293
+ if (dealId !== undefined) {
294
+ localVarQueryParameter['DealId'] = dealId;
295
+ }
296
+ if (dealName !== undefined) {
297
+ localVarQueryParameter['DealName'] = dealName;
298
+ }
299
+ if (dealPackageId !== undefined) {
300
+ localVarQueryParameter['DealPackageId'] = dealPackageId;
301
+ }
302
+ if (hospitalSpecialtyId !== undefined) {
303
+ localVarQueryParameter['HospitalSpecialtyId'] = hospitalSpecialtyId;
304
+ }
305
+ if (serviceId !== undefined) {
306
+ localVarQueryParameter['ServiceId'] = serviceId;
307
+ }
308
+ if (isOpen !== undefined) {
309
+ localVarQueryParameter['IsOpen'] = isOpen;
310
+ }
311
+ if (isCompleted !== undefined) {
312
+ localVarQueryParameter['IsCompleted'] = isCompleted;
313
+ }
314
+ if (status !== undefined) {
315
+ localVarQueryParameter['Status'] = status;
316
+ }
317
+ if (appointmentType !== undefined) {
318
+ localVarQueryParameter['AppointmentType'] = appointmentType;
319
+ }
320
+ if (languageCode !== undefined) {
321
+ localVarQueryParameter['LanguageCode'] = languageCode;
322
+ }
323
+ if (isExternal !== undefined) {
324
+ localVarQueryParameter['IsExternal'] = isExternal;
325
+ }
326
+ if (page !== undefined) {
327
+ localVarQueryParameter['page'] = page;
328
+ }
329
+ if (limit !== undefined) {
330
+ localVarQueryParameter['limit'] = limit;
331
+ }
332
+ if (lastRetrieved !== undefined) {
333
+ localVarQueryParameter['lastRetrieved'] = (lastRetrieved instanceof Date) ?
334
+ lastRetrieved.toISOString() :
335
+ lastRetrieved;
336
+ }
337
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
338
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
339
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
340
+ return [2 /*return*/, {
341
+ url: (0, common_1.toPathString)(localVarUrlObj),
342
+ options: localVarRequestOptions,
343
+ }];
344
+ }
345
+ });
346
+ });
347
+ },
348
+ /**
349
+ *
350
+ * @summary Create appointment
351
+ * @param {string} requestId
352
+ * @param {CreateAppointmentCommand} [createAppointmentCommand]
353
+ * @param {*} [options] Override http request option.
354
+ * @throws {RequiredError}
355
+ */
356
+ apiV2AppointmentsRequestIdPost: function (requestId, createAppointmentCommand, options) {
357
+ if (options === void 0) { options = {}; }
358
+ return __awaiter(_this, void 0, void 0, function () {
359
+ var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
360
+ return __generator(this, function (_a) {
361
+ switch (_a.label) {
362
+ case 0:
363
+ // verify required parameter 'requestId' is not null or undefined
364
+ (0, common_1.assertParamExists)('apiV2AppointmentsRequestIdPost', 'requestId', requestId);
365
+ localVarPath = "/api/v2/appointments/{requestId}"
366
+ .replace("{".concat("requestId", "}"), encodeURIComponent(String(requestId)));
367
+ localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
368
+ if (configuration) {
369
+ baseOptions = configuration.baseOptions;
370
+ }
371
+ localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
372
+ localVarHeaderParameter = {};
373
+ localVarQueryParameter = {};
374
+ // authentication oauth2 required
375
+ // oauth required
376
+ return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "oauth2", ["CloudHospital_api", "IdentityServerApi"], configuration)];
377
+ case 1:
378
+ // authentication oauth2 required
379
+ // oauth required
380
+ _a.sent();
381
+ localVarHeaderParameter['Content-Type'] = 'application/json';
382
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
383
+ headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
384
+ localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
385
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createAppointmentCommand, localVarRequestOptions, configuration);
386
+ return [2 /*return*/, {
387
+ url: (0, common_1.toPathString)(localVarUrlObj),
388
+ options: localVarRequestOptions,
389
+ }];
390
+ }
391
+ });
392
+ });
393
+ },
394
+ };
395
+ };
396
+ exports.AppointmentsApiAxiosParamCreator = AppointmentsApiAxiosParamCreator;
397
+ /**
398
+ * AppointmentsApi - functional programming interface
399
+ * @export
400
+ */
401
+ var AppointmentsApiFp = function (configuration) {
402
+ var localVarAxiosParamCreator = (0, exports.AppointmentsApiAxiosParamCreator)(configuration);
403
+ return {
404
+ /**
405
+ *
406
+ * @summary Get appointment by id
407
+ * @param {string} appointmentId
408
+ * @param {string} [languageCode]
409
+ * @param {*} [options] Override http request option.
410
+ * @throws {RequiredError}
411
+ */
412
+ apiV2AppointmentsAppointmentIdGet: function (appointmentId, languageCode, options) {
413
+ return __awaiter(this, void 0, void 0, function () {
414
+ var localVarAxiosArgs;
415
+ return __generator(this, function (_a) {
416
+ switch (_a.label) {
417
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2AppointmentsAppointmentIdGet(appointmentId, languageCode, options)];
418
+ case 1:
419
+ localVarAxiosArgs = _a.sent();
420
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
421
+ }
422
+ });
423
+ });
424
+ },
425
+ /**
426
+ *
427
+ * @summary Pay appointment
428
+ * @param {string} appointmentId
429
+ * @param {*} [options] Override http request option.
430
+ * @throws {RequiredError}
431
+ */
432
+ apiV2AppointmentsAppointmentIdPayPost: function (appointmentId, options) {
433
+ return __awaiter(this, void 0, void 0, function () {
434
+ var localVarAxiosArgs;
435
+ return __generator(this, function (_a) {
436
+ switch (_a.label) {
437
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2AppointmentsAppointmentIdPayPost(appointmentId, options)];
438
+ case 1:
439
+ localVarAxiosArgs = _a.sent();
440
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
441
+ }
442
+ });
443
+ });
444
+ },
445
+ /**
446
+ *
447
+ * @summary Update appointment
448
+ * @param {string} appointmentId
449
+ * @param {UpdateAppointmentCommand} [updateAppointmentCommand]
450
+ * @param {*} [options] Override http request option.
451
+ * @throws {RequiredError}
452
+ */
453
+ apiV2AppointmentsAppointmentIdPut: function (appointmentId, updateAppointmentCommand, options) {
454
+ return __awaiter(this, void 0, void 0, function () {
455
+ var localVarAxiosArgs;
456
+ return __generator(this, function (_a) {
457
+ switch (_a.label) {
458
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2AppointmentsAppointmentIdPut(appointmentId, updateAppointmentCommand, options)];
459
+ case 1:
460
+ localVarAxiosArgs = _a.sent();
461
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
462
+ }
463
+ });
464
+ });
465
+ },
466
+ /**
467
+ *
468
+ * @summary Get appointments
469
+ * @param {string} [hospitalId]
470
+ * @param {string} [hospitalName]
471
+ * @param {string} [doctorAffiliationId]
472
+ * @param {string} [doctorId]
473
+ * @param {string} [doctorName]
474
+ * @param {string} [dealId]
475
+ * @param {string} [dealName]
476
+ * @param {string} [dealPackageId]
477
+ * @param {string} [hospitalSpecialtyId]
478
+ * @param {string} [serviceId]
479
+ * @param {boolean} [isOpen]
480
+ * @param {boolean} [isCompleted]
481
+ * @param {AppointmentStatus} [status]
482
+ * @param {AppointmentType} [appointmentType]
483
+ * @param {string} [languageCode]
484
+ * @param {boolean} [isExternal]
485
+ * @param {number} [page]
486
+ * @param {number} [limit]
487
+ * @param {Date} [lastRetrieved]
488
+ * @param {*} [options] Override http request option.
489
+ * @throws {RequiredError}
490
+ */
491
+ apiV2AppointmentsGet: function (hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options) {
492
+ return __awaiter(this, void 0, void 0, function () {
493
+ var localVarAxiosArgs;
494
+ return __generator(this, function (_a) {
495
+ switch (_a.label) {
496
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2AppointmentsGet(hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options)];
497
+ case 1:
498
+ localVarAxiosArgs = _a.sent();
499
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
500
+ }
501
+ });
502
+ });
503
+ },
504
+ /**
505
+ *
506
+ * @summary Create appointment
507
+ * @param {string} requestId
508
+ * @param {CreateAppointmentCommand} [createAppointmentCommand]
509
+ * @param {*} [options] Override http request option.
510
+ * @throws {RequiredError}
511
+ */
512
+ apiV2AppointmentsRequestIdPost: function (requestId, createAppointmentCommand, options) {
513
+ return __awaiter(this, void 0, void 0, function () {
514
+ var localVarAxiosArgs;
515
+ return __generator(this, function (_a) {
516
+ switch (_a.label) {
517
+ case 0: return [4 /*yield*/, localVarAxiosParamCreator.apiV2AppointmentsRequestIdPost(requestId, createAppointmentCommand, options)];
518
+ case 1:
519
+ localVarAxiosArgs = _a.sent();
520
+ return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
521
+ }
522
+ });
523
+ });
524
+ },
525
+ };
526
+ };
527
+ exports.AppointmentsApiFp = AppointmentsApiFp;
528
+ /**
529
+ * AppointmentsApi - factory interface
530
+ * @export
531
+ */
532
+ var AppointmentsApiFactory = function (configuration, basePath, axios) {
533
+ var localVarFp = (0, exports.AppointmentsApiFp)(configuration);
534
+ return {
535
+ /**
536
+ *
537
+ * @summary Get appointment by id
538
+ * @param {string} appointmentId
539
+ * @param {string} [languageCode]
540
+ * @param {*} [options] Override http request option.
541
+ * @throws {RequiredError}
542
+ */
543
+ apiV2AppointmentsAppointmentIdGet: function (appointmentId, languageCode, options) {
544
+ return localVarFp.apiV2AppointmentsAppointmentIdGet(appointmentId, languageCode, options).then(function (request) { return request(axios, basePath); });
545
+ },
546
+ /**
547
+ *
548
+ * @summary Pay appointment
549
+ * @param {string} appointmentId
550
+ * @param {*} [options] Override http request option.
551
+ * @throws {RequiredError}
552
+ */
553
+ apiV2AppointmentsAppointmentIdPayPost: function (appointmentId, options) {
554
+ return localVarFp.apiV2AppointmentsAppointmentIdPayPost(appointmentId, options).then(function (request) { return request(axios, basePath); });
555
+ },
556
+ /**
557
+ *
558
+ * @summary Update appointment
559
+ * @param {string} appointmentId
560
+ * @param {UpdateAppointmentCommand} [updateAppointmentCommand]
561
+ * @param {*} [options] Override http request option.
562
+ * @throws {RequiredError}
563
+ */
564
+ apiV2AppointmentsAppointmentIdPut: function (appointmentId, updateAppointmentCommand, options) {
565
+ return localVarFp.apiV2AppointmentsAppointmentIdPut(appointmentId, updateAppointmentCommand, options).then(function (request) { return request(axios, basePath); });
566
+ },
567
+ /**
568
+ *
569
+ * @summary Get appointments
570
+ * @param {string} [hospitalId]
571
+ * @param {string} [hospitalName]
572
+ * @param {string} [doctorAffiliationId]
573
+ * @param {string} [doctorId]
574
+ * @param {string} [doctorName]
575
+ * @param {string} [dealId]
576
+ * @param {string} [dealName]
577
+ * @param {string} [dealPackageId]
578
+ * @param {string} [hospitalSpecialtyId]
579
+ * @param {string} [serviceId]
580
+ * @param {boolean} [isOpen]
581
+ * @param {boolean} [isCompleted]
582
+ * @param {AppointmentStatus} [status]
583
+ * @param {AppointmentType} [appointmentType]
584
+ * @param {string} [languageCode]
585
+ * @param {boolean} [isExternal]
586
+ * @param {number} [page]
587
+ * @param {number} [limit]
588
+ * @param {Date} [lastRetrieved]
589
+ * @param {*} [options] Override http request option.
590
+ * @throws {RequiredError}
591
+ */
592
+ apiV2AppointmentsGet: function (hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options) {
593
+ return localVarFp.apiV2AppointmentsGet(hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options).then(function (request) { return request(axios, basePath); });
594
+ },
595
+ /**
596
+ *
597
+ * @summary Create appointment
598
+ * @param {string} requestId
599
+ * @param {CreateAppointmentCommand} [createAppointmentCommand]
600
+ * @param {*} [options] Override http request option.
601
+ * @throws {RequiredError}
602
+ */
603
+ apiV2AppointmentsRequestIdPost: function (requestId, createAppointmentCommand, options) {
604
+ return localVarFp.apiV2AppointmentsRequestIdPost(requestId, createAppointmentCommand, options).then(function (request) { return request(axios, basePath); });
605
+ },
606
+ };
607
+ };
608
+ exports.AppointmentsApiFactory = AppointmentsApiFactory;
609
+ /**
610
+ * AppointmentsApi - object-oriented interface
611
+ * @export
612
+ * @class AppointmentsApi
613
+ * @extends {BaseAPI}
614
+ */
615
+ var AppointmentsApi = /** @class */ (function (_super) {
616
+ __extends(AppointmentsApi, _super);
617
+ function AppointmentsApi() {
618
+ return _super !== null && _super.apply(this, arguments) || this;
619
+ }
620
+ /**
621
+ *
622
+ * @summary Get appointment by id
623
+ * @param {string} appointmentId
624
+ * @param {string} [languageCode]
625
+ * @param {*} [options] Override http request option.
626
+ * @throws {RequiredError}
627
+ * @memberof AppointmentsApi
628
+ */
629
+ AppointmentsApi.prototype.apiV2AppointmentsAppointmentIdGet = function (appointmentId, languageCode, options) {
630
+ var _this = this;
631
+ return (0, exports.AppointmentsApiFp)(this.configuration).apiV2AppointmentsAppointmentIdGet(appointmentId, languageCode, options).then(function (request) { return request(_this.axios, _this.basePath); });
632
+ };
633
+ /**
634
+ *
635
+ * @summary Pay appointment
636
+ * @param {string} appointmentId
637
+ * @param {*} [options] Override http request option.
638
+ * @throws {RequiredError}
639
+ * @memberof AppointmentsApi
640
+ */
641
+ AppointmentsApi.prototype.apiV2AppointmentsAppointmentIdPayPost = function (appointmentId, options) {
642
+ var _this = this;
643
+ return (0, exports.AppointmentsApiFp)(this.configuration).apiV2AppointmentsAppointmentIdPayPost(appointmentId, options).then(function (request) { return request(_this.axios, _this.basePath); });
644
+ };
645
+ /**
646
+ *
647
+ * @summary Update appointment
648
+ * @param {string} appointmentId
649
+ * @param {UpdateAppointmentCommand} [updateAppointmentCommand]
650
+ * @param {*} [options] Override http request option.
651
+ * @throws {RequiredError}
652
+ * @memberof AppointmentsApi
653
+ */
654
+ AppointmentsApi.prototype.apiV2AppointmentsAppointmentIdPut = function (appointmentId, updateAppointmentCommand, options) {
655
+ var _this = this;
656
+ return (0, exports.AppointmentsApiFp)(this.configuration).apiV2AppointmentsAppointmentIdPut(appointmentId, updateAppointmentCommand, options).then(function (request) { return request(_this.axios, _this.basePath); });
657
+ };
658
+ /**
659
+ *
660
+ * @summary Get appointments
661
+ * @param {string} [hospitalId]
662
+ * @param {string} [hospitalName]
663
+ * @param {string} [doctorAffiliationId]
664
+ * @param {string} [doctorId]
665
+ * @param {string} [doctorName]
666
+ * @param {string} [dealId]
667
+ * @param {string} [dealName]
668
+ * @param {string} [dealPackageId]
669
+ * @param {string} [hospitalSpecialtyId]
670
+ * @param {string} [serviceId]
671
+ * @param {boolean} [isOpen]
672
+ * @param {boolean} [isCompleted]
673
+ * @param {AppointmentStatus} [status]
674
+ * @param {AppointmentType} [appointmentType]
675
+ * @param {string} [languageCode]
676
+ * @param {boolean} [isExternal]
677
+ * @param {number} [page]
678
+ * @param {number} [limit]
679
+ * @param {Date} [lastRetrieved]
680
+ * @param {*} [options] Override http request option.
681
+ * @throws {RequiredError}
682
+ * @memberof AppointmentsApi
683
+ */
684
+ AppointmentsApi.prototype.apiV2AppointmentsGet = function (hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options) {
685
+ var _this = this;
686
+ return (0, exports.AppointmentsApiFp)(this.configuration).apiV2AppointmentsGet(hospitalId, hospitalName, doctorAffiliationId, doctorId, doctorName, dealId, dealName, dealPackageId, hospitalSpecialtyId, serviceId, isOpen, isCompleted, status, appointmentType, languageCode, isExternal, page, limit, lastRetrieved, options).then(function (request) { return request(_this.axios, _this.basePath); });
687
+ };
688
+ /**
689
+ *
690
+ * @summary Create appointment
691
+ * @param {string} requestId
692
+ * @param {CreateAppointmentCommand} [createAppointmentCommand]
693
+ * @param {*} [options] Override http request option.
694
+ * @throws {RequiredError}
695
+ * @memberof AppointmentsApi
696
+ */
697
+ AppointmentsApi.prototype.apiV2AppointmentsRequestIdPost = function (requestId, createAppointmentCommand, options) {
698
+ var _this = this;
699
+ return (0, exports.AppointmentsApiFp)(this.configuration).apiV2AppointmentsRequestIdPost(requestId, createAppointmentCommand, options).then(function (request) { return request(_this.axios, _this.basePath); });
700
+ };
701
+ return AppointmentsApi;
702
+ }(base_1.BaseAPI));
703
+ exports.AppointmentsApi = AppointmentsApi;