@tryvital/vital-node 3.0.2 → 3.0.4
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/Client.d.ts +3 -0
- package/Client.js +11 -6
- package/api/resources/activity/client/Client.js +2 -2
- package/api/resources/body/client/Client.js +2 -2
- package/api/resources/devices/client/Client.js +1 -1
- package/api/resources/index.d.ts +2 -0
- package/api/resources/index.js +3 -1
- package/api/resources/insurance/client/Client.js +2 -2
- package/api/resources/introspect/client/Client.d.ts +23 -0
- package/api/resources/introspect/client/Client.js +126 -0
- package/api/resources/introspect/client/index.d.ts +1 -0
- package/api/resources/introspect/client/index.js +17 -0
- package/api/resources/introspect/client/requests/IntrospectGetUserResourcesRequest.d.ts +10 -0
- package/api/resources/introspect/client/requests/index.d.ts +1 -0
- package/api/resources/introspect/client/requests/index.js +2 -0
- package/api/resources/introspect/index.d.ts +1 -0
- package/api/resources/introspect/index.js +17 -0
- package/api/resources/labTests/client/Client.d.ts +6 -1
- package/api/resources/labTests/client/Client.js +93 -24
- package/api/resources/labTests/client/requests/LabTestsGetMarkersRequest.d.ts +1 -1
- package/api/resources/labTests/client/requests/LabTestsSimulateOrderProcessRequest.d.ts +8 -0
- package/api/resources/labTests/client/requests/index.d.ts +1 -0
- package/api/resources/link/client/Client.js +14 -14
- package/api/resources/meal/client/Client.js +1 -1
- package/api/resources/profile/client/Client.js +2 -2
- package/api/resources/providers/client/Client.js +1 -1
- package/api/resources/sleep/client/Client.js +4 -4
- package/api/resources/team/client/Client.d.ts +4 -0
- package/api/resources/team/client/Client.js +63 -6
- package/api/resources/testkit/client/Client.js +2 -2
- package/api/resources/user/client/Client.d.ts +2 -2
- package/api/resources/user/client/Client.js +23 -23
- package/api/resources/vitals/client/Client.js +23 -23
- package/api/resources/workouts/client/Client.js +3 -3
- package/api/types/ActivityV2InDb.d.ts +1 -1
- package/api/types/AttemptStatus.d.ts +11 -0
- package/api/types/AttemptStatus.js +10 -0
- package/api/types/BodyV2InDb.d.ts +1 -1
- package/api/types/ClientFacingLabTest.d.ts +2 -0
- package/api/types/ClientFacingOrder.d.ts +1 -1
- package/api/types/{PhysicianClientFacing.d.ts → ClientFacingPhysician.d.ts} +1 -1
- package/api/types/ClientFacingPhysician.js +5 -0
- package/api/types/ClientFacingTeam.d.ts +1 -0
- package/api/types/DelegatedFlowType.d.ts +12 -0
- package/api/types/DelegatedFlowType.js +11 -0
- package/api/types/EventDestinationPreferences.d.ts +8 -0
- package/api/types/EventDestinationPreferences.js +5 -0
- package/api/types/EventDestinationPreferencesEnabledItem.d.ts +9 -0
- package/api/types/EventDestinationPreferencesEnabledItem.js +11 -0
- package/api/types/EventDestinationPreferencesPreferred.d.ts +9 -0
- package/api/types/EventDestinationPreferencesPreferred.js +11 -0
- package/api/types/GetMarkersResponse.d.ts +4 -3
- package/api/types/GetOrdersResponse.d.ts +3 -3
- package/api/types/LabTestStatus.d.ts +12 -0
- package/api/types/LabTestStatus.js +11 -0
- package/api/types/LastAttempt.d.ts +8 -0
- package/api/types/LastAttempt.js +5 -0
- package/api/types/PatientAddressCompatible.d.ts +2 -2
- package/api/types/SingleResourceStatistics.d.ts +10 -0
- package/api/types/SingleResourceStatistics.js +5 -0
- package/api/types/SingleUserResourceResponse.d.ts +6 -0
- package/api/types/SingleUserResourceResponse.js +5 -0
- package/api/types/SleepV2InDb.d.ts +1 -1
- package/api/types/TeamConfig.d.ts +3 -0
- package/api/types/UserResourcesResponse.d.ts +8 -0
- package/api/types/UserResourcesResponse.js +5 -0
- package/api/types/WorkoutV2InDb.d.ts +1 -1
- package/api/types/index.d.ts +11 -1
- package/api/types/index.js +11 -1
- package/dist/Client.d.ts +3 -0
- package/dist/Client.js +11 -6
- package/dist/api/resources/activity/client/Client.js +2 -2
- package/dist/api/resources/body/client/Client.js +2 -2
- package/dist/api/resources/devices/client/Client.js +1 -1
- package/dist/api/resources/index.d.ts +2 -0
- package/dist/api/resources/index.js +3 -1
- package/dist/api/resources/insurance/client/Client.js +2 -2
- package/dist/api/resources/introspect/client/Client.d.ts +23 -0
- package/dist/api/resources/introspect/client/Client.js +126 -0
- package/dist/api/resources/introspect/client/index.d.ts +1 -0
- package/dist/api/resources/introspect/client/index.js +17 -0
- package/dist/api/resources/introspect/client/requests/IntrospectGetUserResourcesRequest.d.ts +10 -0
- package/dist/api/resources/introspect/client/requests/IntrospectGetUserResourcesRequest.js +5 -0
- package/dist/api/resources/introspect/client/requests/index.d.ts +1 -0
- package/dist/api/resources/introspect/client/requests/index.js +2 -0
- package/dist/api/resources/introspect/index.d.ts +1 -0
- package/dist/api/resources/introspect/index.js +17 -0
- package/dist/api/resources/labTests/client/Client.d.ts +6 -1
- package/dist/api/resources/labTests/client/Client.js +93 -24
- package/dist/api/resources/labTests/client/requests/LabTestsGetMarkersRequest.d.ts +1 -1
- package/dist/api/resources/labTests/client/requests/LabTestsSimulateOrderProcessRequest.d.ts +8 -0
- package/dist/api/resources/labTests/client/requests/LabTestsSimulateOrderProcessRequest.js +5 -0
- package/dist/api/resources/labTests/client/requests/index.d.ts +1 -0
- package/dist/api/resources/link/client/Client.js +14 -14
- package/dist/api/resources/meal/client/Client.js +1 -1
- package/dist/api/resources/profile/client/Client.js +2 -2
- package/dist/api/resources/providers/client/Client.js +1 -1
- package/dist/api/resources/sleep/client/Client.js +4 -4
- package/dist/api/resources/team/client/Client.d.ts +4 -0
- package/dist/api/resources/team/client/Client.js +63 -6
- package/dist/api/resources/testkit/client/Client.js +2 -2
- package/dist/api/resources/user/client/Client.d.ts +2 -2
- package/dist/api/resources/user/client/Client.js +23 -23
- package/dist/api/resources/vitals/client/Client.js +23 -23
- package/dist/api/resources/workouts/client/Client.js +3 -3
- package/dist/api/types/ActivityV2InDb.d.ts +1 -1
- package/dist/api/types/AttemptStatus.d.ts +11 -0
- package/dist/api/types/AttemptStatus.js +10 -0
- package/dist/api/types/BodyV2InDb.d.ts +1 -1
- package/dist/api/types/ClientFacingLabTest.d.ts +2 -0
- package/dist/api/types/ClientFacingOrder.d.ts +1 -1
- package/dist/api/types/{PhysicianClientFacing.d.ts → ClientFacingPhysician.d.ts} +1 -1
- package/dist/api/types/ClientFacingPhysician.js +5 -0
- package/dist/api/types/ClientFacingTeam.d.ts +1 -0
- package/dist/api/types/DelegatedFlowType.d.ts +12 -0
- package/dist/api/types/DelegatedFlowType.js +11 -0
- package/dist/api/types/EventDestinationPreferences.d.ts +8 -0
- package/dist/api/types/EventDestinationPreferences.js +5 -0
- package/dist/api/types/EventDestinationPreferencesEnabledItem.d.ts +9 -0
- package/dist/api/types/EventDestinationPreferencesEnabledItem.js +11 -0
- package/dist/api/types/EventDestinationPreferencesPreferred.d.ts +9 -0
- package/dist/api/types/EventDestinationPreferencesPreferred.js +11 -0
- package/dist/api/types/GetMarkersResponse.d.ts +4 -3
- package/dist/api/types/GetOrdersResponse.d.ts +3 -3
- package/dist/api/types/LabTestStatus.d.ts +12 -0
- package/dist/api/types/LabTestStatus.js +11 -0
- package/dist/api/types/LastAttempt.d.ts +8 -0
- package/dist/api/types/LastAttempt.js +5 -0
- package/dist/api/types/PatientAddressCompatible.d.ts +2 -2
- package/dist/api/types/SingleResourceStatistics.d.ts +10 -0
- package/dist/api/types/SingleResourceStatistics.js +5 -0
- package/dist/api/types/SingleUserResourceResponse.d.ts +6 -0
- package/dist/api/types/SingleUserResourceResponse.js +5 -0
- package/dist/api/types/SleepV2InDb.d.ts +1 -1
- package/dist/api/types/TeamConfig.d.ts +3 -0
- package/dist/api/types/UserResourcesResponse.d.ts +8 -0
- package/dist/api/types/UserResourcesResponse.js +5 -0
- package/dist/api/types/WorkoutV2InDb.d.ts +1 -1
- package/dist/api/types/index.d.ts +11 -1
- package/dist/api/types/index.js +11 -1
- package/dist/serialization/resources/team/client/getPhysicians.d.ts +10 -0
- package/dist/serialization/resources/team/client/getPhysicians.js +40 -0
- package/dist/serialization/resources/team/client/index.d.ts +1 -0
- package/dist/serialization/resources/team/client/index.js +2 -1
- package/dist/serialization/types/ActivityV2InDb.d.ts +1 -1
- package/dist/serialization/types/ActivityV2InDb.js +1 -1
- package/dist/serialization/types/AttemptStatus.d.ts +10 -0
- package/dist/serialization/types/AttemptStatus.js +31 -0
- package/dist/serialization/types/BodyV2InDb.d.ts +1 -1
- package/dist/serialization/types/BodyV2InDb.js +1 -1
- package/dist/serialization/types/ClientFacingLabTest.d.ts +1 -0
- package/dist/serialization/types/ClientFacingLabTest.js +1 -0
- package/dist/serialization/types/ClientFacingOrder.d.ts +1 -1
- package/dist/serialization/types/ClientFacingOrder.js +1 -1
- package/dist/serialization/types/{PhysicianClientFacing.d.ts → ClientFacingPhysician.d.ts} +2 -2
- package/dist/serialization/types/{PhysicianClientFacing.js → ClientFacingPhysician.js} +2 -2
- package/dist/serialization/types/ClientFacingTeam.d.ts +1 -0
- package/dist/serialization/types/ClientFacingTeam.js +1 -0
- package/dist/serialization/types/DelegatedFlowType.d.ts +10 -0
- package/dist/serialization/types/DelegatedFlowType.js +35 -0
- package/dist/serialization/types/EventDestinationPreferences.d.ts +13 -0
- package/dist/serialization/types/EventDestinationPreferences.js +43 -0
- package/dist/serialization/types/EventDestinationPreferencesEnabledItem.d.ts +10 -0
- package/dist/serialization/types/EventDestinationPreferencesEnabledItem.js +31 -0
- package/dist/serialization/types/EventDestinationPreferencesPreferred.d.ts +10 -0
- package/dist/serialization/types/EventDestinationPreferencesPreferred.js +31 -0
- package/dist/serialization/types/GetMarkersResponse.d.ts +4 -3
- package/dist/serialization/types/GetMarkersResponse.js +4 -3
- package/dist/serialization/types/GetOrdersResponse.d.ts +3 -3
- package/dist/serialization/types/GetOrdersResponse.js +3 -3
- package/dist/serialization/types/LabTestStatus.d.ts +10 -0
- package/dist/serialization/types/LabTestStatus.js +31 -0
- package/dist/serialization/types/LastAttempt.d.ts +13 -0
- package/dist/serialization/types/LastAttempt.js +43 -0
- package/dist/serialization/types/PatientAddressCompatible.d.ts +2 -2
- package/dist/serialization/types/PatientAddressCompatible.js +2 -2
- package/dist/serialization/types/SingleResourceStatistics.d.ts +15 -0
- package/dist/serialization/types/SingleResourceStatistics.js +45 -0
- package/dist/serialization/types/SingleUserResourceResponse.d.ts +12 -0
- package/dist/serialization/types/SingleUserResourceResponse.js +33 -0
- package/dist/serialization/types/SleepV2InDb.d.ts +1 -1
- package/dist/serialization/types/SleepV2InDb.js +1 -1
- package/dist/serialization/types/TeamConfig.d.ts +3 -0
- package/dist/serialization/types/TeamConfig.js +3 -0
- package/dist/serialization/types/UserResourcesResponse.d.ts +13 -0
- package/dist/serialization/types/UserResourcesResponse.js +43 -0
- package/dist/serialization/types/WorkoutV2InDb.d.ts +1 -1
- package/dist/serialization/types/WorkoutV2InDb.js +1 -1
- package/dist/serialization/types/index.d.ts +11 -1
- package/dist/serialization/types/index.js +11 -1
- package/package.json +1 -1
- package/serialization/resources/team/client/getPhysicians.d.ts +10 -0
- package/serialization/resources/team/client/getPhysicians.js +40 -0
- package/serialization/resources/team/client/index.d.ts +1 -0
- package/serialization/resources/team/client/index.js +2 -1
- package/serialization/types/ActivityV2InDb.d.ts +1 -1
- package/serialization/types/ActivityV2InDb.js +1 -1
- package/serialization/types/AttemptStatus.d.ts +10 -0
- package/serialization/types/AttemptStatus.js +31 -0
- package/serialization/types/BodyV2InDb.d.ts +1 -1
- package/serialization/types/BodyV2InDb.js +1 -1
- package/serialization/types/ClientFacingLabTest.d.ts +1 -0
- package/serialization/types/ClientFacingLabTest.js +1 -0
- package/serialization/types/ClientFacingOrder.d.ts +1 -1
- package/serialization/types/ClientFacingOrder.js +1 -1
- package/serialization/types/{PhysicianClientFacing.d.ts → ClientFacingPhysician.d.ts} +2 -2
- package/serialization/types/{PhysicianClientFacing.js → ClientFacingPhysician.js} +2 -2
- package/serialization/types/ClientFacingTeam.d.ts +1 -0
- package/serialization/types/ClientFacingTeam.js +1 -0
- package/serialization/types/DelegatedFlowType.d.ts +10 -0
- package/serialization/types/DelegatedFlowType.js +35 -0
- package/serialization/types/EventDestinationPreferences.d.ts +13 -0
- package/serialization/types/EventDestinationPreferences.js +43 -0
- package/serialization/types/EventDestinationPreferencesEnabledItem.d.ts +10 -0
- package/serialization/types/EventDestinationPreferencesEnabledItem.js +31 -0
- package/serialization/types/EventDestinationPreferencesPreferred.d.ts +10 -0
- package/serialization/types/EventDestinationPreferencesPreferred.js +31 -0
- package/serialization/types/GetMarkersResponse.d.ts +4 -3
- package/serialization/types/GetMarkersResponse.js +4 -3
- package/serialization/types/GetOrdersResponse.d.ts +3 -3
- package/serialization/types/GetOrdersResponse.js +3 -3
- package/serialization/types/LabTestStatus.d.ts +10 -0
- package/serialization/types/LabTestStatus.js +31 -0
- package/serialization/types/LastAttempt.d.ts +13 -0
- package/serialization/types/LastAttempt.js +43 -0
- package/serialization/types/PatientAddressCompatible.d.ts +2 -2
- package/serialization/types/PatientAddressCompatible.js +2 -2
- package/serialization/types/SingleResourceStatistics.d.ts +15 -0
- package/serialization/types/SingleResourceStatistics.js +45 -0
- package/serialization/types/SingleUserResourceResponse.d.ts +12 -0
- package/serialization/types/SingleUserResourceResponse.js +33 -0
- package/serialization/types/SleepV2InDb.d.ts +1 -1
- package/serialization/types/SleepV2InDb.js +1 -1
- package/serialization/types/TeamConfig.d.ts +3 -0
- package/serialization/types/TeamConfig.js +3 -0
- package/serialization/types/UserResourcesResponse.d.ts +13 -0
- package/serialization/types/UserResourcesResponse.js +43 -0
- package/serialization/types/WorkoutV2InDb.d.ts +1 -1
- package/serialization/types/WorkoutV2InDb.js +1 -1
- package/serialization/types/index.d.ts +11 -1
- package/serialization/types/index.js +11 -1
- /package/api/{types/PhysicianClientFacing.js → resources/introspect/client/requests/IntrospectGetUserResourcesRequest.js} +0 -0
- /package/{dist/api/types/PhysicianClientFacing.js → api/resources/labTests/client/requests/LabTestsSimulateOrderProcessRequest.js} +0 -0
@@ -63,7 +63,7 @@ class LabTests {
|
|
63
63
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
64
64
|
"X-Fern-Language": "JavaScript",
|
65
65
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
66
|
-
"X-Fern-SDK-Version": "3.0.
|
66
|
+
"X-Fern-SDK-Version": "3.0.4",
|
67
67
|
},
|
68
68
|
contentType: "application/json",
|
69
69
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -110,7 +110,7 @@ class LabTests {
|
|
110
110
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
111
111
|
"X-Fern-Language": "JavaScript",
|
112
112
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
113
|
-
"X-Fern-SDK-Version": "3.0.
|
113
|
+
"X-Fern-SDK-Version": "3.0.4",
|
114
114
|
},
|
115
115
|
contentType: "application/json",
|
116
116
|
body: yield serializers.CreateLabTestRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -165,7 +165,14 @@ class LabTests {
|
|
165
165
|
const { labId, name, page, size } = request;
|
166
166
|
const _queryParams = new url_search_params_1.default();
|
167
167
|
if (labId != null) {
|
168
|
-
|
168
|
+
if (Array.isArray(labId)) {
|
169
|
+
for (const _item of labId) {
|
170
|
+
_queryParams.append("lab_id", _item.toString());
|
171
|
+
}
|
172
|
+
}
|
173
|
+
else {
|
174
|
+
_queryParams.append("lab_id", labId.toString());
|
175
|
+
}
|
169
176
|
}
|
170
177
|
if (name != null) {
|
171
178
|
_queryParams.append("name", name);
|
@@ -183,7 +190,7 @@ class LabTests {
|
|
183
190
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
184
191
|
"X-Fern-Language": "JavaScript",
|
185
192
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
186
|
-
"X-Fern-SDK-Version": "3.0.
|
193
|
+
"X-Fern-SDK-Version": "3.0.4",
|
187
194
|
},
|
188
195
|
contentType: "application/json",
|
189
196
|
queryParameters: _queryParams,
|
@@ -249,7 +256,7 @@ class LabTests {
|
|
249
256
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
250
257
|
"X-Fern-Language": "JavaScript",
|
251
258
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
252
|
-
"X-Fern-SDK-Version": "3.0.
|
259
|
+
"X-Fern-SDK-Version": "3.0.4",
|
253
260
|
},
|
254
261
|
contentType: "application/json",
|
255
262
|
queryParameters: _queryParams,
|
@@ -308,7 +315,7 @@ class LabTests {
|
|
308
315
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
309
316
|
"X-Fern-Language": "JavaScript",
|
310
317
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
311
|
-
"X-Fern-SDK-Version": "3.0.
|
318
|
+
"X-Fern-SDK-Version": "3.0.4",
|
312
319
|
},
|
313
320
|
contentType: "application/json",
|
314
321
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -365,7 +372,7 @@ class LabTests {
|
|
365
372
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
366
373
|
"X-Fern-Language": "JavaScript",
|
367
374
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
368
|
-
"X-Fern-SDK-Version": "3.0.
|
375
|
+
"X-Fern-SDK-Version": "3.0.4",
|
369
376
|
},
|
370
377
|
contentType: "application/json",
|
371
378
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -413,7 +420,7 @@ class LabTests {
|
|
413
420
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
414
421
|
"X-Fern-Language": "JavaScript",
|
415
422
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
416
|
-
"X-Fern-SDK-Version": "3.0.
|
423
|
+
"X-Fern-SDK-Version": "3.0.4",
|
417
424
|
},
|
418
425
|
contentType: "application/json",
|
419
426
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -472,7 +479,7 @@ class LabTests {
|
|
472
479
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
473
480
|
"X-Fern-Language": "JavaScript",
|
474
481
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
475
|
-
"X-Fern-SDK-Version": "3.0.
|
482
|
+
"X-Fern-SDK-Version": "3.0.4",
|
476
483
|
},
|
477
484
|
contentType: "application/json",
|
478
485
|
body: yield serializers.UsAddress.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -531,7 +538,7 @@ class LabTests {
|
|
531
538
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
532
539
|
"X-Fern-Language": "JavaScript",
|
533
540
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
534
|
-
"X-Fern-SDK-Version": "3.0.
|
541
|
+
"X-Fern-SDK-Version": "3.0.4",
|
535
542
|
},
|
536
543
|
contentType: "application/json",
|
537
544
|
body: yield serializers.AppointmentBookingRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -590,7 +597,7 @@ class LabTests {
|
|
590
597
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
591
598
|
"X-Fern-Language": "JavaScript",
|
592
599
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
593
|
-
"X-Fern-SDK-Version": "3.0.
|
600
|
+
"X-Fern-SDK-Version": "3.0.4",
|
594
601
|
},
|
595
602
|
contentType: "application/json",
|
596
603
|
body: yield serializers.AppointmentRescheduleRequest.jsonOrThrow(request, {
|
@@ -641,7 +648,7 @@ class LabTests {
|
|
641
648
|
* Cancel a previously booked at-home phlebotomy appointment.
|
642
649
|
* @throws {@link Vital.UnprocessableEntityError}
|
643
650
|
*/
|
644
|
-
|
651
|
+
cancelPhlebotomyAppointment(orderId, request, requestOptions) {
|
645
652
|
var _a;
|
646
653
|
return __awaiter(this, void 0, void 0, function* () {
|
647
654
|
const _response = yield core.fetcher({
|
@@ -651,7 +658,7 @@ class LabTests {
|
|
651
658
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
652
659
|
"X-Fern-Language": "JavaScript",
|
653
660
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
654
|
-
"X-Fern-SDK-Version": "3.0.
|
661
|
+
"X-Fern-SDK-Version": "3.0.4",
|
655
662
|
},
|
656
663
|
contentType: "application/json",
|
657
664
|
body: yield serializers.AppointmentCancelRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -709,7 +716,7 @@ class LabTests {
|
|
709
716
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
710
717
|
"X-Fern-Language": "JavaScript",
|
711
718
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
712
|
-
"X-Fern-SDK-Version": "3.0.
|
719
|
+
"X-Fern-SDK-Version": "3.0.4",
|
713
720
|
},
|
714
721
|
contentType: "application/json",
|
715
722
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -757,7 +764,7 @@ class LabTests {
|
|
757
764
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
758
765
|
"X-Fern-Language": "JavaScript",
|
759
766
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
760
|
-
"X-Fern-SDK-Version": "3.0.
|
767
|
+
"X-Fern-SDK-Version": "3.0.4",
|
761
768
|
},
|
762
769
|
contentType: "application/json",
|
763
770
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -821,7 +828,7 @@ class LabTests {
|
|
821
828
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
822
829
|
"X-Fern-Language": "JavaScript",
|
823
830
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
824
|
-
"X-Fern-SDK-Version": "3.0.
|
831
|
+
"X-Fern-SDK-Version": "3.0.4",
|
825
832
|
},
|
826
833
|
contentType: "application/json",
|
827
834
|
queryParameters: _queryParams,
|
@@ -880,7 +887,7 @@ class LabTests {
|
|
880
887
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
881
888
|
"X-Fern-Language": "JavaScript",
|
882
889
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
883
|
-
"X-Fern-SDK-Version": "3.0.
|
890
|
+
"X-Fern-SDK-Version": "3.0.4",
|
884
891
|
},
|
885
892
|
contentType: "application/json",
|
886
893
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -934,7 +941,7 @@ class LabTests {
|
|
934
941
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
935
942
|
"X-Fern-Language": "JavaScript",
|
936
943
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
937
|
-
"X-Fern-SDK-Version": "3.0.
|
944
|
+
"X-Fern-SDK-Version": "3.0.4",
|
938
945
|
},
|
939
946
|
contentType: "application/json",
|
940
947
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -992,7 +999,7 @@ class LabTests {
|
|
992
999
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
993
1000
|
"X-Fern-Language": "JavaScript",
|
994
1001
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
995
|
-
"X-Fern-SDK-Version": "3.0.
|
1002
|
+
"X-Fern-SDK-Version": "3.0.4",
|
996
1003
|
},
|
997
1004
|
contentType: "application/json",
|
998
1005
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1050,7 +1057,7 @@ class LabTests {
|
|
1050
1057
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1051
1058
|
"X-Fern-Language": "JavaScript",
|
1052
1059
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1053
|
-
"X-Fern-SDK-Version": "3.0.
|
1060
|
+
"X-Fern-SDK-Version": "3.0.4",
|
1054
1061
|
},
|
1055
1062
|
contentType: "application/json",
|
1056
1063
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1103,7 +1110,7 @@ class LabTests {
|
|
1103
1110
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1104
1111
|
"X-Fern-Language": "JavaScript",
|
1105
1112
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1106
|
-
"X-Fern-SDK-Version": "3.0.
|
1113
|
+
"X-Fern-SDK-Version": "3.0.4",
|
1107
1114
|
},
|
1108
1115
|
contentType: "application/json",
|
1109
1116
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1161,7 +1168,7 @@ class LabTests {
|
|
1161
1168
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1162
1169
|
"X-Fern-Language": "JavaScript",
|
1163
1170
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1164
|
-
"X-Fern-SDK-Version": "3.0.
|
1171
|
+
"X-Fern-SDK-Version": "3.0.4",
|
1165
1172
|
},
|
1166
1173
|
contentType: "application/json",
|
1167
1174
|
body: yield serializers.CreateOrderRequestCompatible.jsonOrThrow(request, {
|
@@ -1222,7 +1229,7 @@ class LabTests {
|
|
1222
1229
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1223
1230
|
"X-Fern-Language": "JavaScript",
|
1224
1231
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1225
|
-
"X-Fern-SDK-Version": "3.0.
|
1232
|
+
"X-Fern-SDK-Version": "3.0.4",
|
1226
1233
|
},
|
1227
1234
|
contentType: "application/json",
|
1228
1235
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1266,6 +1273,68 @@ class LabTests {
|
|
1266
1273
|
}
|
1267
1274
|
});
|
1268
1275
|
}
|
1276
|
+
/**
|
1277
|
+
* Get available test kits.
|
1278
|
+
* @throws {@link Vital.UnprocessableEntityError}
|
1279
|
+
*/
|
1280
|
+
simulateOrderProcess(orderId, request = {}, requestOptions) {
|
1281
|
+
var _a;
|
1282
|
+
return __awaiter(this, void 0, void 0, function* () {
|
1283
|
+
const { finalStatus, delay } = request;
|
1284
|
+
const _queryParams = new url_search_params_1.default();
|
1285
|
+
if (finalStatus != null) {
|
1286
|
+
_queryParams.append("final_status", finalStatus);
|
1287
|
+
}
|
1288
|
+
if (delay != null) {
|
1289
|
+
_queryParams.append("delay", delay.toString());
|
1290
|
+
}
|
1291
|
+
const _response = yield core.fetcher({
|
1292
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VitalEnvironment.Production, `v3/order/${orderId}/test`),
|
1293
|
+
method: "POST",
|
1294
|
+
headers: {
|
1295
|
+
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1296
|
+
"X-Fern-Language": "JavaScript",
|
1297
|
+
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1298
|
+
"X-Fern-SDK-Version": "3.0.4",
|
1299
|
+
},
|
1300
|
+
contentType: "application/json",
|
1301
|
+
queryParameters: _queryParams,
|
1302
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
1303
|
+
});
|
1304
|
+
if (_response.ok) {
|
1305
|
+
return _response.body;
|
1306
|
+
}
|
1307
|
+
if (_response.error.reason === "status-code") {
|
1308
|
+
switch (_response.error.statusCode) {
|
1309
|
+
case 422:
|
1310
|
+
throw new Vital.UnprocessableEntityError(yield serializers.HttpValidationError.parseOrThrow(_response.error.body, {
|
1311
|
+
unrecognizedObjectKeys: "passthrough",
|
1312
|
+
allowUnrecognizedUnionMembers: true,
|
1313
|
+
allowUnrecognizedEnumValues: true,
|
1314
|
+
breadcrumbsPrefix: ["response"],
|
1315
|
+
}));
|
1316
|
+
default:
|
1317
|
+
throw new errors.VitalError({
|
1318
|
+
statusCode: _response.error.statusCode,
|
1319
|
+
body: _response.error.body,
|
1320
|
+
});
|
1321
|
+
}
|
1322
|
+
}
|
1323
|
+
switch (_response.error.reason) {
|
1324
|
+
case "non-json":
|
1325
|
+
throw new errors.VitalError({
|
1326
|
+
statusCode: _response.error.statusCode,
|
1327
|
+
body: _response.error.rawBody,
|
1328
|
+
});
|
1329
|
+
case "timeout":
|
1330
|
+
throw new errors.VitalTimeoutError();
|
1331
|
+
case "unknown":
|
1332
|
+
throw new errors.VitalError({
|
1333
|
+
message: _response.error.errorMessage,
|
1334
|
+
});
|
1335
|
+
}
|
1336
|
+
});
|
1337
|
+
}
|
1269
1338
|
/**
|
1270
1339
|
* GET many orders with filters.
|
1271
1340
|
* @throws {@link Vital.UnprocessableEntityError}
|
@@ -1310,7 +1379,7 @@ class LabTests {
|
|
1310
1379
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1311
1380
|
"X-Fern-Language": "JavaScript",
|
1312
1381
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1313
|
-
"X-Fern-SDK-Version": "3.0.
|
1382
|
+
"X-Fern-SDK-Version": "3.0.4",
|
1314
1383
|
},
|
1315
1384
|
contentType: "application/json",
|
1316
1385
|
queryParameters: _queryParams,
|
@@ -5,7 +5,7 @@ export interface LabTestsGetMarkersRequest {
|
|
5
5
|
/**
|
6
6
|
* The identifier Vital assigned to a lab partner.
|
7
7
|
*/
|
8
|
-
labId?: number;
|
8
|
+
labId?: number | number[];
|
9
9
|
/**
|
10
10
|
* The name of an individual biomarker or a panel. Used as a fuzzy filter when searching markers.
|
11
11
|
*/
|
@@ -6,4 +6,5 @@ export { AppointmentRescheduleRequest } from "./AppointmentRescheduleRequest";
|
|
6
6
|
export { AppointmentCancelRequest } from "./AppointmentCancelRequest";
|
7
7
|
export { LabTestsGetAreaInfoRequest } from "./LabTestsGetAreaInfoRequest";
|
8
8
|
export { CreateOrderRequestCompatible } from "./CreateOrderRequestCompatible";
|
9
|
+
export { LabTestsSimulateOrderProcessRequest } from "./LabTestsSimulateOrderProcessRequest";
|
9
10
|
export { LabTestsGetOrdersRequest } from "./LabTestsGetOrdersRequest";
|
@@ -80,7 +80,7 @@ class Link {
|
|
80
80
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
81
81
|
"X-Fern-Language": "JavaScript",
|
82
82
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
83
|
-
"X-Fern-SDK-Version": "3.0.
|
83
|
+
"X-Fern-SDK-Version": "3.0.4",
|
84
84
|
},
|
85
85
|
contentType: "application/json",
|
86
86
|
body: yield serializers.LinkTokenExchange.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -138,7 +138,7 @@ class Link {
|
|
138
138
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
139
139
|
"X-Fern-Language": "JavaScript",
|
140
140
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
141
|
-
"X-Fern-SDK-Version": "3.0.
|
141
|
+
"X-Fern-SDK-Version": "3.0.4",
|
142
142
|
},
|
143
143
|
contentType: "application/json",
|
144
144
|
body: yield serializers.LinkTokenBase.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -203,7 +203,7 @@ class Link {
|
|
203
203
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
204
204
|
"X-Fern-Language": "JavaScript",
|
205
205
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
206
|
-
"X-Fern-SDK-Version": "3.0.
|
206
|
+
"X-Fern-SDK-Version": "3.0.4",
|
207
207
|
},
|
208
208
|
contentType: "application/json",
|
209
209
|
queryParameters: _queryParams,
|
@@ -265,7 +265,7 @@ class Link {
|
|
265
265
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
266
266
|
"X-Fern-Language": "JavaScript",
|
267
267
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
268
|
-
"X-Fern-SDK-Version": "3.0.
|
268
|
+
"X-Fern-SDK-Version": "3.0.4",
|
269
269
|
"x-vital-sdk-no-redirect": vitalSdkNoRedirect != null ? vitalSdkNoRedirect : undefined,
|
270
270
|
},
|
271
271
|
contentType: "application/json",
|
@@ -325,7 +325,7 @@ class Link {
|
|
325
325
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
326
326
|
"X-Fern-Language": "JavaScript",
|
327
327
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
328
|
-
"X-Fern-SDK-Version": "3.0.
|
328
|
+
"X-Fern-SDK-Version": "3.0.4",
|
329
329
|
},
|
330
330
|
contentType: "application/json",
|
331
331
|
body: yield serializers.BeginLinkTokenRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -384,7 +384,7 @@ class Link {
|
|
384
384
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
385
385
|
"X-Fern-Language": "JavaScript",
|
386
386
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
387
|
-
"X-Fern-SDK-Version": "3.0.
|
387
|
+
"X-Fern-SDK-Version": "3.0.4",
|
388
388
|
},
|
389
389
|
contentType: "application/json",
|
390
390
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -434,7 +434,7 @@ class Link {
|
|
434
434
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
435
435
|
"X-Fern-Language": "JavaScript",
|
436
436
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
437
|
-
"X-Fern-SDK-Version": "3.0.
|
437
|
+
"X-Fern-SDK-Version": "3.0.4",
|
438
438
|
},
|
439
439
|
contentType: "application/json",
|
440
440
|
body: yield serializers.EmailAuthLink.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -496,7 +496,7 @@ class Link {
|
|
496
496
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
497
497
|
"X-Fern-Language": "JavaScript",
|
498
498
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
499
|
-
"X-Fern-SDK-Version": "3.0.
|
499
|
+
"X-Fern-SDK-Version": "3.0.4",
|
500
500
|
"x-vital-link-client-region": vitalLinkClientRegion != null ? vitalLinkClientRegion : undefined,
|
501
501
|
},
|
502
502
|
contentType: "application/json",
|
@@ -556,7 +556,7 @@ class Link {
|
|
556
556
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
557
557
|
"X-Fern-Language": "JavaScript",
|
558
558
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
559
|
-
"X-Fern-SDK-Version": "3.0.
|
559
|
+
"X-Fern-SDK-Version": "3.0.4",
|
560
560
|
},
|
561
561
|
contentType: "application/json",
|
562
562
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -615,7 +615,7 @@ class Link {
|
|
615
615
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
616
616
|
"X-Fern-Language": "JavaScript",
|
617
617
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
618
|
-
"X-Fern-SDK-Version": "3.0.
|
618
|
+
"X-Fern-SDK-Version": "3.0.4",
|
619
619
|
"x-vital-link-client-region": vitalLinkClientRegion != null ? vitalLinkClientRegion : undefined,
|
620
620
|
},
|
621
621
|
contentType: "application/json",
|
@@ -675,7 +675,7 @@ class Link {
|
|
675
675
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
676
676
|
"X-Fern-Language": "JavaScript",
|
677
677
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
678
|
-
"X-Fern-SDK-Version": "3.0.
|
678
|
+
"X-Fern-SDK-Version": "3.0.4",
|
679
679
|
},
|
680
680
|
contentType: "application/json",
|
681
681
|
body: yield serializers.EmailProviderAuthLink.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -733,7 +733,7 @@ class Link {
|
|
733
733
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
734
734
|
"X-Fern-Language": "JavaScript",
|
735
735
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
736
|
-
"X-Fern-SDK-Version": "3.0.
|
736
|
+
"X-Fern-SDK-Version": "3.0.4",
|
737
737
|
},
|
738
738
|
contentType: "application/json",
|
739
739
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -783,7 +783,7 @@ class Link {
|
|
783
783
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
784
784
|
"X-Fern-Language": "JavaScript",
|
785
785
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
786
|
-
"X-Fern-SDK-Version": "3.0.
|
786
|
+
"X-Fern-SDK-Version": "3.0.4",
|
787
787
|
},
|
788
788
|
contentType: "application/json",
|
789
789
|
body: yield serializers.ManualConnectionData.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -842,7 +842,7 @@ class Link {
|
|
842
842
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
843
843
|
"X-Fern-Language": "JavaScript",
|
844
844
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
845
|
-
"X-Fern-SDK-Version": "3.0.
|
845
|
+
"X-Fern-SDK-Version": "3.0.4",
|
846
846
|
},
|
847
847
|
contentType: "application/json",
|
848
848
|
body: yield serializers.DemoConnectionCreationPayload.jsonOrThrow(request, {
|
@@ -73,7 +73,7 @@ class Meal {
|
|
73
73
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
74
74
|
"X-Fern-Language": "JavaScript",
|
75
75
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
76
|
-
"X-Fern-SDK-Version": "3.0.
|
76
|
+
"X-Fern-SDK-Version": "3.0.4",
|
77
77
|
},
|
78
78
|
contentType: "application/json",
|
79
79
|
queryParameters: _queryParams,
|
@@ -69,7 +69,7 @@ class Profile {
|
|
69
69
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
70
70
|
"X-Fern-Language": "JavaScript",
|
71
71
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
72
|
-
"X-Fern-SDK-Version": "3.0.
|
72
|
+
"X-Fern-SDK-Version": "3.0.4",
|
73
73
|
},
|
74
74
|
contentType: "application/json",
|
75
75
|
queryParameters: _queryParams,
|
@@ -133,7 +133,7 @@ class Profile {
|
|
133
133
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
134
134
|
"X-Fern-Language": "JavaScript",
|
135
135
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
136
|
-
"X-Fern-SDK-Version": "3.0.
|
136
|
+
"X-Fern-SDK-Version": "3.0.4",
|
137
137
|
},
|
138
138
|
contentType: "application/json",
|
139
139
|
queryParameters: _queryParams,
|
@@ -61,7 +61,7 @@ class Providers {
|
|
61
61
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
62
62
|
"X-Fern-Language": "JavaScript",
|
63
63
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
64
|
-
"X-Fern-SDK-Version": "3.0.
|
64
|
+
"X-Fern-SDK-Version": "3.0.4",
|
65
65
|
},
|
66
66
|
contentType: "application/json",
|
67
67
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -73,7 +73,7 @@ class Sleep {
|
|
73
73
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
74
74
|
"X-Fern-Language": "JavaScript",
|
75
75
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
76
|
-
"X-Fern-SDK-Version": "3.0.
|
76
|
+
"X-Fern-SDK-Version": "3.0.4",
|
77
77
|
},
|
78
78
|
contentType: "application/json",
|
79
79
|
queryParameters: _queryParams,
|
@@ -141,7 +141,7 @@ class Sleep {
|
|
141
141
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
142
142
|
"X-Fern-Language": "JavaScript",
|
143
143
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
144
|
-
"X-Fern-SDK-Version": "3.0.
|
144
|
+
"X-Fern-SDK-Version": "3.0.4",
|
145
145
|
},
|
146
146
|
contentType: "application/json",
|
147
147
|
queryParameters: _queryParams,
|
@@ -209,7 +209,7 @@ class Sleep {
|
|
209
209
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
210
210
|
"X-Fern-Language": "JavaScript",
|
211
211
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
212
|
-
"X-Fern-SDK-Version": "3.0.
|
212
|
+
"X-Fern-SDK-Version": "3.0.4",
|
213
213
|
},
|
214
214
|
contentType: "application/json",
|
215
215
|
queryParameters: _queryParams,
|
@@ -268,7 +268,7 @@ class Sleep {
|
|
268
268
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
269
269
|
"X-Fern-Language": "JavaScript",
|
270
270
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
271
|
-
"X-Fern-SDK-Version": "3.0.
|
271
|
+
"X-Fern-SDK-Version": "3.0.4",
|
272
272
|
},
|
273
273
|
contentType: "application/json",
|
274
274
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -41,4 +41,8 @@ export declare class Team {
|
|
41
41
|
* @throws {@link Vital.UnprocessableEntityError}
|
42
42
|
*/
|
43
43
|
updateSourcePriorities(request: Vital.TeamUpdateSourcePrioritiesRequest, requestOptions?: Team.RequestOptions): Promise<Record<string, unknown>[]>;
|
44
|
+
/**
|
45
|
+
* @throws {@link Vital.UnprocessableEntityError}
|
46
|
+
*/
|
47
|
+
getPhysicians(teamId: string, requestOptions?: Team.RequestOptions): Promise<Vital.ClientFacingPhysician[]>;
|
44
48
|
}
|
@@ -63,7 +63,7 @@ class Team {
|
|
63
63
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
64
64
|
"X-Fern-Language": "JavaScript",
|
65
65
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
66
|
-
"X-Fern-SDK-Version": "3.0.
|
66
|
+
"X-Fern-SDK-Version": "3.0.4",
|
67
67
|
},
|
68
68
|
contentType: "application/json",
|
69
69
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -111,7 +111,7 @@ class Team {
|
|
111
111
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
112
112
|
"X-Fern-Language": "JavaScript",
|
113
113
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
114
|
-
"X-Fern-SDK-Version": "3.0.
|
114
|
+
"X-Fern-SDK-Version": "3.0.4",
|
115
115
|
},
|
116
116
|
contentType: "application/json",
|
117
117
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -174,7 +174,7 @@ class Team {
|
|
174
174
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
175
175
|
"X-Fern-Language": "JavaScript",
|
176
176
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
177
|
-
"X-Fern-SDK-Version": "3.0.
|
177
|
+
"X-Fern-SDK-Version": "3.0.4",
|
178
178
|
},
|
179
179
|
contentType: "application/json",
|
180
180
|
queryParameters: _queryParams,
|
@@ -229,7 +229,7 @@ class Team {
|
|
229
229
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
230
230
|
"X-Fern-Language": "JavaScript",
|
231
231
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
232
|
-
"X-Fern-SDK-Version": "3.0.
|
232
|
+
"X-Fern-SDK-Version": "3.0.4",
|
233
233
|
},
|
234
234
|
contentType: "application/json",
|
235
235
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -282,7 +282,7 @@ class Team {
|
|
282
282
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
283
283
|
"X-Fern-Language": "JavaScript",
|
284
284
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
285
|
-
"X-Fern-SDK-Version": "3.0.
|
285
|
+
"X-Fern-SDK-Version": "3.0.4",
|
286
286
|
},
|
287
287
|
contentType: "application/json",
|
288
288
|
queryParameters: _queryParams,
|
@@ -344,7 +344,7 @@ class Team {
|
|
344
344
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
345
345
|
"X-Fern-Language": "JavaScript",
|
346
346
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
347
|
-
"X-Fern-SDK-Version": "3.0.
|
347
|
+
"X-Fern-SDK-Version": "3.0.4",
|
348
348
|
},
|
349
349
|
contentType: "application/json",
|
350
350
|
queryParameters: _queryParams,
|
@@ -389,5 +389,62 @@ class Team {
|
|
389
389
|
}
|
390
390
|
});
|
391
391
|
}
|
392
|
+
/**
|
393
|
+
* @throws {@link Vital.UnprocessableEntityError}
|
394
|
+
*/
|
395
|
+
getPhysicians(teamId, requestOptions) {
|
396
|
+
var _a;
|
397
|
+
return __awaiter(this, void 0, void 0, function* () {
|
398
|
+
const _response = yield core.fetcher({
|
399
|
+
url: (0, url_join_1.default)((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.VitalEnvironment.Production, `v2/team/${teamId}/physicians`),
|
400
|
+
method: "GET",
|
401
|
+
headers: {
|
402
|
+
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
403
|
+
"X-Fern-Language": "JavaScript",
|
404
|
+
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
405
|
+
"X-Fern-SDK-Version": "3.0.4",
|
406
|
+
},
|
407
|
+
contentType: "application/json",
|
408
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
409
|
+
});
|
410
|
+
if (_response.ok) {
|
411
|
+
return yield serializers.team.getPhysicians.Response.parseOrThrow(_response.body, {
|
412
|
+
unrecognizedObjectKeys: "passthrough",
|
413
|
+
allowUnrecognizedUnionMembers: true,
|
414
|
+
allowUnrecognizedEnumValues: true,
|
415
|
+
breadcrumbsPrefix: ["response"],
|
416
|
+
});
|
417
|
+
}
|
418
|
+
if (_response.error.reason === "status-code") {
|
419
|
+
switch (_response.error.statusCode) {
|
420
|
+
case 422:
|
421
|
+
throw new Vital.UnprocessableEntityError(yield serializers.HttpValidationError.parseOrThrow(_response.error.body, {
|
422
|
+
unrecognizedObjectKeys: "passthrough",
|
423
|
+
allowUnrecognizedUnionMembers: true,
|
424
|
+
allowUnrecognizedEnumValues: true,
|
425
|
+
breadcrumbsPrefix: ["response"],
|
426
|
+
}));
|
427
|
+
default:
|
428
|
+
throw new errors.VitalError({
|
429
|
+
statusCode: _response.error.statusCode,
|
430
|
+
body: _response.error.body,
|
431
|
+
});
|
432
|
+
}
|
433
|
+
}
|
434
|
+
switch (_response.error.reason) {
|
435
|
+
case "non-json":
|
436
|
+
throw new errors.VitalError({
|
437
|
+
statusCode: _response.error.statusCode,
|
438
|
+
body: _response.error.rawBody,
|
439
|
+
});
|
440
|
+
case "timeout":
|
441
|
+
throw new errors.VitalTimeoutError();
|
442
|
+
case "unknown":
|
443
|
+
throw new errors.VitalError({
|
444
|
+
message: _response.error.errorMessage,
|
445
|
+
});
|
446
|
+
}
|
447
|
+
});
|
448
|
+
}
|
392
449
|
}
|
393
450
|
exports.Team = Team;
|