phenoml 6.0.0 → 6.2.0
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/cjs/BaseClient.d.ts +4 -0
- package/dist/cjs/Client.js +2 -2
- package/dist/cjs/api/resources/agent/client/Client.js +24 -8
- package/dist/cjs/api/resources/agent/resources/prompts/client/Client.js +21 -7
- package/dist/cjs/api/resources/cohort/client/Client.js +3 -1
- package/dist/cjs/api/resources/construe/client/Client.js +30 -10
- package/dist/cjs/api/resources/fhir/client/Client.js +18 -6
- package/dist/cjs/api/resources/fhirProvider/client/Client.js +21 -7
- package/dist/cjs/api/resources/lang2Fhir/client/Client.js +15 -5
- package/dist/cjs/api/resources/summary/client/Client.js +18 -6
- package/dist/cjs/api/resources/tools/client/Client.js +12 -4
- package/dist/cjs/api/resources/tools/resources/mcpServer/client/Client.js +12 -4
- package/dist/cjs/api/resources/tools/resources/mcpServer/resources/tools/client/Client.js +12 -4
- package/dist/cjs/api/resources/workflows/client/Client.js +18 -6
- package/dist/cjs/core/exports.d.ts +1 -0
- package/dist/cjs/core/exports.js +17 -0
- package/dist/cjs/core/fetcher/Fetcher.d.ts +4 -1
- package/dist/cjs/core/fetcher/Fetcher.js +181 -5
- package/dist/cjs/core/fetcher/getRequestBody.d.ts +1 -1
- package/dist/cjs/core/fetcher/getRequestBody.js +4 -0
- package/dist/cjs/core/headers.js +6 -4
- package/dist/cjs/core/index.d.ts +1 -0
- package/dist/cjs/core/index.js +2 -1
- package/dist/cjs/core/logging/exports.d.ts +18 -0
- package/dist/cjs/core/logging/exports.js +45 -0
- package/dist/cjs/core/logging/index.d.ts +1 -0
- package/dist/cjs/core/logging/index.js +17 -0
- package/dist/cjs/core/logging/logger.d.ts +126 -0
- package/dist/cjs/core/logging/logger.js +144 -0
- package/dist/cjs/exports.d.ts +1 -0
- package/dist/cjs/exports.js +17 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.d.mts +4 -0
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/api/resources/agent/client/Client.mjs +24 -8
- package/dist/esm/api/resources/agent/resources/prompts/client/Client.mjs +21 -7
- package/dist/esm/api/resources/cohort/client/Client.mjs +3 -1
- package/dist/esm/api/resources/construe/client/Client.mjs +30 -10
- package/dist/esm/api/resources/fhir/client/Client.mjs +18 -6
- package/dist/esm/api/resources/fhirProvider/client/Client.mjs +21 -7
- package/dist/esm/api/resources/lang2Fhir/client/Client.mjs +15 -5
- package/dist/esm/api/resources/summary/client/Client.mjs +18 -6
- package/dist/esm/api/resources/tools/client/Client.mjs +12 -4
- package/dist/esm/api/resources/tools/resources/mcpServer/client/Client.mjs +12 -4
- package/dist/esm/api/resources/tools/resources/mcpServer/resources/tools/client/Client.mjs +12 -4
- package/dist/esm/api/resources/workflows/client/Client.mjs +18 -6
- package/dist/esm/core/exports.d.mts +1 -0
- package/dist/esm/core/exports.mjs +1 -0
- package/dist/esm/core/fetcher/Fetcher.d.mts +4 -1
- package/dist/esm/core/fetcher/Fetcher.mjs +181 -5
- package/dist/esm/core/fetcher/getRequestBody.d.mts +1 -1
- package/dist/esm/core/fetcher/getRequestBody.mjs +4 -0
- package/dist/esm/core/headers.mjs +6 -4
- package/dist/esm/core/index.d.mts +1 -0
- package/dist/esm/core/index.mjs +1 -0
- package/dist/esm/core/logging/exports.d.mts +18 -0
- package/dist/esm/core/logging/exports.mjs +9 -0
- package/dist/esm/core/logging/index.d.mts +1 -0
- package/dist/esm/core/logging/index.mjs +1 -0
- package/dist/esm/core/logging/logger.d.mts +126 -0
- package/dist/esm/core/logging/logger.mjs +138 -0
- package/dist/esm/exports.d.mts +1 -0
- package/dist/esm/exports.mjs +1 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +3 -2
- package/reference.md +1 -1
package/dist/cjs/BaseClient.d.ts
CHANGED
|
@@ -11,7 +11,11 @@ export interface BaseClientOptions {
|
|
|
11
11
|
timeoutInSeconds?: number;
|
|
12
12
|
/** The default number of times to retry the request. Defaults to 2. */
|
|
13
13
|
maxRetries?: number;
|
|
14
|
+
/** Provide a custom fetch implementation. Useful for platforms that don't have a built-in fetch or need a custom implementation. */
|
|
15
|
+
fetch?: typeof fetch;
|
|
14
16
|
fetcher?: core.FetchFunction;
|
|
17
|
+
/** Configure logging for the client. */
|
|
18
|
+
logging?: core.logging.LogConfig | core.logging.Logger;
|
|
15
19
|
}
|
|
16
20
|
export interface BaseRequestOptions {
|
|
17
21
|
/** The maximum time to wait for a response in seconds. */
|
package/dist/cjs/Client.js
CHANGED
|
@@ -49,10 +49,10 @@ const headers_js_1 = require("./core/headers.js");
|
|
|
49
49
|
const core = __importStar(require("./core/index.js"));
|
|
50
50
|
class phenomlClient {
|
|
51
51
|
constructor(_options) {
|
|
52
|
-
this._options = Object.assign(Object.assign({}, _options), { headers: (0, headers_js_1.mergeHeaders)({
|
|
52
|
+
this._options = Object.assign(Object.assign({}, _options), { logging: core.logging.createLogger(_options === null || _options === void 0 ? void 0 : _options.logging), headers: (0, headers_js_1.mergeHeaders)({
|
|
53
53
|
"X-Fern-Language": "JavaScript",
|
|
54
54
|
"X-Fern-SDK-Name": "phenoml",
|
|
55
|
-
"X-Fern-SDK-Version": "6.
|
|
55
|
+
"X-Fern-SDK-Version": "6.2.0",
|
|
56
56
|
"User-Agent": "phenoml/auto",
|
|
57
57
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
58
58
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
@@ -92,7 +92,7 @@ class Agent {
|
|
|
92
92
|
}
|
|
93
93
|
__create(request, requestOptions) {
|
|
94
94
|
return __awaiter(this, void 0, void 0, function* () {
|
|
95
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
95
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
96
96
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
97
97
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
98
98
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "agent/create"),
|
|
@@ -105,6 +105,8 @@ class Agent {
|
|
|
105
105
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
106
106
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
107
107
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
108
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
109
|
+
logging: this._options.logging,
|
|
108
110
|
});
|
|
109
111
|
if (_response.ok) {
|
|
110
112
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -164,7 +166,7 @@ class Agent {
|
|
|
164
166
|
}
|
|
165
167
|
__list() {
|
|
166
168
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
167
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
169
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
168
170
|
const { tags } = request;
|
|
169
171
|
const _queryParams = {};
|
|
170
172
|
if (tags != null) {
|
|
@@ -179,6 +181,8 @@ class Agent {
|
|
|
179
181
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
180
182
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
181
183
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
184
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
185
|
+
logging: this._options.logging,
|
|
182
186
|
});
|
|
183
187
|
if (_response.ok) {
|
|
184
188
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -235,7 +239,7 @@ class Agent {
|
|
|
235
239
|
}
|
|
236
240
|
__get(id, requestOptions) {
|
|
237
241
|
return __awaiter(this, void 0, void 0, function* () {
|
|
238
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
242
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
239
243
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
240
244
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
241
245
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/${core.url.encodePathParam(id)}`),
|
|
@@ -245,6 +249,8 @@ class Agent {
|
|
|
245
249
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
246
250
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
247
251
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
252
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
253
|
+
logging: this._options.logging,
|
|
248
254
|
});
|
|
249
255
|
if (_response.ok) {
|
|
250
256
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -309,7 +315,7 @@ class Agent {
|
|
|
309
315
|
}
|
|
310
316
|
__update(id, request, requestOptions) {
|
|
311
317
|
return __awaiter(this, void 0, void 0, function* () {
|
|
312
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
318
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
313
319
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
314
320
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
315
321
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/${core.url.encodePathParam(id)}`),
|
|
@@ -322,6 +328,8 @@ class Agent {
|
|
|
322
328
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
323
329
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
324
330
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
331
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
332
|
+
logging: this._options.logging,
|
|
325
333
|
});
|
|
326
334
|
if (_response.ok) {
|
|
327
335
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -382,7 +390,7 @@ class Agent {
|
|
|
382
390
|
}
|
|
383
391
|
__delete(id, requestOptions) {
|
|
384
392
|
return __awaiter(this, void 0, void 0, function* () {
|
|
385
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
393
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
386
394
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
387
395
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
388
396
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/${core.url.encodePathParam(id)}`),
|
|
@@ -392,6 +400,8 @@ class Agent {
|
|
|
392
400
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
393
401
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
394
402
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
403
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
404
|
+
logging: this._options.logging,
|
|
395
405
|
});
|
|
396
406
|
if (_response.ok) {
|
|
397
407
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -463,7 +473,7 @@ class Agent {
|
|
|
463
473
|
}
|
|
464
474
|
__patch(id, request, requestOptions) {
|
|
465
475
|
return __awaiter(this, void 0, void 0, function* () {
|
|
466
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
476
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
467
477
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
468
478
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
469
479
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/${core.url.encodePathParam(id)}`),
|
|
@@ -476,6 +486,8 @@ class Agent {
|
|
|
476
486
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
477
487
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
478
488
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
489
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
490
|
+
logging: this._options.logging,
|
|
479
491
|
});
|
|
480
492
|
if (_response.ok) {
|
|
481
493
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -541,7 +553,7 @@ class Agent {
|
|
|
541
553
|
}
|
|
542
554
|
__chat(request, requestOptions) {
|
|
543
555
|
return __awaiter(this, void 0, void 0, function* () {
|
|
544
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
556
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
545
557
|
const { "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider } = request, _body = __rest(request, ["X-Phenoml-On-Behalf-Of", "X-Phenoml-Fhir-Provider"]);
|
|
546
558
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
547
559
|
Authorization: yield this._getAuthorizationHeader(),
|
|
@@ -559,6 +571,8 @@ class Agent {
|
|
|
559
571
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
560
572
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
561
573
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
574
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
575
|
+
logging: this._options.logging,
|
|
562
576
|
});
|
|
563
577
|
if (_response.ok) {
|
|
564
578
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -621,7 +635,7 @@ class Agent {
|
|
|
621
635
|
}
|
|
622
636
|
__getChatMessages(request, requestOptions) {
|
|
623
637
|
return __awaiter(this, void 0, void 0, function* () {
|
|
624
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
638
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
625
639
|
const { chat_session_id: chatSessionId, num_messages: numMessages, role, order } = request;
|
|
626
640
|
const _queryParams = {};
|
|
627
641
|
_queryParams.chat_session_id = chatSessionId;
|
|
@@ -643,6 +657,8 @@ class Agent {
|
|
|
643
657
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
644
658
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
645
659
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
660
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
661
|
+
logging: this._options.logging,
|
|
646
662
|
});
|
|
647
663
|
if (_response.ok) {
|
|
648
664
|
return {
|
|
@@ -75,7 +75,7 @@ class Prompts {
|
|
|
75
75
|
}
|
|
76
76
|
__create(request, requestOptions) {
|
|
77
77
|
return __awaiter(this, void 0, void 0, function* () {
|
|
78
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
78
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
79
79
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
80
80
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
81
81
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "agent/prompts"),
|
|
@@ -88,6 +88,8 @@ class Prompts {
|
|
|
88
88
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
89
89
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
90
90
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
91
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
92
|
+
logging: this._options.logging,
|
|
91
93
|
});
|
|
92
94
|
if (_response.ok) {
|
|
93
95
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -144,7 +146,7 @@ class Prompts {
|
|
|
144
146
|
}
|
|
145
147
|
__list(requestOptions) {
|
|
146
148
|
return __awaiter(this, void 0, void 0, function* () {
|
|
147
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
149
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
148
150
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
149
151
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
150
152
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "agent/prompts/list"),
|
|
@@ -154,6 +156,8 @@ class Prompts {
|
|
|
154
156
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
155
157
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
156
158
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
159
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
160
|
+
logging: this._options.logging,
|
|
157
161
|
});
|
|
158
162
|
if (_response.ok) {
|
|
159
163
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -210,7 +214,7 @@ class Prompts {
|
|
|
210
214
|
}
|
|
211
215
|
__get(id, requestOptions) {
|
|
212
216
|
return __awaiter(this, void 0, void 0, function* () {
|
|
213
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
217
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
214
218
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
215
219
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
216
220
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/prompts/${core.url.encodePathParam(id)}`),
|
|
@@ -220,6 +224,8 @@ class Prompts {
|
|
|
220
224
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
221
225
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
222
226
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
227
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
228
|
+
logging: this._options.logging,
|
|
223
229
|
});
|
|
224
230
|
if (_response.ok) {
|
|
225
231
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -280,7 +286,7 @@ class Prompts {
|
|
|
280
286
|
}
|
|
281
287
|
__update(id_1) {
|
|
282
288
|
return __awaiter(this, arguments, void 0, function* (id, request = {}, requestOptions) {
|
|
283
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
289
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
284
290
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
285
291
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
286
292
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/prompts/${core.url.encodePathParam(id)}`),
|
|
@@ -293,6 +299,8 @@ class Prompts {
|
|
|
293
299
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
294
300
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
295
301
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
302
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
303
|
+
logging: this._options.logging,
|
|
296
304
|
});
|
|
297
305
|
if (_response.ok) {
|
|
298
306
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -353,7 +361,7 @@ class Prompts {
|
|
|
353
361
|
}
|
|
354
362
|
__delete(id, requestOptions) {
|
|
355
363
|
return __awaiter(this, void 0, void 0, function* () {
|
|
356
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
364
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
357
365
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
358
366
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
359
367
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/prompts/${core.url.encodePathParam(id)}`),
|
|
@@ -363,6 +371,8 @@ class Prompts {
|
|
|
363
371
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
364
372
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
365
373
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
374
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
375
|
+
logging: this._options.logging,
|
|
366
376
|
});
|
|
367
377
|
if (_response.ok) {
|
|
368
378
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -434,7 +444,7 @@ class Prompts {
|
|
|
434
444
|
}
|
|
435
445
|
__patch(id, request, requestOptions) {
|
|
436
446
|
return __awaiter(this, void 0, void 0, function* () {
|
|
437
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
447
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
438
448
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
439
449
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
440
450
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, `agent/prompts/${core.url.encodePathParam(id)}`),
|
|
@@ -447,6 +457,8 @@ class Prompts {
|
|
|
447
457
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
448
458
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
449
459
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
460
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
461
|
+
logging: this._options.logging,
|
|
450
462
|
});
|
|
451
463
|
if (_response.ok) {
|
|
452
464
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -505,7 +517,7 @@ class Prompts {
|
|
|
505
517
|
}
|
|
506
518
|
__loadDefaults(requestOptions) {
|
|
507
519
|
return __awaiter(this, void 0, void 0, function* () {
|
|
508
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
520
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
509
521
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
510
522
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
511
523
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "agent/prompts/load-defaults"),
|
|
@@ -515,6 +527,8 @@ class Prompts {
|
|
|
515
527
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
516
528
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
517
529
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
530
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
531
|
+
logging: this._options.logging,
|
|
518
532
|
});
|
|
519
533
|
if (_response.ok) {
|
|
520
534
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -73,7 +73,7 @@ class Cohort {
|
|
|
73
73
|
}
|
|
74
74
|
__analyze(request, requestOptions) {
|
|
75
75
|
return __awaiter(this, void 0, void 0, function* () {
|
|
76
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
76
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
77
77
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
78
78
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
79
79
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "cohort"),
|
|
@@ -86,6 +86,8 @@ class Cohort {
|
|
|
86
86
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
87
87
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
88
88
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
89
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
90
|
+
logging: this._options.logging,
|
|
89
91
|
});
|
|
90
92
|
if (_response.ok) {
|
|
91
93
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -81,7 +81,7 @@ class Construe {
|
|
|
81
81
|
}
|
|
82
82
|
__uploadCodeSystem(request, requestOptions) {
|
|
83
83
|
return __awaiter(this, void 0, void 0, function* () {
|
|
84
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
84
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
85
85
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
86
86
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
87
87
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "construe/upload"),
|
|
@@ -94,6 +94,8 @@ class Construe {
|
|
|
94
94
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
95
95
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
96
96
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
97
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
98
|
+
logging: this._options.logging,
|
|
97
99
|
});
|
|
98
100
|
if (_response.ok) {
|
|
99
101
|
return {
|
|
@@ -165,7 +167,7 @@ class Construe {
|
|
|
165
167
|
}
|
|
166
168
|
__extractCodes(request, requestOptions) {
|
|
167
169
|
return __awaiter(this, void 0, void 0, function* () {
|
|
168
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
170
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
169
171
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
170
172
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
171
173
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "construe/extract"),
|
|
@@ -178,6 +180,8 @@ class Construe {
|
|
|
178
180
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
179
181
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
180
182
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
183
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
184
|
+
logging: this._options.logging,
|
|
181
185
|
});
|
|
182
186
|
if (_response.ok) {
|
|
183
187
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -237,7 +241,7 @@ class Construe {
|
|
|
237
241
|
}
|
|
238
242
|
__listAvailableCodeSystems(requestOptions) {
|
|
239
243
|
return __awaiter(this, void 0, void 0, function* () {
|
|
240
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
244
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
241
245
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
242
246
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
243
247
|
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.phenomlEnvironment.Default, "construe/codes/systems"),
|
|
@@ -247,6 +251,8 @@ class Construe {
|
|
|
247
251
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
248
252
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
249
253
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
254
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
255
|
+
logging: this._options.logging,
|
|
250
256
|
});
|
|
251
257
|
if (_response.ok) {
|
|
252
258
|
return {
|
|
@@ -307,7 +313,7 @@ class Construe {
|
|
|
307
313
|
}
|
|
308
314
|
__getCodeSystemDetail(codesystem_1) {
|
|
309
315
|
return __awaiter(this, arguments, void 0, function* (codesystem, request = {}, requestOptions) {
|
|
310
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
316
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
311
317
|
const { version } = request;
|
|
312
318
|
const _queryParams = {};
|
|
313
319
|
if (version != null) {
|
|
@@ -322,6 +328,8 @@ class Construe {
|
|
|
322
328
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
323
329
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
324
330
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
331
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
332
|
+
logging: this._options.logging,
|
|
325
333
|
});
|
|
326
334
|
if (_response.ok) {
|
|
327
335
|
return {
|
|
@@ -388,7 +396,7 @@ class Construe {
|
|
|
388
396
|
}
|
|
389
397
|
__deleteCustomCodeSystem(codesystem_1) {
|
|
390
398
|
return __awaiter(this, arguments, void 0, function* (codesystem, request = {}, requestOptions) {
|
|
391
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
399
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
392
400
|
const { version } = request;
|
|
393
401
|
const _queryParams = {};
|
|
394
402
|
if (version != null) {
|
|
@@ -403,6 +411,8 @@ class Construe {
|
|
|
403
411
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
404
412
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
405
413
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
414
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
415
|
+
logging: this._options.logging,
|
|
406
416
|
});
|
|
407
417
|
if (_response.ok) {
|
|
408
418
|
return {
|
|
@@ -474,7 +484,7 @@ class Construe {
|
|
|
474
484
|
}
|
|
475
485
|
__exportCustomCodeSystem(codesystem_1) {
|
|
476
486
|
return __awaiter(this, arguments, void 0, function* (codesystem, request = {}, requestOptions) {
|
|
477
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
487
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
478
488
|
const { version } = request;
|
|
479
489
|
const _queryParams = {};
|
|
480
490
|
if (version != null) {
|
|
@@ -489,6 +499,8 @@ class Construe {
|
|
|
489
499
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
490
500
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
491
501
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
502
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
503
|
+
logging: this._options.logging,
|
|
492
504
|
});
|
|
493
505
|
if (_response.ok) {
|
|
494
506
|
return {
|
|
@@ -563,7 +575,7 @@ class Construe {
|
|
|
563
575
|
}
|
|
564
576
|
__listCodesInACodeSystem(codesystem_1) {
|
|
565
577
|
return __awaiter(this, arguments, void 0, function* (codesystem, request = {}, requestOptions) {
|
|
566
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
578
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
567
579
|
const { version, cursor, limit } = request;
|
|
568
580
|
const _queryParams = {};
|
|
569
581
|
if (version != null) {
|
|
@@ -584,6 +596,8 @@ class Construe {
|
|
|
584
596
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
585
597
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
586
598
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
599
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
600
|
+
logging: this._options.logging,
|
|
587
601
|
});
|
|
588
602
|
if (_response.ok) {
|
|
589
603
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -648,7 +662,7 @@ class Construe {
|
|
|
648
662
|
}
|
|
649
663
|
__getASpecificCode(codesystem_1, codeId_1) {
|
|
650
664
|
return __awaiter(this, arguments, void 0, function* (codesystem, codeId, request = {}, requestOptions) {
|
|
651
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
665
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
652
666
|
const { version } = request;
|
|
653
667
|
const _queryParams = {};
|
|
654
668
|
if (version != null) {
|
|
@@ -663,6 +677,8 @@ class Construe {
|
|
|
663
677
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
664
678
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
665
679
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
680
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
681
|
+
logging: this._options.logging,
|
|
666
682
|
});
|
|
667
683
|
if (_response.ok) {
|
|
668
684
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -744,7 +760,7 @@ class Construe {
|
|
|
744
760
|
}
|
|
745
761
|
__semanticSearchEmbeddingBased(codesystem, request, requestOptions) {
|
|
746
762
|
return __awaiter(this, void 0, void 0, function* () {
|
|
747
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
763
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
748
764
|
const { text, version, limit } = request;
|
|
749
765
|
const _queryParams = {};
|
|
750
766
|
_queryParams.text = text;
|
|
@@ -763,6 +779,8 @@ class Construe {
|
|
|
763
779
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
764
780
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
765
781
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
782
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
783
|
+
logging: this._options.logging,
|
|
766
784
|
});
|
|
767
785
|
if (_response.ok) {
|
|
768
786
|
return {
|
|
@@ -853,7 +871,7 @@ class Construe {
|
|
|
853
871
|
}
|
|
854
872
|
__terminologyServerTextSearch(codesystem, request, requestOptions) {
|
|
855
873
|
return __awaiter(this, void 0, void 0, function* () {
|
|
856
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
874
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
857
875
|
const { q, version, limit } = request;
|
|
858
876
|
const _queryParams = {};
|
|
859
877
|
_queryParams.q = q;
|
|
@@ -872,6 +890,8 @@ class Construe {
|
|
|
872
890
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
873
891
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
874
892
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
893
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
894
|
+
logging: this._options.logging,
|
|
875
895
|
});
|
|
876
896
|
if (_response.ok) {
|
|
877
897
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -87,7 +87,7 @@ class Fhir {
|
|
|
87
87
|
}
|
|
88
88
|
__search(fhirProviderId_1, fhirPath_1) {
|
|
89
89
|
return __awaiter(this, arguments, void 0, function* (fhirProviderId, fhirPath, request = {}, requestOptions) {
|
|
90
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
90
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
91
91
|
const { query_parameters: queryParameters, "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider, } = request;
|
|
92
92
|
const _queryParams = {};
|
|
93
93
|
if (queryParameters != null) {
|
|
@@ -106,6 +106,8 @@ class Fhir {
|
|
|
106
106
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
107
107
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
108
108
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
109
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
110
|
+
logging: this._options.logging,
|
|
109
111
|
});
|
|
110
112
|
if (_response.ok) {
|
|
111
113
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -192,7 +194,7 @@ class Fhir {
|
|
|
192
194
|
}
|
|
193
195
|
__create(fhirProviderId, fhirPath, request, requestOptions) {
|
|
194
196
|
return __awaiter(this, void 0, void 0, function* () {
|
|
195
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
197
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
196
198
|
const { "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider, body: _body, } = request;
|
|
197
199
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
198
200
|
Authorization: yield this._getAuthorizationHeader(),
|
|
@@ -210,6 +212,8 @@ class Fhir {
|
|
|
210
212
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
211
213
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
212
214
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
215
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
216
|
+
logging: this._options.logging,
|
|
213
217
|
});
|
|
214
218
|
if (_response.ok) {
|
|
215
219
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -296,7 +300,7 @@ class Fhir {
|
|
|
296
300
|
}
|
|
297
301
|
__upsert(fhirProviderId, fhirPath, request, requestOptions) {
|
|
298
302
|
return __awaiter(this, void 0, void 0, function* () {
|
|
299
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
303
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
300
304
|
const { "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider, body: _body, } = request;
|
|
301
305
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
302
306
|
Authorization: yield this._getAuthorizationHeader(),
|
|
@@ -314,6 +318,8 @@ class Fhir {
|
|
|
314
318
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
315
319
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
316
320
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
321
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
322
|
+
logging: this._options.logging,
|
|
317
323
|
});
|
|
318
324
|
if (_response.ok) {
|
|
319
325
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -386,7 +392,7 @@ class Fhir {
|
|
|
386
392
|
}
|
|
387
393
|
__delete(fhirProviderId_1, fhirPath_1) {
|
|
388
394
|
return __awaiter(this, arguments, void 0, function* (fhirProviderId, fhirPath, request = {}, requestOptions) {
|
|
389
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
395
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
390
396
|
const { "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider } = request;
|
|
391
397
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
392
398
|
Authorization: yield this._getAuthorizationHeader(),
|
|
@@ -401,6 +407,8 @@ class Fhir {
|
|
|
401
407
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
402
408
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
403
409
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
410
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
411
|
+
logging: this._options.logging,
|
|
404
412
|
});
|
|
405
413
|
if (_response.ok) {
|
|
406
414
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -536,7 +544,7 @@ class Fhir {
|
|
|
536
544
|
}
|
|
537
545
|
__patch(fhirProviderId, fhirPath, request, requestOptions) {
|
|
538
546
|
return __awaiter(this, void 0, void 0, function* () {
|
|
539
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
547
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
540
548
|
const { "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider, body: _body, } = request;
|
|
541
549
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
542
550
|
Authorization: yield this._getAuthorizationHeader(),
|
|
@@ -554,6 +562,8 @@ class Fhir {
|
|
|
554
562
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
555
563
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
556
564
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
565
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
566
|
+
logging: this._options.logging,
|
|
557
567
|
});
|
|
558
568
|
if (_response.ok) {
|
|
559
569
|
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
@@ -656,7 +666,7 @@ class Fhir {
|
|
|
656
666
|
}
|
|
657
667
|
__executeBundle(fhirProviderId, request, requestOptions) {
|
|
658
668
|
return __awaiter(this, void 0, void 0, function* () {
|
|
659
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
669
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
660
670
|
const { "X-Phenoml-On-Behalf-Of": phenomlOnBehalfOf, "X-Phenoml-Fhir-Provider": phenomlFhirProvider, body: _body, } = request;
|
|
661
671
|
const _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({
|
|
662
672
|
Authorization: yield this._getAuthorizationHeader(),
|
|
@@ -674,6 +684,8 @@ class Fhir {
|
|
|
674
684
|
timeoutMs: ((_g = (_e = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _e !== void 0 ? _e : (_f = this._options) === null || _f === void 0 ? void 0 : _f.timeoutInSeconds) !== null && _g !== void 0 ? _g : 60) * 1000,
|
|
675
685
|
maxRetries: (_h = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _h !== void 0 ? _h : (_j = this._options) === null || _j === void 0 ? void 0 : _j.maxRetries,
|
|
676
686
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
687
|
+
fetchFn: (_k = this._options) === null || _k === void 0 ? void 0 : _k.fetch,
|
|
688
|
+
logging: this._options.logging,
|
|
677
689
|
});
|
|
678
690
|
if (_response.ok) {
|
|
679
691
|
return { data: _response.body, rawResponse: _response.rawResponse };
|