@tryvital/vital-node 3.1.103 → 3.1.105

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (160) hide show
  1. package/Client.d.ts +3 -0
  2. package/Client.js +39 -34
  3. package/api/resources/activity/client/Client.js +2 -2
  4. package/api/resources/aggregate/client/Client.js +1 -1
  5. package/api/resources/body/client/Client.js +2 -2
  6. package/api/resources/devices/client/Client.js +1 -1
  7. package/api/resources/index.d.ts +2 -0
  8. package/api/resources/index.js +3 -1
  9. package/api/resources/insurance/client/Client.js +2 -2
  10. package/api/resources/introspect/client/Client.js +2 -2
  11. package/api/resources/labTests/client/Client.js +34 -34
  12. package/api/resources/link/client/Client.js +14 -14
  13. package/api/resources/link/client/requests/LinkTokenBase.d.ts +2 -0
  14. package/api/resources/meal/client/Client.js +1 -1
  15. package/api/resources/menstrualCycle/client/Client.js +1 -1
  16. package/api/resources/profile/client/Client.js +2 -2
  17. package/api/resources/providers/client/Client.js +1 -1
  18. package/api/resources/sleep/client/Client.js +4 -4
  19. package/api/resources/sleepCycle/client/Client.d.ts +42 -0
  20. package/api/resources/sleepCycle/client/Client.js +135 -0
  21. package/api/resources/sleepCycle/client/index.d.ts +1 -0
  22. package/api/resources/sleepCycle/client/index.js +17 -0
  23. package/api/resources/sleepCycle/client/requests/SleepCycleGetRequest.d.ts +17 -0
  24. package/api/resources/sleepCycle/client/requests/SleepCycleGetRequest.js +5 -0
  25. package/api/resources/sleepCycle/client/requests/index.d.ts +1 -0
  26. package/api/resources/sleepCycle/client/requests/index.js +2 -0
  27. package/api/resources/sleepCycle/index.d.ts +1 -0
  28. package/api/resources/sleepCycle/index.js +17 -0
  29. package/api/resources/team/client/Client.js +7 -7
  30. package/api/resources/testkit/client/Client.js +2 -2
  31. package/api/resources/user/client/Client.js +16 -16
  32. package/api/resources/vitals/client/Client.js +56 -56
  33. package/api/resources/workouts/client/Client.js +3 -3
  34. package/api/types/BiomarkerResult.d.ts +1 -0
  35. package/api/types/ClientSleepCycleResponse.d.ts +7 -0
  36. package/api/types/ClientSleepCycleResponse.js +5 -0
  37. package/api/types/Labs.d.ts +2 -1
  38. package/api/types/Labs.js +1 -0
  39. package/api/types/LinkRequirements.d.ts +9 -0
  40. package/api/types/LinkRequirements.js +5 -0
  41. package/api/types/MissingBiomarkerResult.d.ts +1 -0
  42. package/api/types/ParentBiomarkerData.d.ts +9 -0
  43. package/api/types/ParentBiomarkerData.js +5 -0
  44. package/api/types/SleepCycle.d.ts +17 -0
  45. package/api/types/SleepCycle.js +5 -0
  46. package/api/types/SleepCycleSourceProvider.d.ts +5 -0
  47. package/api/types/SleepCycleSourceProvider.js +5 -0
  48. package/api/types/SleepCycleSourceType.d.ts +19 -0
  49. package/api/types/SleepCycleSourceType.js +21 -0
  50. package/api/types/VitalSleepStage.d.ts +4 -0
  51. package/api/types/VitalSleepStage.js +5 -0
  52. package/api/types/index.d.ts +7 -0
  53. package/api/types/index.js +7 -0
  54. package/dist/Client.d.ts +3 -0
  55. package/dist/Client.js +39 -34
  56. package/dist/api/resources/activity/client/Client.js +2 -2
  57. package/dist/api/resources/aggregate/client/Client.js +1 -1
  58. package/dist/api/resources/body/client/Client.js +2 -2
  59. package/dist/api/resources/devices/client/Client.js +1 -1
  60. package/dist/api/resources/index.d.ts +2 -0
  61. package/dist/api/resources/index.js +3 -1
  62. package/dist/api/resources/insurance/client/Client.js +2 -2
  63. package/dist/api/resources/introspect/client/Client.js +2 -2
  64. package/dist/api/resources/labTests/client/Client.js +34 -34
  65. package/dist/api/resources/link/client/Client.js +14 -14
  66. package/dist/api/resources/link/client/requests/LinkTokenBase.d.ts +2 -0
  67. package/dist/api/resources/meal/client/Client.js +1 -1
  68. package/dist/api/resources/menstrualCycle/client/Client.js +1 -1
  69. package/dist/api/resources/profile/client/Client.js +2 -2
  70. package/dist/api/resources/providers/client/Client.js +1 -1
  71. package/dist/api/resources/sleep/client/Client.js +4 -4
  72. package/dist/api/resources/sleepCycle/client/Client.d.ts +42 -0
  73. package/dist/api/resources/sleepCycle/client/Client.js +135 -0
  74. package/dist/api/resources/sleepCycle/client/index.d.ts +1 -0
  75. package/dist/api/resources/sleepCycle/client/index.js +17 -0
  76. package/dist/api/resources/sleepCycle/client/requests/SleepCycleGetRequest.d.ts +17 -0
  77. package/dist/api/resources/sleepCycle/client/requests/SleepCycleGetRequest.js +5 -0
  78. package/dist/api/resources/sleepCycle/client/requests/index.d.ts +1 -0
  79. package/dist/api/resources/sleepCycle/client/requests/index.js +2 -0
  80. package/dist/api/resources/sleepCycle/index.d.ts +1 -0
  81. package/dist/api/resources/sleepCycle/index.js +17 -0
  82. package/dist/api/resources/team/client/Client.js +7 -7
  83. package/dist/api/resources/testkit/client/Client.js +2 -2
  84. package/dist/api/resources/user/client/Client.js +16 -16
  85. package/dist/api/resources/vitals/client/Client.js +56 -56
  86. package/dist/api/resources/workouts/client/Client.js +3 -3
  87. package/dist/api/types/BiomarkerResult.d.ts +1 -0
  88. package/dist/api/types/ClientSleepCycleResponse.d.ts +7 -0
  89. package/dist/api/types/ClientSleepCycleResponse.js +5 -0
  90. package/dist/api/types/Labs.d.ts +2 -1
  91. package/dist/api/types/Labs.js +1 -0
  92. package/dist/api/types/LinkRequirements.d.ts +9 -0
  93. package/dist/api/types/LinkRequirements.js +5 -0
  94. package/dist/api/types/MissingBiomarkerResult.d.ts +1 -0
  95. package/dist/api/types/ParentBiomarkerData.d.ts +9 -0
  96. package/dist/api/types/ParentBiomarkerData.js +5 -0
  97. package/dist/api/types/SleepCycle.d.ts +17 -0
  98. package/dist/api/types/SleepCycle.js +5 -0
  99. package/dist/api/types/SleepCycleSourceProvider.d.ts +5 -0
  100. package/dist/api/types/SleepCycleSourceProvider.js +5 -0
  101. package/dist/api/types/SleepCycleSourceType.d.ts +19 -0
  102. package/dist/api/types/SleepCycleSourceType.js +21 -0
  103. package/dist/api/types/VitalSleepStage.d.ts +4 -0
  104. package/dist/api/types/VitalSleepStage.js +5 -0
  105. package/dist/api/types/index.d.ts +7 -0
  106. package/dist/api/types/index.js +7 -0
  107. package/dist/serialization/resources/link/client/requests/LinkTokenBase.d.ts +2 -0
  108. package/dist/serialization/resources/link/client/requests/LinkTokenBase.js +2 -0
  109. package/dist/serialization/types/BiomarkerResult.d.ts +2 -0
  110. package/dist/serialization/types/BiomarkerResult.js +2 -0
  111. package/dist/serialization/types/ClientSleepCycleResponse.d.ts +13 -0
  112. package/dist/serialization/types/ClientSleepCycleResponse.js +34 -0
  113. package/dist/serialization/types/Labs.d.ts +1 -1
  114. package/dist/serialization/types/Labs.js +1 -0
  115. package/dist/serialization/types/LinkRequirements.d.ts +15 -0
  116. package/dist/serialization/types/LinkRequirements.js +36 -0
  117. package/dist/serialization/types/MissingBiomarkerResult.d.ts +2 -0
  118. package/dist/serialization/types/MissingBiomarkerResult.js +2 -0
  119. package/dist/serialization/types/ParentBiomarkerData.d.ts +15 -0
  120. package/dist/serialization/types/ParentBiomarkerData.js +36 -0
  121. package/dist/serialization/types/SleepCycle.d.ts +25 -0
  122. package/dist/serialization/types/SleepCycle.js +46 -0
  123. package/dist/serialization/types/SleepCycleSourceProvider.d.ts +12 -0
  124. package/dist/serialization/types/SleepCycleSourceProvider.js +33 -0
  125. package/dist/serialization/types/SleepCycleSourceType.d.ts +10 -0
  126. package/dist/serialization/types/SleepCycleSourceType.js +45 -0
  127. package/dist/serialization/types/VitalSleepStage.d.ts +10 -0
  128. package/dist/serialization/types/VitalSleepStage.js +31 -0
  129. package/dist/serialization/types/index.d.ts +7 -0
  130. package/dist/serialization/types/index.js +7 -0
  131. package/dist/version.d.ts +1 -1
  132. package/dist/version.js +1 -1
  133. package/package.json +1 -1
  134. package/reference.md +75 -0
  135. package/serialization/resources/link/client/requests/LinkTokenBase.d.ts +2 -0
  136. package/serialization/resources/link/client/requests/LinkTokenBase.js +2 -0
  137. package/serialization/types/BiomarkerResult.d.ts +2 -0
  138. package/serialization/types/BiomarkerResult.js +2 -0
  139. package/serialization/types/ClientSleepCycleResponse.d.ts +13 -0
  140. package/serialization/types/ClientSleepCycleResponse.js +34 -0
  141. package/serialization/types/Labs.d.ts +1 -1
  142. package/serialization/types/Labs.js +1 -0
  143. package/serialization/types/LinkRequirements.d.ts +15 -0
  144. package/serialization/types/LinkRequirements.js +36 -0
  145. package/serialization/types/MissingBiomarkerResult.d.ts +2 -0
  146. package/serialization/types/MissingBiomarkerResult.js +2 -0
  147. package/serialization/types/ParentBiomarkerData.d.ts +15 -0
  148. package/serialization/types/ParentBiomarkerData.js +36 -0
  149. package/serialization/types/SleepCycle.d.ts +25 -0
  150. package/serialization/types/SleepCycle.js +46 -0
  151. package/serialization/types/SleepCycleSourceProvider.d.ts +12 -0
  152. package/serialization/types/SleepCycleSourceProvider.js +33 -0
  153. package/serialization/types/SleepCycleSourceType.d.ts +10 -0
  154. package/serialization/types/SleepCycleSourceType.js +45 -0
  155. package/serialization/types/VitalSleepStage.d.ts +10 -0
  156. package/serialization/types/VitalSleepStage.js +31 -0
  157. package/serialization/types/index.d.ts +7 -0
  158. package/serialization/types/index.js +7 -0
  159. package/version.d.ts +1 -1
  160. package/version.js +1 -1
@@ -22,4 +22,5 @@ export interface BiomarkerResult {
22
22
  loinc?: string;
23
23
  loincSlug?: string;
24
24
  providerId?: string;
25
+ sourceMarkers?: Vital.ParentBiomarkerData[];
25
26
  }
@@ -0,0 +1,7 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Vital from "../index";
5
+ export interface ClientSleepCycleResponse {
6
+ sleepCycle: Vital.SleepCycle[];
7
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
- export declare type Labs = "ayumetrix" | "spiriplex" | "ussl" | "quest" | "labcorp" | "bioreference" | "us_biotek" | "manual" | "sanocardio";
4
+ export declare type Labs = "ayumetrix" | "spiriplex" | "ussl" | "quest" | "labcorp" | "bioreference" | "us_biotek" | "manual" | "sanocardio" | "ihd";
5
5
  export declare const Labs: {
6
6
  readonly Ayumetrix: "ayumetrix";
7
7
  readonly Spiriplex: "spiriplex";
@@ -12,4 +12,5 @@ export declare const Labs: {
12
12
  readonly UsBiotek: "us_biotek";
13
13
  readonly Manual: "manual";
14
14
  readonly Sanocardio: "sanocardio";
15
+ readonly Ihd: "ihd";
15
16
  };
@@ -14,4 +14,5 @@ exports.Labs = {
14
14
  UsBiotek: "us_biotek",
15
15
  Manual: "manual",
16
16
  Sanocardio: "sanocardio",
17
+ Ihd: "ihd",
17
18
  };
@@ -0,0 +1,9 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Vital from "../index";
5
+ export interface LinkRequirements {
6
+ provider?: Vital.Providers;
7
+ providerAllowlist?: Vital.Providers[];
8
+ redirectUrl?: string;
9
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -10,4 +10,5 @@ export interface MissingBiomarkerResult {
10
10
  loinc?: string;
11
11
  loincSlug?: string;
12
12
  providerId?: string;
13
+ sourceMarkers?: Vital.ParentBiomarkerData[];
13
14
  }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export interface ParentBiomarkerData {
5
+ markerId: number;
6
+ name: string;
7
+ slug: string;
8
+ providerId?: string;
9
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,17 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Vital from "../index";
5
+ export interface SleepCycle {
6
+ id: string;
7
+ sleepId: string;
8
+ sessionStart: Date;
9
+ sessionEnd: Date;
10
+ stageStartOffsetSecond: number[];
11
+ stageEndOffsetSecond: number[];
12
+ stageType: Vital.VitalSleepStage[];
13
+ timeZone?: string;
14
+ sourceProvider: Vital.SleepCycleSourceProvider;
15
+ sourceType: Vital.SleepCycleSourceType;
16
+ sourceAppId?: string;
17
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,5 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Vital from "../index";
5
+ export declare type SleepCycleSourceProvider = Vital.Providers | Vital.Labs;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,19 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export declare type SleepCycleSourceType = "unknown" | "phone" | "watch" | "app" | "multiple_sources" | "fingerprick" | "cuff" | "manual_scan" | "automatic" | "scale" | "chest_strap" | "ring" | "lab";
5
+ export declare const SleepCycleSourceType: {
6
+ readonly Unknown: "unknown";
7
+ readonly Phone: "phone";
8
+ readonly Watch: "watch";
9
+ readonly App: "app";
10
+ readonly MultipleSources: "multiple_sources";
11
+ readonly Fingerprick: "fingerprick";
12
+ readonly Cuff: "cuff";
13
+ readonly ManualScan: "manual_scan";
14
+ readonly Automatic: "automatic";
15
+ readonly Scale: "scale";
16
+ readonly ChestStrap: "chest_strap";
17
+ readonly Ring: "ring";
18
+ readonly Lab: "lab";
19
+ };
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.SleepCycleSourceType = void 0;
7
+ exports.SleepCycleSourceType = {
8
+ Unknown: "unknown",
9
+ Phone: "phone",
10
+ Watch: "watch",
11
+ App: "app",
12
+ MultipleSources: "multiple_sources",
13
+ Fingerprick: "fingerprick",
14
+ Cuff: "cuff",
15
+ ManualScan: "manual_scan",
16
+ Automatic: "automatic",
17
+ Scale: "scale",
18
+ ChestStrap: "chest_strap",
19
+ Ring: "ring",
20
+ Lab: "lab",
21
+ };
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export declare type VitalSleepStage = number;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -136,6 +136,7 @@ export * from "./ClientFacingWaterTimeseries";
136
136
  export * from "./ClientFacingWorkout";
137
137
  export * from "./ClientFacingWorkoutDurationSampleIntensity";
138
138
  export * from "./ClientFacingWorkoutDurationSample";
139
+ export * from "./ClientSleepCycleResponse";
139
140
  export * from "./ClientSleepResponse";
140
141
  export * from "./ClientUserIdConflict";
141
142
  export * from "./ClientWorkoutResponse";
@@ -199,6 +200,7 @@ export * from "./LabTestStatus";
199
200
  export * from "./Labs";
200
201
  export * from "./LastAttempt";
201
202
  export * from "./LibreConfig";
203
+ export * from "./LinkRequirements";
202
204
  export * from "./LinkTokenExchangeResponse";
203
205
  export * from "./LngLat";
204
206
  export * from "./Macros";
@@ -223,6 +225,7 @@ export * from "./PscAreaInfo";
223
225
  export * from "./PscAreaInfoDetails";
224
226
  export * from "./PscInfo";
225
227
  export * from "./PaginatedUsersResponse";
228
+ export * from "./ParentBiomarkerData";
226
229
  export * from "./PasswordProviders";
227
230
  export * from "./PatientAddressCompatible";
228
231
  export * from "./PatientDetails";
@@ -273,6 +276,9 @@ export * from "./SingleUserHistoricalPullResponse";
273
276
  export * from "./SingleUserResourceResponse";
274
277
  export * from "./SleepColumnExprSleep";
275
278
  export * from "./SleepColumnExpr";
279
+ export * from "./SleepCycleSourceProvider";
280
+ export * from "./SleepCycleSourceType";
281
+ export * from "./SleepCycle";
276
282
  export * from "./SleepScoreValueMacroExpr";
277
283
  export * from "./SleepSummaryState";
278
284
  export * from "./SleepType";
@@ -297,6 +303,7 @@ export * from "./UserSignInTokenResponse";
297
303
  export * from "./UserSuccessResponse";
298
304
  export * from "./ValidationErrorLocItem";
299
305
  export * from "./ValidationError";
306
+ export * from "./VitalSleepStage";
300
307
  export * from "./VitalTokenCreatedResponse";
301
308
  export * from "./Vitamins";
302
309
  export * from "./WorkoutColumnExprWorkout";
@@ -152,6 +152,7 @@ __exportStar(require("./ClientFacingWaterTimeseries"), exports);
152
152
  __exportStar(require("./ClientFacingWorkout"), exports);
153
153
  __exportStar(require("./ClientFacingWorkoutDurationSampleIntensity"), exports);
154
154
  __exportStar(require("./ClientFacingWorkoutDurationSample"), exports);
155
+ __exportStar(require("./ClientSleepCycleResponse"), exports);
155
156
  __exportStar(require("./ClientSleepResponse"), exports);
156
157
  __exportStar(require("./ClientUserIdConflict"), exports);
157
158
  __exportStar(require("./ClientWorkoutResponse"), exports);
@@ -215,6 +216,7 @@ __exportStar(require("./LabTestStatus"), exports);
215
216
  __exportStar(require("./Labs"), exports);
216
217
  __exportStar(require("./LastAttempt"), exports);
217
218
  __exportStar(require("./LibreConfig"), exports);
219
+ __exportStar(require("./LinkRequirements"), exports);
218
220
  __exportStar(require("./LinkTokenExchangeResponse"), exports);
219
221
  __exportStar(require("./LngLat"), exports);
220
222
  __exportStar(require("./Macros"), exports);
@@ -239,6 +241,7 @@ __exportStar(require("./PscAreaInfo"), exports);
239
241
  __exportStar(require("./PscAreaInfoDetails"), exports);
240
242
  __exportStar(require("./PscInfo"), exports);
241
243
  __exportStar(require("./PaginatedUsersResponse"), exports);
244
+ __exportStar(require("./ParentBiomarkerData"), exports);
242
245
  __exportStar(require("./PasswordProviders"), exports);
243
246
  __exportStar(require("./PatientAddressCompatible"), exports);
244
247
  __exportStar(require("./PatientDetails"), exports);
@@ -289,6 +292,9 @@ __exportStar(require("./SingleUserHistoricalPullResponse"), exports);
289
292
  __exportStar(require("./SingleUserResourceResponse"), exports);
290
293
  __exportStar(require("./SleepColumnExprSleep"), exports);
291
294
  __exportStar(require("./SleepColumnExpr"), exports);
295
+ __exportStar(require("./SleepCycleSourceProvider"), exports);
296
+ __exportStar(require("./SleepCycleSourceType"), exports);
297
+ __exportStar(require("./SleepCycle"), exports);
292
298
  __exportStar(require("./SleepScoreValueMacroExpr"), exports);
293
299
  __exportStar(require("./SleepSummaryState"), exports);
294
300
  __exportStar(require("./SleepType"), exports);
@@ -313,6 +319,7 @@ __exportStar(require("./UserSignInTokenResponse"), exports);
313
319
  __exportStar(require("./UserSuccessResponse"), exports);
314
320
  __exportStar(require("./ValidationErrorLocItem"), exports);
315
321
  __exportStar(require("./ValidationError"), exports);
322
+ __exportStar(require("./VitalSleepStage"), exports);
316
323
  __exportStar(require("./VitalTokenCreatedResponse"), exports);
317
324
  __exportStar(require("./Vitamins"), exports);
318
325
  __exportStar(require("./WorkoutColumnExprWorkout"), exports);
@@ -4,11 +4,13 @@
4
4
  import * as serializers from "../../../../index";
5
5
  import * as Vital from "../../../../../api/index";
6
6
  import * as core from "../../../../../core";
7
+ import { LinkRequirements } from "../../../../types/LinkRequirements";
7
8
  export declare const LinkTokenBase: core.serialization.Schema<serializers.LinkTokenBase.Raw, Vital.LinkTokenBase>;
8
9
  export declare namespace LinkTokenBase {
9
10
  interface Raw {
10
11
  token: string;
11
12
  is_used?: boolean | null;
12
13
  oauth_info?: Record<string, unknown> | null;
14
+ requirements?: LinkRequirements.Raw | null;
13
15
  }
14
16
  }
@@ -28,8 +28,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
29
  exports.LinkTokenBase = void 0;
30
30
  const core = __importStar(require("../../../../../core"));
31
+ const LinkRequirements_1 = require("../../../../types/LinkRequirements");
31
32
  exports.LinkTokenBase = core.serialization.object({
32
33
  token: core.serialization.string(),
33
34
  isUsed: core.serialization.property("is_used", core.serialization.boolean().optional()),
34
35
  oauthInfo: core.serialization.property("oauth_info", core.serialization.record(core.serialization.string(), core.serialization.unknown()).optional()),
36
+ requirements: LinkRequirements_1.LinkRequirements.optional(),
35
37
  });
@@ -5,6 +5,7 @@ import * as serializers from "../index";
5
5
  import * as Vital from "../../api/index";
6
6
  import * as core from "../../core";
7
7
  import { ResultType } from "./ResultType";
8
+ import { ParentBiomarkerData } from "./ParentBiomarkerData";
8
9
  export declare const BiomarkerResult: core.serialization.ObjectSchema<serializers.BiomarkerResult.Raw, Vital.BiomarkerResult>;
9
10
  export declare namespace BiomarkerResult {
10
11
  interface Raw {
@@ -24,5 +25,6 @@ export declare namespace BiomarkerResult {
24
25
  loinc?: string | null;
25
26
  loinc_slug?: string | null;
26
27
  provider_id?: string | null;
28
+ source_markers?: ParentBiomarkerData.Raw[] | null;
27
29
  }
28
30
  }
@@ -29,6 +29,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
29
29
  exports.BiomarkerResult = void 0;
30
30
  const core = __importStar(require("../../core"));
31
31
  const ResultType_1 = require("./ResultType");
32
+ const ParentBiomarkerData_1 = require("./ParentBiomarkerData");
32
33
  exports.BiomarkerResult = core.serialization.object({
33
34
  name: core.serialization.string(),
34
35
  slug: core.serialization.string().optional(),
@@ -46,4 +47,5 @@ exports.BiomarkerResult = core.serialization.object({
46
47
  loinc: core.serialization.string().optional(),
47
48
  loincSlug: core.serialization.property("loinc_slug", core.serialization.string().optional()),
48
49
  providerId: core.serialization.property("provider_id", core.serialization.string().optional()),
50
+ sourceMarkers: core.serialization.property("source_markers", core.serialization.list(ParentBiomarkerData_1.ParentBiomarkerData).optional()),
49
51
  });
@@ -0,0 +1,13 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../index";
5
+ import * as Vital from "../../api/index";
6
+ import * as core from "../../core";
7
+ import { SleepCycle } from "./SleepCycle";
8
+ export declare const ClientSleepCycleResponse: core.serialization.ObjectSchema<serializers.ClientSleepCycleResponse.Raw, Vital.ClientSleepCycleResponse>;
9
+ export declare namespace ClientSleepCycleResponse {
10
+ interface Raw {
11
+ sleep_cycle: SleepCycle.Raw[];
12
+ }
13
+ }
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.ClientSleepCycleResponse = void 0;
30
+ const core = __importStar(require("../../core"));
31
+ const SleepCycle_1 = require("./SleepCycle");
32
+ exports.ClientSleepCycleResponse = core.serialization.object({
33
+ sleepCycle: core.serialization.property("sleep_cycle", core.serialization.list(SleepCycle_1.SleepCycle)),
34
+ });
@@ -6,5 +6,5 @@ import * as Vital from "../../api/index";
6
6
  import * as core from "../../core";
7
7
  export declare const Labs: core.serialization.Schema<serializers.Labs.Raw, Vital.Labs>;
8
8
  export declare namespace Labs {
9
- type Raw = "ayumetrix" | "spiriplex" | "ussl" | "quest" | "labcorp" | "bioreference" | "us_biotek" | "manual" | "sanocardio";
9
+ type Raw = "ayumetrix" | "spiriplex" | "ussl" | "quest" | "labcorp" | "bioreference" | "us_biotek" | "manual" | "sanocardio" | "ihd";
10
10
  }
@@ -38,4 +38,5 @@ exports.Labs = core.serialization.enum_([
38
38
  "us_biotek",
39
39
  "manual",
40
40
  "sanocardio",
41
+ "ihd",
41
42
  ]);
@@ -0,0 +1,15 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../index";
5
+ import * as Vital from "../../api/index";
6
+ import * as core from "../../core";
7
+ import { Providers } from "./Providers";
8
+ export declare const LinkRequirements: core.serialization.ObjectSchema<serializers.LinkRequirements.Raw, Vital.LinkRequirements>;
9
+ export declare namespace LinkRequirements {
10
+ interface Raw {
11
+ provider?: Providers.Raw | null;
12
+ provider_allowlist?: Providers.Raw[] | null;
13
+ redirect_url?: string | null;
14
+ }
15
+ }
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.LinkRequirements = void 0;
30
+ const core = __importStar(require("../../core"));
31
+ const Providers_1 = require("./Providers");
32
+ exports.LinkRequirements = core.serialization.object({
33
+ provider: Providers_1.Providers.optional(),
34
+ providerAllowlist: core.serialization.property("provider_allowlist", core.serialization.list(Providers_1.Providers).optional()),
35
+ redirectUrl: core.serialization.property("redirect_url", core.serialization.string().optional()),
36
+ });
@@ -5,6 +5,7 @@ import * as serializers from "../index";
5
5
  import * as Vital from "../../api/index";
6
6
  import * as core from "../../core";
7
7
  import { FailureType } from "./FailureType";
8
+ import { ParentBiomarkerData } from "./ParentBiomarkerData";
8
9
  export declare const MissingBiomarkerResult: core.serialization.ObjectSchema<serializers.MissingBiomarkerResult.Raw, Vital.MissingBiomarkerResult>;
9
10
  export declare namespace MissingBiomarkerResult {
10
11
  interface Raw {
@@ -15,5 +16,6 @@ export declare namespace MissingBiomarkerResult {
15
16
  loinc?: string | null;
16
17
  loinc_slug?: string | null;
17
18
  provider_id?: string | null;
19
+ source_markers?: ParentBiomarkerData.Raw[] | null;
18
20
  }
19
21
  }
@@ -29,6 +29,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
29
29
  exports.MissingBiomarkerResult = void 0;
30
30
  const core = __importStar(require("../../core"));
31
31
  const FailureType_1 = require("./FailureType");
32
+ const ParentBiomarkerData_1 = require("./ParentBiomarkerData");
32
33
  exports.MissingBiomarkerResult = core.serialization.object({
33
34
  name: core.serialization.string(),
34
35
  slug: core.serialization.string(),
@@ -37,4 +38,5 @@ exports.MissingBiomarkerResult = core.serialization.object({
37
38
  loinc: core.serialization.string().optional(),
38
39
  loincSlug: core.serialization.property("loinc_slug", core.serialization.string().optional()),
39
40
  providerId: core.serialization.property("provider_id", core.serialization.string().optional()),
41
+ sourceMarkers: core.serialization.property("source_markers", core.serialization.list(ParentBiomarkerData_1.ParentBiomarkerData).optional()),
40
42
  });
@@ -0,0 +1,15 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../index";
5
+ import * as Vital from "../../api/index";
6
+ import * as core from "../../core";
7
+ export declare const ParentBiomarkerData: core.serialization.ObjectSchema<serializers.ParentBiomarkerData.Raw, Vital.ParentBiomarkerData>;
8
+ export declare namespace ParentBiomarkerData {
9
+ interface Raw {
10
+ marker_id: number;
11
+ name: string;
12
+ slug: string;
13
+ provider_id?: string | null;
14
+ }
15
+ }
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.ParentBiomarkerData = void 0;
30
+ const core = __importStar(require("../../core"));
31
+ exports.ParentBiomarkerData = core.serialization.object({
32
+ markerId: core.serialization.property("marker_id", core.serialization.number()),
33
+ name: core.serialization.string(),
34
+ slug: core.serialization.string(),
35
+ providerId: core.serialization.property("provider_id", core.serialization.string().optional()),
36
+ });
@@ -0,0 +1,25 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../index";
5
+ import * as Vital from "../../api/index";
6
+ import * as core from "../../core";
7
+ import { VitalSleepStage } from "./VitalSleepStage";
8
+ import { SleepCycleSourceProvider } from "./SleepCycleSourceProvider";
9
+ import { SleepCycleSourceType } from "./SleepCycleSourceType";
10
+ export declare const SleepCycle: core.serialization.ObjectSchema<serializers.SleepCycle.Raw, Vital.SleepCycle>;
11
+ export declare namespace SleepCycle {
12
+ interface Raw {
13
+ id: string;
14
+ sleep_id: string;
15
+ session_start: string;
16
+ session_end: string;
17
+ stage_start_offset_second: number[];
18
+ stage_end_offset_second: number[];
19
+ stage_type: VitalSleepStage.Raw[];
20
+ time_zone?: string | null;
21
+ source_provider: SleepCycleSourceProvider.Raw;
22
+ source_type: SleepCycleSourceType.Raw;
23
+ source_app_id?: string | null;
24
+ }
25
+ }
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.SleepCycle = void 0;
30
+ const core = __importStar(require("../../core"));
31
+ const VitalSleepStage_1 = require("./VitalSleepStage");
32
+ const SleepCycleSourceProvider_1 = require("./SleepCycleSourceProvider");
33
+ const SleepCycleSourceType_1 = require("./SleepCycleSourceType");
34
+ exports.SleepCycle = core.serialization.object({
35
+ id: core.serialization.string(),
36
+ sleepId: core.serialization.property("sleep_id", core.serialization.string()),
37
+ sessionStart: core.serialization.property("session_start", core.serialization.date()),
38
+ sessionEnd: core.serialization.property("session_end", core.serialization.date()),
39
+ stageStartOffsetSecond: core.serialization.property("stage_start_offset_second", core.serialization.list(core.serialization.number())),
40
+ stageEndOffsetSecond: core.serialization.property("stage_end_offset_second", core.serialization.list(core.serialization.number())),
41
+ stageType: core.serialization.property("stage_type", core.serialization.list(VitalSleepStage_1.VitalSleepStage)),
42
+ timeZone: core.serialization.property("time_zone", core.serialization.string().optional()),
43
+ sourceProvider: core.serialization.property("source_provider", SleepCycleSourceProvider_1.SleepCycleSourceProvider),
44
+ sourceType: core.serialization.property("source_type", SleepCycleSourceType_1.SleepCycleSourceType),
45
+ sourceAppId: core.serialization.property("source_app_id", core.serialization.string().optional()),
46
+ });
@@ -0,0 +1,12 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as serializers from "../index";
5
+ import * as Vital from "../../api/index";
6
+ import * as core from "../../core";
7
+ import { Providers } from "./Providers";
8
+ import { Labs } from "./Labs";
9
+ export declare const SleepCycleSourceProvider: core.serialization.Schema<serializers.SleepCycleSourceProvider.Raw, Vital.SleepCycleSourceProvider>;
10
+ export declare namespace SleepCycleSourceProvider {
11
+ type Raw = Providers.Raw | Labs.Raw;
12
+ }