@tryvital/vital-node 3.0.5 → 3.0.7
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/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/insurance/client/Client.js +2 -2
- package/api/resources/introspect/client/Client.d.ts +4 -0
- package/api/resources/introspect/client/Client.js +73 -1
- package/api/resources/introspect/client/requests/IntrospectGetUserHistoricalPullsRequest.d.ts +10 -0
- package/api/resources/introspect/client/requests/index.d.ts +1 -0
- package/api/resources/labTests/client/Client.d.ts +8 -2
- package/api/resources/labTests/client/Client.js +88 -57
- package/api/resources/labTests/client/requests/RequestAppointmentRequest.d.ts +9 -0
- package/api/resources/labTests/client/requests/index.d.ts +1 -0
- package/api/resources/link/client/Client.d.ts +3 -3
- package/api/resources/link/client/Client.js +23 -51
- package/api/resources/link/client/requests/EmailAuthLink.d.ts +1 -1
- package/api/resources/link/client/requests/EmailProviderAuthLink.d.ts +1 -1
- package/api/resources/link/client/requests/IndividualProviderData.d.ts +1 -1
- package/api/resources/link/client/requests/LinkGenerateOauthLinkRequest.d.ts +1 -1
- package/api/resources/link/client/requests/LinkGetAllProvidersRequest.d.ts +1 -1
- package/api/resources/link/client/requests/LinkTokenStateRequest.d.ts +1 -1
- package/api/resources/link/client/requests/PasswordAuthLink.d.ts +1 -1
- 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 +1 -1
- package/api/resources/team/client/Client.js +9 -13
- package/api/resources/team/client/requests/TeamGetLinkConfigRequest.d.ts +1 -1
- package/api/resources/testkit/client/Client.js +2 -2
- package/api/resources/user/client/Client.d.ts +1 -1
- package/api/resources/user/client/Client.js +18 -12
- package/api/resources/user/client/requests/UserRefreshRequest.d.ts +6 -0
- package/api/resources/user/client/requests/index.d.ts +1 -0
- package/api/resources/vitals/client/Client.js +23 -23
- package/api/resources/workouts/client/Client.js +3 -3
- package/api/types/AppointmentEventStatus.d.ts +2 -1
- package/api/types/AppointmentEventStatus.js +1 -0
- package/api/types/AppointmentProvider.d.ts +2 -1
- package/api/types/AppointmentProvider.js +1 -0
- package/api/types/AppointmentServiceType.d.ts +11 -0
- package/api/types/AppointmentServiceType.js +10 -0
- package/api/types/ClientFacingAppointment.d.ts +3 -3
- package/api/types/HistoricalPullStatus.d.ts +12 -0
- package/api/types/HistoricalPullStatus.js +11 -0
- package/api/types/OrderStatus.d.ts +2 -1
- package/api/types/OrderStatus.js +1 -0
- package/api/types/PhlebotomyAreaInfo.d.ts +2 -0
- package/api/types/PhlebotomyProviderInfo.d.ts +8 -0
- package/api/types/SingleHistoricalPullStatistics.d.ts +12 -0
- package/api/types/SingleHistoricalPullStatistics.js +5 -0
- package/api/types/SingleProviderHistoricalPullResponse.d.ts +8 -0
- package/api/types/SingleProviderHistoricalPullResponse.js +5 -0
- package/api/types/SingleUserHistoricalPullResponse.d.ts +8 -0
- package/api/types/SingleUserHistoricalPullResponse.js +5 -0
- package/api/types/SingleUserResourceResponse.d.ts +2 -0
- package/api/types/UserHistoricalPullsResponse.d.ts +8 -0
- package/api/types/UserHistoricalPullsResponse.js +5 -0
- package/api/types/UserRefreshSuccessResponse.d.ts +1 -0
- package/api/types/UserSignInTokenResponse.d.ts +1 -2
- package/api/types/index.d.ts +7 -2
- package/api/types/index.js +7 -2
- package/core/index.d.ts +1 -0
- package/core/index.js +1 -0
- package/core/streaming-fetcher/StreamingFetcher.d.ts +30 -0
- package/core/streaming-fetcher/StreamingFetcher.js +79 -0
- package/core/streaming-fetcher/getHeader.d.ts +2 -0
- package/core/streaming-fetcher/getHeader.js +12 -0
- package/core/streaming-fetcher/index.d.ts +3 -0
- package/core/streaming-fetcher/index.js +7 -0
- 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/insurance/client/Client.js +2 -2
- package/dist/api/resources/introspect/client/Client.d.ts +4 -0
- package/dist/api/resources/introspect/client/Client.js +73 -1
- package/dist/api/resources/introspect/client/requests/IntrospectGetUserHistoricalPullsRequest.d.ts +10 -0
- package/dist/api/resources/introspect/client/requests/IntrospectGetUserHistoricalPullsRequest.js +5 -0
- package/dist/api/resources/introspect/client/requests/index.d.ts +1 -0
- package/dist/api/resources/labTests/client/Client.d.ts +8 -2
- package/dist/api/resources/labTests/client/Client.js +88 -57
- package/dist/api/resources/labTests/client/requests/RequestAppointmentRequest.d.ts +9 -0
- package/dist/api/resources/labTests/client/requests/RequestAppointmentRequest.js +5 -0
- package/dist/api/resources/labTests/client/requests/index.d.ts +1 -0
- package/dist/api/resources/link/client/Client.d.ts +3 -3
- package/dist/api/resources/link/client/Client.js +23 -51
- package/dist/api/resources/link/client/requests/EmailAuthLink.d.ts +1 -1
- package/dist/api/resources/link/client/requests/EmailProviderAuthLink.d.ts +1 -1
- package/dist/api/resources/link/client/requests/IndividualProviderData.d.ts +1 -1
- package/dist/api/resources/link/client/requests/LinkGenerateOauthLinkRequest.d.ts +1 -1
- package/dist/api/resources/link/client/requests/LinkGetAllProvidersRequest.d.ts +1 -1
- package/dist/api/resources/link/client/requests/LinkTokenStateRequest.d.ts +1 -1
- package/dist/api/resources/link/client/requests/PasswordAuthLink.d.ts +1 -1
- 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 +1 -1
- package/dist/api/resources/team/client/Client.js +9 -13
- package/dist/api/resources/team/client/requests/TeamGetLinkConfigRequest.d.ts +1 -1
- package/dist/api/resources/testkit/client/Client.js +2 -2
- package/dist/api/resources/user/client/Client.d.ts +1 -1
- package/dist/api/resources/user/client/Client.js +18 -12
- package/dist/api/resources/user/client/requests/UserRefreshRequest.d.ts +6 -0
- package/dist/api/resources/user/client/requests/UserRefreshRequest.js +5 -0
- package/dist/api/resources/user/client/requests/index.d.ts +1 -0
- package/dist/api/resources/vitals/client/Client.js +23 -23
- package/dist/api/resources/workouts/client/Client.js +3 -3
- package/dist/api/types/AppointmentEventStatus.d.ts +2 -1
- package/dist/api/types/AppointmentEventStatus.js +1 -0
- package/dist/api/types/AppointmentProvider.d.ts +2 -1
- package/dist/api/types/AppointmentProvider.js +1 -0
- package/dist/api/types/AppointmentServiceType.d.ts +11 -0
- package/dist/api/types/AppointmentServiceType.js +10 -0
- package/dist/api/types/ClientFacingAppointment.d.ts +3 -3
- package/dist/api/types/HistoricalPullStatus.d.ts +12 -0
- package/dist/api/types/HistoricalPullStatus.js +11 -0
- package/dist/api/types/OrderStatus.d.ts +2 -1
- package/dist/api/types/OrderStatus.js +1 -0
- package/dist/api/types/PhlebotomyAreaInfo.d.ts +2 -0
- package/dist/api/types/PhlebotomyProviderInfo.d.ts +8 -0
- package/dist/api/types/PhlebotomyProviderInfo.js +5 -0
- package/dist/api/types/SingleHistoricalPullStatistics.d.ts +12 -0
- package/dist/api/types/SingleHistoricalPullStatistics.js +5 -0
- package/dist/api/types/SingleProviderHistoricalPullResponse.d.ts +8 -0
- package/dist/api/types/SingleProviderHistoricalPullResponse.js +5 -0
- package/dist/api/types/SingleUserHistoricalPullResponse.d.ts +8 -0
- package/dist/api/types/SingleUserHistoricalPullResponse.js +5 -0
- package/dist/api/types/SingleUserResourceResponse.d.ts +2 -0
- package/dist/api/types/UserHistoricalPullsResponse.d.ts +8 -0
- package/dist/api/types/UserHistoricalPullsResponse.js +5 -0
- package/dist/api/types/UserRefreshSuccessResponse.d.ts +1 -0
- package/dist/api/types/UserSignInTokenResponse.d.ts +1 -2
- package/dist/api/types/index.d.ts +7 -2
- package/dist/api/types/index.js +7 -2
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.js +1 -0
- package/dist/core/streaming-fetcher/StreamingFetcher.d.ts +30 -0
- package/dist/core/streaming-fetcher/StreamingFetcher.js +79 -0
- package/dist/core/streaming-fetcher/getHeader.d.ts +2 -0
- package/dist/core/streaming-fetcher/getHeader.js +12 -0
- package/dist/core/streaming-fetcher/index.d.ts +3 -0
- package/dist/core/streaming-fetcher/index.js +7 -0
- package/dist/serialization/resources/labTests/client/requests/RequestAppointmentRequest.d.ts +13 -0
- package/dist/serialization/resources/labTests/client/requests/RequestAppointmentRequest.js +43 -0
- package/dist/serialization/resources/labTests/client/requests/index.d.ts +1 -0
- package/dist/serialization/resources/labTests/client/requests/index.js +3 -1
- package/dist/serialization/types/AppointmentEventStatus.d.ts +1 -1
- package/dist/serialization/types/AppointmentEventStatus.js +1 -1
- package/dist/serialization/types/AppointmentProvider.d.ts +1 -1
- package/dist/serialization/types/AppointmentProvider.js +1 -1
- package/dist/serialization/types/AppointmentServiceType.d.ts +10 -0
- package/dist/serialization/types/{UserSignInToken.js → AppointmentServiceType.js} +2 -5
- package/dist/serialization/types/ClientFacingAppointment.d.ts +3 -3
- package/dist/serialization/types/ClientFacingAppointment.js +3 -3
- package/dist/serialization/types/HistoricalPullStatus.d.ts +10 -0
- package/{serialization/types/UserSignInToken.js → dist/serialization/types/HistoricalPullStatus.js} +2 -5
- package/dist/serialization/types/OrderStatus.d.ts +1 -1
- package/dist/serialization/types/OrderStatus.js +1 -0
- package/dist/serialization/types/PhlebotomyAreaInfo.d.ts +1 -0
- package/dist/serialization/types/PhlebotomyAreaInfo.js +10 -0
- package/dist/serialization/types/PhlebotomyProviderInfo.d.ts +13 -0
- package/dist/serialization/types/PhlebotomyProviderInfo.js +43 -0
- package/dist/serialization/types/SingleHistoricalPullStatistics.d.ts +17 -0
- package/dist/serialization/types/SingleHistoricalPullStatistics.js +47 -0
- package/dist/serialization/types/SingleProviderHistoricalPullResponse.d.ts +13 -0
- package/dist/serialization/types/SingleProviderHistoricalPullResponse.js +43 -0
- package/dist/serialization/types/SingleUserHistoricalPullResponse.d.ts +13 -0
- package/dist/serialization/types/SingleUserHistoricalPullResponse.js +43 -0
- package/dist/serialization/types/SingleUserResourceResponse.d.ts +1 -0
- package/dist/serialization/types/SingleUserResourceResponse.js +10 -0
- package/dist/serialization/types/UserHistoricalPullsResponse.d.ts +13 -0
- package/dist/serialization/types/{UserSignInTokenResponseSignInToken.js → UserHistoricalPullsResponse.js} +5 -5
- package/dist/serialization/types/UserRefreshSuccessResponse.d.ts +1 -0
- package/dist/serialization/types/UserRefreshSuccessResponse.js +1 -0
- package/dist/serialization/types/UserSignInTokenResponse.d.ts +1 -1
- package/dist/serialization/types/UserSignInTokenResponse.js +1 -10
- package/dist/serialization/types/index.d.ts +7 -2
- package/dist/serialization/types/index.js +7 -2
- package/package.json +1 -1
- package/serialization/resources/labTests/client/requests/RequestAppointmentRequest.d.ts +13 -0
- package/serialization/resources/labTests/client/requests/RequestAppointmentRequest.js +43 -0
- package/serialization/resources/labTests/client/requests/index.d.ts +1 -0
- package/serialization/resources/labTests/client/requests/index.js +3 -1
- package/serialization/types/AppointmentEventStatus.d.ts +1 -1
- package/serialization/types/AppointmentEventStatus.js +1 -1
- package/serialization/types/AppointmentProvider.d.ts +1 -1
- package/serialization/types/AppointmentProvider.js +1 -1
- package/serialization/types/AppointmentServiceType.d.ts +10 -0
- package/serialization/types/AppointmentServiceType.js +31 -0
- package/serialization/types/ClientFacingAppointment.d.ts +3 -3
- package/serialization/types/ClientFacingAppointment.js +3 -3
- package/serialization/types/HistoricalPullStatus.d.ts +10 -0
- package/serialization/types/HistoricalPullStatus.js +31 -0
- package/serialization/types/OrderStatus.d.ts +1 -1
- package/serialization/types/OrderStatus.js +1 -0
- package/serialization/types/PhlebotomyAreaInfo.d.ts +1 -0
- package/serialization/types/PhlebotomyAreaInfo.js +10 -0
- package/serialization/types/PhlebotomyProviderInfo.d.ts +13 -0
- package/serialization/types/PhlebotomyProviderInfo.js +43 -0
- package/serialization/types/SingleHistoricalPullStatistics.d.ts +17 -0
- package/serialization/types/SingleHistoricalPullStatistics.js +47 -0
- package/serialization/types/SingleProviderHistoricalPullResponse.d.ts +13 -0
- package/serialization/types/SingleProviderHistoricalPullResponse.js +43 -0
- package/serialization/types/SingleUserHistoricalPullResponse.d.ts +13 -0
- package/serialization/types/SingleUserHistoricalPullResponse.js +43 -0
- package/serialization/types/SingleUserResourceResponse.d.ts +1 -0
- package/serialization/types/SingleUserResourceResponse.js +10 -0
- package/serialization/types/UserHistoricalPullsResponse.d.ts +13 -0
- package/serialization/types/{UserSignInTokenResponseSignInToken.js → UserHistoricalPullsResponse.js} +5 -5
- package/serialization/types/UserRefreshSuccessResponse.d.ts +1 -0
- package/serialization/types/UserRefreshSuccessResponse.js +1 -0
- package/serialization/types/UserSignInTokenResponse.d.ts +1 -1
- package/serialization/types/UserSignInTokenResponse.js +1 -10
- package/serialization/types/index.d.ts +7 -2
- package/serialization/types/index.js +7 -2
- package/api/types/UserSignInToken.d.ts +0 -7
- package/api/types/UserSignInTokenResponseSignInToken.d.ts +0 -5
- package/dist/api/types/UserSignInToken.d.ts +0 -7
- package/dist/api/types/UserSignInTokenResponseSignInToken.d.ts +0 -5
- package/dist/serialization/types/UserSignInToken.d.ts +0 -13
- package/dist/serialization/types/UserSignInTokenResponseSignInToken.d.ts +0 -10
- package/serialization/types/UserSignInToken.d.ts +0 -13
- package/serialization/types/UserSignInTokenResponseSignInToken.d.ts +0 -10
- /package/api/{types/UserSignInToken.js → resources/introspect/client/requests/IntrospectGetUserHistoricalPullsRequest.js} +0 -0
- /package/api/{types/UserSignInTokenResponseSignInToken.js → resources/labTests/client/requests/RequestAppointmentRequest.js} +0 -0
- /package/{dist/api/types/UserSignInToken.js → api/resources/user/client/requests/UserRefreshRequest.js} +0 -0
- /package/{dist/api/types/UserSignInTokenResponseSignInToken.js → api/types/PhlebotomyProviderInfo.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.7",
|
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.7",
|
114
114
|
},
|
115
115
|
contentType: "application/json",
|
116
116
|
body: yield serializers.CreateLabTestRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -190,7 +190,7 @@ class LabTests {
|
|
190
190
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
191
191
|
"X-Fern-Language": "JavaScript",
|
192
192
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
193
|
-
"X-Fern-SDK-Version": "3.0.
|
193
|
+
"X-Fern-SDK-Version": "3.0.7",
|
194
194
|
},
|
195
195
|
contentType: "application/json",
|
196
196
|
queryParameters: _queryParams,
|
@@ -256,7 +256,7 @@ class LabTests {
|
|
256
256
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
257
257
|
"X-Fern-Language": "JavaScript",
|
258
258
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
259
|
-
"X-Fern-SDK-Version": "3.0.
|
259
|
+
"X-Fern-SDK-Version": "3.0.7",
|
260
260
|
},
|
261
261
|
contentType: "application/json",
|
262
262
|
queryParameters: _queryParams,
|
@@ -315,7 +315,7 @@ class LabTests {
|
|
315
315
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
316
316
|
"X-Fern-Language": "JavaScript",
|
317
317
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
318
|
-
"X-Fern-SDK-Version": "3.0.
|
318
|
+
"X-Fern-SDK-Version": "3.0.7",
|
319
319
|
},
|
320
320
|
contentType: "application/json",
|
321
321
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -372,7 +372,7 @@ class LabTests {
|
|
372
372
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
373
373
|
"X-Fern-Language": "JavaScript",
|
374
374
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
375
|
-
"X-Fern-SDK-Version": "3.0.
|
375
|
+
"X-Fern-SDK-Version": "3.0.7",
|
376
376
|
},
|
377
377
|
contentType: "application/json",
|
378
378
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -420,7 +420,7 @@ class LabTests {
|
|
420
420
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
421
421
|
"X-Fern-Language": "JavaScript",
|
422
422
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
423
|
-
"X-Fern-SDK-Version": "3.0.
|
423
|
+
"X-Fern-SDK-Version": "3.0.7",
|
424
424
|
},
|
425
425
|
contentType: "application/json",
|
426
426
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -479,7 +479,7 @@ class LabTests {
|
|
479
479
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
480
480
|
"X-Fern-Language": "JavaScript",
|
481
481
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
482
|
-
"X-Fern-SDK-Version": "3.0.
|
482
|
+
"X-Fern-SDK-Version": "3.0.7",
|
483
483
|
},
|
484
484
|
contentType: "application/json",
|
485
485
|
body: yield serializers.UsAddress.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -538,7 +538,7 @@ class LabTests {
|
|
538
538
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
539
539
|
"X-Fern-Language": "JavaScript",
|
540
540
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
541
|
-
"X-Fern-SDK-Version": "3.0.
|
541
|
+
"X-Fern-SDK-Version": "3.0.7",
|
542
542
|
},
|
543
543
|
contentType: "application/json",
|
544
544
|
body: yield serializers.AppointmentBookingRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -583,6 +583,65 @@ class LabTests {
|
|
583
583
|
}
|
584
584
|
});
|
585
585
|
}
|
586
|
+
/**
|
587
|
+
* Request an at-home phlebotomy appointment.
|
588
|
+
* @throws {@link Vital.UnprocessableEntityError}
|
589
|
+
*/
|
590
|
+
requestPhlebotomyAppointment(orderId, request, requestOptions) {
|
591
|
+
var _a;
|
592
|
+
return __awaiter(this, void 0, void 0, function* () {
|
593
|
+
const _response = yield core.fetcher({
|
594
|
+
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}/phlebotomy/appointment/request`),
|
595
|
+
method: "POST",
|
596
|
+
headers: {
|
597
|
+
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
598
|
+
"X-Fern-Language": "JavaScript",
|
599
|
+
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
600
|
+
"X-Fern-SDK-Version": "3.0.7",
|
601
|
+
},
|
602
|
+
contentType: "application/json",
|
603
|
+
body: yield serializers.RequestAppointmentRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
604
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
605
|
+
});
|
606
|
+
if (_response.ok) {
|
607
|
+
return yield serializers.ClientFacingAppointment.parseOrThrow(_response.body, {
|
608
|
+
unrecognizedObjectKeys: "passthrough",
|
609
|
+
allowUnrecognizedUnionMembers: true,
|
610
|
+
allowUnrecognizedEnumValues: true,
|
611
|
+
breadcrumbsPrefix: ["response"],
|
612
|
+
});
|
613
|
+
}
|
614
|
+
if (_response.error.reason === "status-code") {
|
615
|
+
switch (_response.error.statusCode) {
|
616
|
+
case 422:
|
617
|
+
throw new Vital.UnprocessableEntityError(yield serializers.HttpValidationError.parseOrThrow(_response.error.body, {
|
618
|
+
unrecognizedObjectKeys: "passthrough",
|
619
|
+
allowUnrecognizedUnionMembers: true,
|
620
|
+
allowUnrecognizedEnumValues: true,
|
621
|
+
breadcrumbsPrefix: ["response"],
|
622
|
+
}));
|
623
|
+
default:
|
624
|
+
throw new errors.VitalError({
|
625
|
+
statusCode: _response.error.statusCode,
|
626
|
+
body: _response.error.body,
|
627
|
+
});
|
628
|
+
}
|
629
|
+
}
|
630
|
+
switch (_response.error.reason) {
|
631
|
+
case "non-json":
|
632
|
+
throw new errors.VitalError({
|
633
|
+
statusCode: _response.error.statusCode,
|
634
|
+
body: _response.error.rawBody,
|
635
|
+
});
|
636
|
+
case "timeout":
|
637
|
+
throw new errors.VitalTimeoutError();
|
638
|
+
case "unknown":
|
639
|
+
throw new errors.VitalError({
|
640
|
+
message: _response.error.errorMessage,
|
641
|
+
});
|
642
|
+
}
|
643
|
+
});
|
644
|
+
}
|
586
645
|
/**
|
587
646
|
* Reschedule a previously booked at-home phlebotomy appointment.
|
588
647
|
* @throws {@link Vital.UnprocessableEntityError}
|
@@ -597,7 +656,7 @@ class LabTests {
|
|
597
656
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
598
657
|
"X-Fern-Language": "JavaScript",
|
599
658
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
600
|
-
"X-Fern-SDK-Version": "3.0.
|
659
|
+
"X-Fern-SDK-Version": "3.0.7",
|
601
660
|
},
|
602
661
|
contentType: "application/json",
|
603
662
|
body: yield serializers.AppointmentRescheduleRequest.jsonOrThrow(request, {
|
@@ -658,7 +717,7 @@ class LabTests {
|
|
658
717
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
659
718
|
"X-Fern-Language": "JavaScript",
|
660
719
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
661
|
-
"X-Fern-SDK-Version": "3.0.
|
720
|
+
"X-Fern-SDK-Version": "3.0.7",
|
662
721
|
},
|
663
722
|
contentType: "application/json",
|
664
723
|
body: yield serializers.AppointmentCancelRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -716,7 +775,7 @@ class LabTests {
|
|
716
775
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
717
776
|
"X-Fern-Language": "JavaScript",
|
718
777
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
719
|
-
"X-Fern-SDK-Version": "3.0.
|
778
|
+
"X-Fern-SDK-Version": "3.0.7",
|
720
779
|
},
|
721
780
|
contentType: "application/json",
|
722
781
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -764,7 +823,7 @@ class LabTests {
|
|
764
823
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
765
824
|
"X-Fern-Language": "JavaScript",
|
766
825
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
767
|
-
"X-Fern-SDK-Version": "3.0.
|
826
|
+
"X-Fern-SDK-Version": "3.0.7",
|
768
827
|
},
|
769
828
|
contentType: "application/json",
|
770
829
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -828,7 +887,7 @@ class LabTests {
|
|
828
887
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
829
888
|
"X-Fern-Language": "JavaScript",
|
830
889
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
831
|
-
"X-Fern-SDK-Version": "3.0.
|
890
|
+
"X-Fern-SDK-Version": "3.0.7",
|
832
891
|
},
|
833
892
|
contentType: "application/json",
|
834
893
|
queryParameters: _queryParams,
|
@@ -875,55 +934,27 @@ class LabTests {
|
|
875
934
|
}
|
876
935
|
/**
|
877
936
|
* This endpoint returns the lab results for the order.
|
878
|
-
* @throws {@link Vital.UnprocessableEntityError}
|
879
937
|
*/
|
880
938
|
getResultPdf(orderId, requestOptions) {
|
881
939
|
var _a;
|
882
940
|
return __awaiter(this, void 0, void 0, function* () {
|
883
|
-
const _response = yield core.
|
941
|
+
const _response = yield core.streamingFetcher({
|
884
942
|
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}/result/pdf`),
|
885
943
|
method: "GET",
|
886
944
|
headers: {
|
887
945
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
888
946
|
"X-Fern-Language": "JavaScript",
|
889
947
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
890
|
-
"X-Fern-SDK-Version": "3.0.
|
948
|
+
"X-Fern-SDK-Version": "3.0.7",
|
891
949
|
},
|
892
|
-
contentType: "application/json",
|
893
950
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
894
|
-
|
895
|
-
if (_response.ok) {
|
896
|
-
return _response.body;
|
897
|
-
}
|
898
|
-
if (_response.error.reason === "status-code") {
|
899
|
-
switch (_response.error.statusCode) {
|
900
|
-
case 422:
|
901
|
-
throw new Vital.UnprocessableEntityError(yield serializers.HttpValidationError.parseOrThrow(_response.error.body, {
|
902
|
-
unrecognizedObjectKeys: "passthrough",
|
903
|
-
allowUnrecognizedUnionMembers: true,
|
904
|
-
allowUnrecognizedEnumValues: true,
|
905
|
-
breadcrumbsPrefix: ["response"],
|
906
|
-
}));
|
907
|
-
default:
|
908
|
-
throw new errors.VitalError({
|
909
|
-
statusCode: _response.error.statusCode,
|
910
|
-
body: _response.error.body,
|
911
|
-
});
|
912
|
-
}
|
913
|
-
}
|
914
|
-
switch (_response.error.reason) {
|
915
|
-
case "non-json":
|
951
|
+
onError: (error) => {
|
916
952
|
throw new errors.VitalError({
|
917
|
-
|
918
|
-
body: _response.error.rawBody,
|
953
|
+
message: error === null || error === void 0 ? void 0 : error.message,
|
919
954
|
});
|
920
|
-
|
921
|
-
|
922
|
-
|
923
|
-
throw new errors.VitalError({
|
924
|
-
message: _response.error.errorMessage,
|
925
|
-
});
|
926
|
-
}
|
955
|
+
},
|
956
|
+
});
|
957
|
+
return _response.data;
|
927
958
|
});
|
928
959
|
}
|
929
960
|
/**
|
@@ -941,7 +972,7 @@ class LabTests {
|
|
941
972
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
942
973
|
"X-Fern-Language": "JavaScript",
|
943
974
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
944
|
-
"X-Fern-SDK-Version": "3.0.
|
975
|
+
"X-Fern-SDK-Version": "3.0.7",
|
945
976
|
},
|
946
977
|
contentType: "application/json",
|
947
978
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -999,7 +1030,7 @@ class LabTests {
|
|
999
1030
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1000
1031
|
"X-Fern-Language": "JavaScript",
|
1001
1032
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1002
|
-
"X-Fern-SDK-Version": "3.0.
|
1033
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1003
1034
|
},
|
1004
1035
|
contentType: "application/json",
|
1005
1036
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1057,7 +1088,7 @@ class LabTests {
|
|
1057
1088
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1058
1089
|
"X-Fern-Language": "JavaScript",
|
1059
1090
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1060
|
-
"X-Fern-SDK-Version": "3.0.
|
1091
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1061
1092
|
},
|
1062
1093
|
contentType: "application/json",
|
1063
1094
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1110,7 +1141,7 @@ class LabTests {
|
|
1110
1141
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1111
1142
|
"X-Fern-Language": "JavaScript",
|
1112
1143
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1113
|
-
"X-Fern-SDK-Version": "3.0.
|
1144
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1114
1145
|
},
|
1115
1146
|
contentType: "application/json",
|
1116
1147
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1168,7 +1199,7 @@ class LabTests {
|
|
1168
1199
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1169
1200
|
"X-Fern-Language": "JavaScript",
|
1170
1201
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1171
|
-
"X-Fern-SDK-Version": "3.0.
|
1202
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1172
1203
|
},
|
1173
1204
|
contentType: "application/json",
|
1174
1205
|
body: yield serializers.CreateOrderRequestCompatible.jsonOrThrow(request, {
|
@@ -1229,7 +1260,7 @@ class LabTests {
|
|
1229
1260
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1230
1261
|
"X-Fern-Language": "JavaScript",
|
1231
1262
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1232
|
-
"X-Fern-SDK-Version": "3.0.
|
1263
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1233
1264
|
},
|
1234
1265
|
contentType: "application/json",
|
1235
1266
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -1295,7 +1326,7 @@ class LabTests {
|
|
1295
1326
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1296
1327
|
"X-Fern-Language": "JavaScript",
|
1297
1328
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1298
|
-
"X-Fern-SDK-Version": "3.0.
|
1329
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1299
1330
|
},
|
1300
1331
|
contentType: "application/json",
|
1301
1332
|
queryParameters: _queryParams,
|
@@ -1379,7 +1410,7 @@ class LabTests {
|
|
1379
1410
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
1380
1411
|
"X-Fern-Language": "JavaScript",
|
1381
1412
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
1382
|
-
"X-Fern-SDK-Version": "3.0.
|
1413
|
+
"X-Fern-SDK-Version": "3.0.7",
|
1383
1414
|
},
|
1384
1415
|
contentType: "application/json",
|
1385
1416
|
queryParameters: _queryParams,
|
@@ -0,0 +1,9 @@
|
|
1
|
+
/**
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
3
|
+
*/
|
4
|
+
import * as Vital from "../../../..";
|
5
|
+
export interface RequestAppointmentRequest {
|
6
|
+
/** At-home phlebotomy appointment address. */
|
7
|
+
address: Vital.UsAddress;
|
8
|
+
provider: Vital.AppointmentProvider;
|
9
|
+
}
|
@@ -2,6 +2,7 @@ export { CreateLabTestRequest } from "./CreateLabTestRequest";
|
|
2
2
|
export { LabTestsGetMarkersRequest } from "./LabTestsGetMarkersRequest";
|
3
3
|
export { LabTestsGetMarkersForLabTestRequest } from "./LabTestsGetMarkersForLabTestRequest";
|
4
4
|
export { AppointmentBookingRequest } from "./AppointmentBookingRequest";
|
5
|
+
export { RequestAppointmentRequest } from "./RequestAppointmentRequest";
|
5
6
|
export { AppointmentRescheduleRequest } from "./AppointmentRescheduleRequest";
|
6
7
|
export { AppointmentCancelRequest } from "./AppointmentCancelRequest";
|
7
8
|
export { LabTestsGetAreaInfoRequest } from "./LabTestsGetAreaInfoRequest";
|
@@ -46,7 +46,7 @@ export declare class Link {
|
|
46
46
|
* Check link token state - can be hit continuously used as heartbeat
|
47
47
|
* @throws {@link Vital.UnprocessableEntityError}
|
48
48
|
*/
|
49
|
-
tokenState(request
|
49
|
+
tokenState(request?: Vital.LinkTokenStateRequest, requestOptions?: Link.RequestOptions): Promise<Record<string, unknown>>;
|
50
50
|
/**
|
51
51
|
* REQUEST_SOURCE: VITAL-LINK
|
52
52
|
* PROVIDER_TYPE: EMAIL-AUTH
|
@@ -65,7 +65,7 @@ export declare class Link {
|
|
65
65
|
* This endpoint generates an OAuth link for oauth provider
|
66
66
|
* @throws {@link Vital.UnprocessableEntityError}
|
67
67
|
*/
|
68
|
-
generateOauthLink(oauthProvider: Vital.OAuthProviders, request
|
68
|
+
generateOauthLink(oauthProvider: Vital.OAuthProviders, request?: Vital.LinkGenerateOauthLinkRequest, requestOptions?: Link.RequestOptions): Promise<Vital.Source>;
|
69
69
|
/**
|
70
70
|
* This connects auth providers that are password based.
|
71
71
|
* @throws {@link Vital.UnprocessableEntityError}
|
@@ -80,7 +80,7 @@ export declare class Link {
|
|
80
80
|
* GET List of all available providers given the generated link token.
|
81
81
|
* @throws {@link Vital.UnprocessableEntityError}
|
82
82
|
*/
|
83
|
-
getAllProviders(request
|
83
|
+
getAllProviders(request?: Vital.LinkGetAllProvidersRequest, requestOptions?: Link.RequestOptions): Promise<Vital.SourceLink[]>;
|
84
84
|
/**
|
85
85
|
* REQUEST_SOURCE: CUSTOMER
|
86
86
|
* PROVIDER_TYPE: MANUAL-PROVIDER
|
@@ -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.7",
|
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.7",
|
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.7",
|
207
207
|
},
|
208
208
|
contentType: "application/json",
|
209
209
|
queryParameters: _queryParams,
|
@@ -263,7 +263,7 @@ class Link {
|
|
263
263
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
264
264
|
"X-Fern-Language": "JavaScript",
|
265
265
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
266
|
-
"X-Fern-SDK-Version": "3.0.
|
266
|
+
"X-Fern-SDK-Version": "3.0.7",
|
267
267
|
},
|
268
268
|
contentType: "application/json",
|
269
269
|
body: yield serializers.BeginLinkTokenRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -313,7 +313,7 @@ class Link {
|
|
313
313
|
* Check link token state - can be hit continuously used as heartbeat
|
314
314
|
* @throws {@link Vital.UnprocessableEntityError}
|
315
315
|
*/
|
316
|
-
tokenState(request, requestOptions) {
|
316
|
+
tokenState(request = {}, requestOptions) {
|
317
317
|
var _a;
|
318
318
|
return __awaiter(this, void 0, void 0, function* () {
|
319
319
|
const { vitalLinkToken } = request;
|
@@ -324,12 +324,8 @@ class Link {
|
|
324
324
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
325
325
|
"X-Fern-Language": "JavaScript",
|
326
326
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
327
|
-
"X-Fern-SDK-Version": "3.0.
|
328
|
-
"x-vital-link-token": vitalLinkToken != null
|
329
|
-
? typeof vitalLinkToken === "string"
|
330
|
-
? vitalLinkToken
|
331
|
-
: JSON.stringify(vitalLinkToken)
|
332
|
-
: undefined,
|
327
|
+
"X-Fern-SDK-Version": "3.0.7",
|
328
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
333
329
|
},
|
334
330
|
contentType: "application/json",
|
335
331
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -390,12 +386,8 @@ class Link {
|
|
390
386
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
391
387
|
"X-Fern-Language": "JavaScript",
|
392
388
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
393
|
-
"X-Fern-SDK-Version": "3.0.
|
394
|
-
"x-vital-link-token": vitalLinkToken != null
|
395
|
-
? typeof vitalLinkToken === "string"
|
396
|
-
? vitalLinkToken
|
397
|
-
: JSON.stringify(vitalLinkToken)
|
398
|
-
: undefined,
|
389
|
+
"X-Fern-SDK-Version": "3.0.7",
|
390
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
399
391
|
},
|
400
392
|
contentType: "application/json",
|
401
393
|
body: yield serializers.EmailAuthLink.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
|
@@ -457,13 +449,9 @@ class Link {
|
|
457
449
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
458
450
|
"X-Fern-Language": "JavaScript",
|
459
451
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
460
|
-
"X-Fern-SDK-Version": "3.0.
|
452
|
+
"X-Fern-SDK-Version": "3.0.7",
|
461
453
|
"x-vital-link-client-region": vitalLinkClientRegion != null ? vitalLinkClientRegion : undefined,
|
462
|
-
"x-vital-link-token": vitalLinkToken != null
|
463
|
-
? typeof vitalLinkToken === "string"
|
464
|
-
? vitalLinkToken
|
465
|
-
: JSON.stringify(vitalLinkToken)
|
466
|
-
: undefined,
|
454
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
467
455
|
},
|
468
456
|
contentType: "application/json",
|
469
457
|
body: yield serializers.PasswordAuthLink.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
|
@@ -512,7 +500,7 @@ class Link {
|
|
512
500
|
* This endpoint generates an OAuth link for oauth provider
|
513
501
|
* @throws {@link Vital.UnprocessableEntityError}
|
514
502
|
*/
|
515
|
-
generateOauthLink(oauthProvider, request, requestOptions) {
|
503
|
+
generateOauthLink(oauthProvider, request = {}, requestOptions) {
|
516
504
|
var _a;
|
517
505
|
return __awaiter(this, void 0, void 0, function* () {
|
518
506
|
const { vitalLinkToken } = request;
|
@@ -523,12 +511,8 @@ class Link {
|
|
523
511
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
524
512
|
"X-Fern-Language": "JavaScript",
|
525
513
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
526
|
-
"X-Fern-SDK-Version": "3.0.
|
527
|
-
"x-vital-link-token": vitalLinkToken != null
|
528
|
-
? typeof vitalLinkToken === "string"
|
529
|
-
? vitalLinkToken
|
530
|
-
: JSON.stringify(vitalLinkToken)
|
531
|
-
: undefined,
|
514
|
+
"X-Fern-SDK-Version": "3.0.7",
|
515
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
532
516
|
},
|
533
517
|
contentType: "application/json",
|
534
518
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -587,13 +571,9 @@ class Link {
|
|
587
571
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
588
572
|
"X-Fern-Language": "JavaScript",
|
589
573
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
590
|
-
"X-Fern-SDK-Version": "3.0.
|
574
|
+
"X-Fern-SDK-Version": "3.0.7",
|
591
575
|
"x-vital-link-client-region": vitalLinkClientRegion != null ? vitalLinkClientRegion : undefined,
|
592
|
-
"x-vital-link-token": vitalLinkToken != null
|
593
|
-
? typeof vitalLinkToken === "string"
|
594
|
-
? vitalLinkToken
|
595
|
-
: JSON.stringify(vitalLinkToken)
|
596
|
-
: undefined,
|
576
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
597
577
|
},
|
598
578
|
contentType: "application/json",
|
599
579
|
body: yield serializers.IndividualProviderData.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
|
@@ -653,12 +633,8 @@ class Link {
|
|
653
633
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
654
634
|
"X-Fern-Language": "JavaScript",
|
655
635
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
656
|
-
"X-Fern-SDK-Version": "3.0.
|
657
|
-
"x-vital-link-token": vitalLinkToken != null
|
658
|
-
? typeof vitalLinkToken === "string"
|
659
|
-
? vitalLinkToken
|
660
|
-
: JSON.stringify(vitalLinkToken)
|
661
|
-
: undefined,
|
636
|
+
"X-Fern-SDK-Version": "3.0.7",
|
637
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
662
638
|
},
|
663
639
|
contentType: "application/json",
|
664
640
|
body: yield serializers.EmailProviderAuthLink.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
|
@@ -707,7 +683,7 @@ class Link {
|
|
707
683
|
* GET List of all available providers given the generated link token.
|
708
684
|
* @throws {@link Vital.UnprocessableEntityError}
|
709
685
|
*/
|
710
|
-
getAllProviders(request, requestOptions) {
|
686
|
+
getAllProviders(request = {}, requestOptions) {
|
711
687
|
var _a;
|
712
688
|
return __awaiter(this, void 0, void 0, function* () {
|
713
689
|
const { vitalLinkToken } = request;
|
@@ -718,12 +694,8 @@ class Link {
|
|
718
694
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
719
695
|
"X-Fern-Language": "JavaScript",
|
720
696
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
721
|
-
"X-Fern-SDK-Version": "3.0.
|
722
|
-
"x-vital-link-token": vitalLinkToken != null
|
723
|
-
? typeof vitalLinkToken === "string"
|
724
|
-
? vitalLinkToken
|
725
|
-
: JSON.stringify(vitalLinkToken)
|
726
|
-
: undefined,
|
697
|
+
"X-Fern-SDK-Version": "3.0.7",
|
698
|
+
"x-vital-link-token": vitalLinkToken != null ? vitalLinkToken : undefined,
|
727
699
|
},
|
728
700
|
contentType: "application/json",
|
729
701
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
@@ -783,7 +755,7 @@ class Link {
|
|
783
755
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
784
756
|
"X-Fern-Language": "JavaScript",
|
785
757
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
786
|
-
"X-Fern-SDK-Version": "3.0.
|
758
|
+
"X-Fern-SDK-Version": "3.0.7",
|
787
759
|
},
|
788
760
|
contentType: "application/json",
|
789
761
|
body: yield serializers.ManualConnectionData.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
@@ -842,7 +814,7 @@ class Link {
|
|
842
814
|
"x-vital-api-key": yield core.Supplier.get(this._options.apiKey),
|
843
815
|
"X-Fern-Language": "JavaScript",
|
844
816
|
"X-Fern-SDK-Name": "@tryvital/vital-node",
|
845
|
-
"X-Fern-SDK-Version": "3.0.
|
817
|
+
"X-Fern-SDK-Version": "3.0.7",
|
846
818
|
},
|
847
819
|
contentType: "application/json",
|
848
820
|
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.7",
|
77
77
|
},
|
78
78
|
contentType: "application/json",
|
79
79
|
queryParameters: _queryParams,
|