saferx-pharma-sdk 0.0.39 → 0.0.42

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 (45) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/drugSafety/client/Client.d.ts +2 -30
  3. package/dist/cjs/api/resources/drugSafety/client/Client.js +2 -30
  4. package/dist/cjs/api/resources/drugSafety/client/requests/DrugSafetyCheckRequest.d.ts +0 -31
  5. package/dist/cjs/api/types/DrugSafetyCheckResponse.d.ts +0 -1
  6. package/dist/cjs/api/types/ReproductiveSafetyData.d.ts +3 -3
  7. package/dist/cjs/api/types/index.d.ts +0 -6
  8. package/dist/cjs/api/types/index.js +0 -6
  9. package/dist/cjs/version.d.ts +1 -1
  10. package/dist/cjs/version.js +1 -1
  11. package/dist/esm/BaseClient.mjs +2 -2
  12. package/dist/esm/api/resources/drugSafety/client/Client.d.mts +2 -30
  13. package/dist/esm/api/resources/drugSafety/client/Client.mjs +2 -30
  14. package/dist/esm/api/resources/drugSafety/client/requests/DrugSafetyCheckRequest.d.mts +0 -31
  15. package/dist/esm/api/types/DrugSafetyCheckResponse.d.mts +0 -1
  16. package/dist/esm/api/types/ReproductiveSafetyData.d.mts +3 -3
  17. package/dist/esm/api/types/index.d.mts +0 -6
  18. package/dist/esm/api/types/index.mjs +0 -6
  19. package/dist/esm/version.d.mts +1 -1
  20. package/dist/esm/version.mjs +1 -1
  21. package/package.json +1 -1
  22. package/dist/cjs/api/types/IntelligenceClinicalProfile.d.ts +0 -24
  23. package/dist/cjs/api/types/IntelligenceClinicalProfile.js +0 -13
  24. package/dist/cjs/api/types/IntelligenceContext.d.ts +0 -17
  25. package/dist/cjs/api/types/IntelligenceContext.js +0 -3
  26. package/dist/cjs/api/types/IntelligenceProcessorError.d.ts +0 -4
  27. package/dist/cjs/api/types/IntelligenceProcessorError.js +0 -3
  28. package/dist/cjs/api/types/IntelligenceResult.d.ts +0 -16
  29. package/dist/cjs/api/types/IntelligenceResult.js +0 -3
  30. package/dist/cjs/api/types/IntelligenceSynthesis.d.ts +0 -6
  31. package/dist/cjs/api/types/IntelligenceSynthesis.js +0 -3
  32. package/dist/cjs/api/types/MedicationHistoryItem.d.ts +0 -22
  33. package/dist/cjs/api/types/MedicationHistoryItem.js +0 -15
  34. package/dist/esm/api/types/IntelligenceClinicalProfile.d.mts +0 -24
  35. package/dist/esm/api/types/IntelligenceClinicalProfile.mjs +0 -10
  36. package/dist/esm/api/types/IntelligenceContext.d.mts +0 -17
  37. package/dist/esm/api/types/IntelligenceContext.mjs +0 -2
  38. package/dist/esm/api/types/IntelligenceProcessorError.d.mts +0 -4
  39. package/dist/esm/api/types/IntelligenceProcessorError.mjs +0 -2
  40. package/dist/esm/api/types/IntelligenceResult.d.mts +0 -16
  41. package/dist/esm/api/types/IntelligenceResult.mjs +0 -2
  42. package/dist/esm/api/types/IntelligenceSynthesis.d.mts +0 -6
  43. package/dist/esm/api/types/IntelligenceSynthesis.mjs +0 -2
  44. package/dist/esm/api/types/MedicationHistoryItem.d.mts +0 -22
  45. package/dist/esm/api/types/MedicationHistoryItem.mjs +0 -12
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
43
43
  const headers = (0, headers_js_1.mergeHeaders)({
44
44
  "X-Fern-Language": "JavaScript",
45
45
  "X-Fern-SDK-Name": "saferx-pharma-sdk",
46
- "X-Fern-SDK-Version": "0.0.39",
47
- "User-Agent": "saferx-pharma-sdk/0.0.39",
46
+ "X-Fern-SDK-Version": "0.0.42",
47
+ "User-Agent": "saferx-pharma-sdk/0.0.42",
48
48
  "X-Fern-Runtime": core.RUNTIME.type,
49
49
  "X-Fern-Runtime-Version": core.RUNTIME.version,
50
50
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -20,6 +20,8 @@ export declare class DrugSafetyClient {
20
20
  * checks in parallel, and returns a unified response with alerts bubbled to
21
21
  * the top for easy triage.
22
22
  *
23
+ * This endpoint is API-key only. It does not require `X-SafeRx-Token`.
24
+ *
23
25
  * **Typical response time:** ~40ms (warm cache, 3 drugs, all domains).
24
26
  *
25
27
  * @param {SafeRx.DrugSafetyCheckRequest} request
@@ -51,36 +53,6 @@ export declare class DrugSafetyClient {
51
53
  * @example
52
54
  * await client.drugSafety.check({
53
55
  * drugs: ["Augmentin 1g", "Marivan"],
54
- * intelligence_context: {
55
- * user_id: "patient-123",
56
- * clinical_profile: {
57
- * age: 72,
58
- * crcl: 38,
59
- * hepatic_status: "normal",
60
- * pregnancy: false,
61
- * lactation: false,
62
- * conditions: ["renal impairment", "hypertension"],
63
- * populations: ["geriatric", "renal"],
64
- * allergies: ["penicillin"],
65
- * diet_habits: ["low_sodium"]
66
- * },
67
- * medication_history: [{
68
- * sfrx_id: "SRX-010-004748",
69
- * start_date: "2026-01-10",
70
- * status: "active"
71
- * }, {
72
- * sfrx_id: "SRX-050-000123",
73
- * start_date: "2025-09-01",
74
- * status: "historical"
75
- * }]
76
- * },
77
- * include: ["ae", "ddi", "pllr", "clinical", "dose"],
78
- * lang: "en"
79
- * })
80
- *
81
- * @example
82
- * await client.drugSafety.check({
83
- * drugs: ["Augmentin 1g", "Marivan"],
84
56
  * include: ["ddi"]
85
57
  * })
86
58
  *
@@ -65,6 +65,8 @@ class DrugSafetyClient {
65
65
  * checks in parallel, and returns a unified response with alerts bubbled to
66
66
  * the top for easy triage.
67
67
  *
68
+ * This endpoint is API-key only. It does not require `X-SafeRx-Token`.
69
+ *
68
70
  * **Typical response time:** ~40ms (warm cache, 3 drugs, all domains).
69
71
  *
70
72
  * @param {SafeRx.DrugSafetyCheckRequest} request
@@ -96,36 +98,6 @@ class DrugSafetyClient {
96
98
  * @example
97
99
  * await client.drugSafety.check({
98
100
  * drugs: ["Augmentin 1g", "Marivan"],
99
- * intelligence_context: {
100
- * user_id: "patient-123",
101
- * clinical_profile: {
102
- * age: 72,
103
- * crcl: 38,
104
- * hepatic_status: "normal",
105
- * pregnancy: false,
106
- * lactation: false,
107
- * conditions: ["renal impairment", "hypertension"],
108
- * populations: ["geriatric", "renal"],
109
- * allergies: ["penicillin"],
110
- * diet_habits: ["low_sodium"]
111
- * },
112
- * medication_history: [{
113
- * sfrx_id: "SRX-010-004748",
114
- * start_date: "2026-01-10",
115
- * status: "active"
116
- * }, {
117
- * sfrx_id: "SRX-050-000123",
118
- * start_date: "2025-09-01",
119
- * status: "historical"
120
- * }]
121
- * },
122
- * include: ["ae", "ddi", "pllr", "clinical", "dose"],
123
- * lang: "en"
124
- * })
125
- *
126
- * @example
127
- * await client.drugSafety.check({
128
- * drugs: ["Augmentin 1g", "Marivan"],
129
101
  * include: ["ddi"]
130
102
  * })
131
103
  *
@@ -20,36 +20,6 @@ import type * as SafeRx from "../../../../index.js";
20
20
  * @example
21
21
  * {
22
22
  * drugs: ["Augmentin 1g", "Marivan"],
23
- * intelligence_context: {
24
- * user_id: "patient-123",
25
- * clinical_profile: {
26
- * age: 72,
27
- * crcl: 38,
28
- * hepatic_status: "normal",
29
- * pregnancy: false,
30
- * lactation: false,
31
- * conditions: ["renal impairment", "hypertension"],
32
- * populations: ["geriatric", "renal"],
33
- * allergies: ["penicillin"],
34
- * diet_habits: ["low_sodium"]
35
- * },
36
- * medication_history: [{
37
- * sfrx_id: "SRX-010-004748",
38
- * start_date: "2026-01-10",
39
- * status: "active"
40
- * }, {
41
- * sfrx_id: "SRX-050-000123",
42
- * start_date: "2025-09-01",
43
- * status: "historical"
44
- * }]
45
- * },
46
- * include: ["ae", "ddi", "pllr", "clinical", "dose"],
47
- * lang: "en"
48
- * }
49
- *
50
- * @example
51
- * {
52
- * drugs: ["Augmentin 1g", "Marivan"],
53
23
  * include: ["ddi"]
54
24
  * }
55
25
  *
@@ -70,7 +40,6 @@ export interface DrugSafetyCheckRequest {
70
40
  */
71
41
  drugs: string[];
72
42
  patient_profile?: SafeRx.PatientProfile;
73
- intelligence_context?: SafeRx.IntelligenceContext;
74
43
  /**
75
44
  * Safety domains to check. Omit to run all six domains.
76
45
  * Including fewer domains reduces response size and may improve latency.
@@ -18,7 +18,6 @@ export interface DrugSafetyCheckResponse {
18
18
  */
19
19
  alerts: SafeRx.Alert[];
20
20
  meta: SafeRx.Meta;
21
- intelligence?: SafeRx.IntelligenceResult | undefined;
22
21
  }
23
22
  export declare namespace DrugSafetyCheckResponse {
24
23
  /** Always `"success"` for 200 responses */
@@ -32,19 +32,19 @@ export interface ReproductiveSafetyData {
32
32
  pregnancy_warning?: SafeRx.ReproductiveWarning | undefined;
33
33
  lactation_warning?: SafeRx.ReproductiveWarning | undefined;
34
34
  /** First trimester pregnancy risk classification */
35
- preg_t1_risk?: (string | null) | undefined;
35
+ preg_t1_risk?: (number | null) | undefined;
36
36
  /** First trimester clinical note */
37
37
  preg_t1_note?: (string | null) | undefined;
38
38
  /** First trimester note in Arabic */
39
39
  preg_t1_note_ar?: (string | null) | undefined;
40
40
  /** Second trimester pregnancy risk classification */
41
- preg_t2_risk?: (string | null) | undefined;
41
+ preg_t2_risk?: (number | null) | undefined;
42
42
  /** Second trimester clinical note */
43
43
  preg_t2_note?: (string | null) | undefined;
44
44
  /** Second trimester note in Arabic */
45
45
  preg_t2_note_ar?: (string | null) | undefined;
46
46
  /** Third trimester pregnancy risk classification */
47
- preg_t3_risk?: (string | null) | undefined;
47
+ preg_t3_risk?: (number | null) | undefined;
48
48
  /** Third trimester clinical note */
49
49
  preg_t3_note?: (string | null) | undefined;
50
50
  /** Third trimester note in Arabic */
@@ -18,17 +18,11 @@ export * from "./ErrorResponse.js";
18
18
  export * from "./FoodConflict.js";
19
19
  export * from "./FoodData.js";
20
20
  export * from "./ForbiddenErrorBody.js";
21
- export * from "./IntelligenceClinicalProfile.js";
22
- export * from "./IntelligenceContext.js";
23
- export * from "./IntelligenceProcessorError.js";
24
- export * from "./IntelligenceResult.js";
25
- export * from "./IntelligenceSynthesis.js";
26
21
  export * from "./Interaction.js";
27
22
  export * from "./InteractionSummary.js";
28
23
  export * from "./InteractionsData.js";
29
24
  export * from "./InternalServerErrorBody.js";
30
25
  export * from "./MealTiming.js";
31
- export * from "./MedicationHistoryItem.js";
32
26
  export * from "./Meta.js";
33
27
  export * from "./MetadataResponse.js";
34
28
  export * from "./Monitoring.js";
@@ -34,17 +34,11 @@ __exportStar(require("./ErrorResponse.js"), exports);
34
34
  __exportStar(require("./FoodConflict.js"), exports);
35
35
  __exportStar(require("./FoodData.js"), exports);
36
36
  __exportStar(require("./ForbiddenErrorBody.js"), exports);
37
- __exportStar(require("./IntelligenceClinicalProfile.js"), exports);
38
- __exportStar(require("./IntelligenceContext.js"), exports);
39
- __exportStar(require("./IntelligenceProcessorError.js"), exports);
40
- __exportStar(require("./IntelligenceResult.js"), exports);
41
- __exportStar(require("./IntelligenceSynthesis.js"), exports);
42
37
  __exportStar(require("./Interaction.js"), exports);
43
38
  __exportStar(require("./InteractionSummary.js"), exports);
44
39
  __exportStar(require("./InteractionsData.js"), exports);
45
40
  __exportStar(require("./InternalServerErrorBody.js"), exports);
46
41
  __exportStar(require("./MealTiming.js"), exports);
47
- __exportStar(require("./MedicationHistoryItem.js"), exports);
48
42
  __exportStar(require("./Meta.js"), exports);
49
43
  __exportStar(require("./MetadataResponse.js"), exports);
50
44
  __exportStar(require("./Monitoring.js"), exports);
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "0.0.39";
1
+ export declare const SDK_VERSION = "0.0.42";
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = "0.0.39";
4
+ exports.SDK_VERSION = "0.0.42";
@@ -6,8 +6,8 @@ export function normalizeClientOptions(options) {
6
6
  const headers = mergeHeaders({
7
7
  "X-Fern-Language": "JavaScript",
8
8
  "X-Fern-SDK-Name": "saferx-pharma-sdk",
9
- "X-Fern-SDK-Version": "0.0.39",
10
- "User-Agent": "saferx-pharma-sdk/0.0.39",
9
+ "X-Fern-SDK-Version": "0.0.42",
10
+ "User-Agent": "saferx-pharma-sdk/0.0.42",
11
11
  "X-Fern-Runtime": core.RUNTIME.type,
12
12
  "X-Fern-Runtime-Version": core.RUNTIME.version,
13
13
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -20,6 +20,8 @@ export declare class DrugSafetyClient {
20
20
  * checks in parallel, and returns a unified response with alerts bubbled to
21
21
  * the top for easy triage.
22
22
  *
23
+ * This endpoint is API-key only. It does not require `X-SafeRx-Token`.
24
+ *
23
25
  * **Typical response time:** ~40ms (warm cache, 3 drugs, all domains).
24
26
  *
25
27
  * @param {SafeRx.DrugSafetyCheckRequest} request
@@ -51,36 +53,6 @@ export declare class DrugSafetyClient {
51
53
  * @example
52
54
  * await client.drugSafety.check({
53
55
  * drugs: ["Augmentin 1g", "Marivan"],
54
- * intelligence_context: {
55
- * user_id: "patient-123",
56
- * clinical_profile: {
57
- * age: 72,
58
- * crcl: 38,
59
- * hepatic_status: "normal",
60
- * pregnancy: false,
61
- * lactation: false,
62
- * conditions: ["renal impairment", "hypertension"],
63
- * populations: ["geriatric", "renal"],
64
- * allergies: ["penicillin"],
65
- * diet_habits: ["low_sodium"]
66
- * },
67
- * medication_history: [{
68
- * sfrx_id: "SRX-010-004748",
69
- * start_date: "2026-01-10",
70
- * status: "active"
71
- * }, {
72
- * sfrx_id: "SRX-050-000123",
73
- * start_date: "2025-09-01",
74
- * status: "historical"
75
- * }]
76
- * },
77
- * include: ["ae", "ddi", "pllr", "clinical", "dose"],
78
- * lang: "en"
79
- * })
80
- *
81
- * @example
82
- * await client.drugSafety.check({
83
- * drugs: ["Augmentin 1g", "Marivan"],
84
56
  * include: ["ddi"]
85
57
  * })
86
58
  *
@@ -29,6 +29,8 @@ export class DrugSafetyClient {
29
29
  * checks in parallel, and returns a unified response with alerts bubbled to
30
30
  * the top for easy triage.
31
31
  *
32
+ * This endpoint is API-key only. It does not require `X-SafeRx-Token`.
33
+ *
32
34
  * **Typical response time:** ~40ms (warm cache, 3 drugs, all domains).
33
35
  *
34
36
  * @param {SafeRx.DrugSafetyCheckRequest} request
@@ -60,36 +62,6 @@ export class DrugSafetyClient {
60
62
  * @example
61
63
  * await client.drugSafety.check({
62
64
  * drugs: ["Augmentin 1g", "Marivan"],
63
- * intelligence_context: {
64
- * user_id: "patient-123",
65
- * clinical_profile: {
66
- * age: 72,
67
- * crcl: 38,
68
- * hepatic_status: "normal",
69
- * pregnancy: false,
70
- * lactation: false,
71
- * conditions: ["renal impairment", "hypertension"],
72
- * populations: ["geriatric", "renal"],
73
- * allergies: ["penicillin"],
74
- * diet_habits: ["low_sodium"]
75
- * },
76
- * medication_history: [{
77
- * sfrx_id: "SRX-010-004748",
78
- * start_date: "2026-01-10",
79
- * status: "active"
80
- * }, {
81
- * sfrx_id: "SRX-050-000123",
82
- * start_date: "2025-09-01",
83
- * status: "historical"
84
- * }]
85
- * },
86
- * include: ["ae", "ddi", "pllr", "clinical", "dose"],
87
- * lang: "en"
88
- * })
89
- *
90
- * @example
91
- * await client.drugSafety.check({
92
- * drugs: ["Augmentin 1g", "Marivan"],
93
65
  * include: ["ddi"]
94
66
  * })
95
67
  *
@@ -20,36 +20,6 @@ import type * as SafeRx from "../../../../index.mjs";
20
20
  * @example
21
21
  * {
22
22
  * drugs: ["Augmentin 1g", "Marivan"],
23
- * intelligence_context: {
24
- * user_id: "patient-123",
25
- * clinical_profile: {
26
- * age: 72,
27
- * crcl: 38,
28
- * hepatic_status: "normal",
29
- * pregnancy: false,
30
- * lactation: false,
31
- * conditions: ["renal impairment", "hypertension"],
32
- * populations: ["geriatric", "renal"],
33
- * allergies: ["penicillin"],
34
- * diet_habits: ["low_sodium"]
35
- * },
36
- * medication_history: [{
37
- * sfrx_id: "SRX-010-004748",
38
- * start_date: "2026-01-10",
39
- * status: "active"
40
- * }, {
41
- * sfrx_id: "SRX-050-000123",
42
- * start_date: "2025-09-01",
43
- * status: "historical"
44
- * }]
45
- * },
46
- * include: ["ae", "ddi", "pllr", "clinical", "dose"],
47
- * lang: "en"
48
- * }
49
- *
50
- * @example
51
- * {
52
- * drugs: ["Augmentin 1g", "Marivan"],
53
23
  * include: ["ddi"]
54
24
  * }
55
25
  *
@@ -70,7 +40,6 @@ export interface DrugSafetyCheckRequest {
70
40
  */
71
41
  drugs: string[];
72
42
  patient_profile?: SafeRx.PatientProfile;
73
- intelligence_context?: SafeRx.IntelligenceContext;
74
43
  /**
75
44
  * Safety domains to check. Omit to run all six domains.
76
45
  * Including fewer domains reduces response size and may improve latency.
@@ -18,7 +18,6 @@ export interface DrugSafetyCheckResponse {
18
18
  */
19
19
  alerts: SafeRx.Alert[];
20
20
  meta: SafeRx.Meta;
21
- intelligence?: SafeRx.IntelligenceResult | undefined;
22
21
  }
23
22
  export declare namespace DrugSafetyCheckResponse {
24
23
  /** Always `"success"` for 200 responses */
@@ -32,19 +32,19 @@ export interface ReproductiveSafetyData {
32
32
  pregnancy_warning?: SafeRx.ReproductiveWarning | undefined;
33
33
  lactation_warning?: SafeRx.ReproductiveWarning | undefined;
34
34
  /** First trimester pregnancy risk classification */
35
- preg_t1_risk?: (string | null) | undefined;
35
+ preg_t1_risk?: (number | null) | undefined;
36
36
  /** First trimester clinical note */
37
37
  preg_t1_note?: (string | null) | undefined;
38
38
  /** First trimester note in Arabic */
39
39
  preg_t1_note_ar?: (string | null) | undefined;
40
40
  /** Second trimester pregnancy risk classification */
41
- preg_t2_risk?: (string | null) | undefined;
41
+ preg_t2_risk?: (number | null) | undefined;
42
42
  /** Second trimester clinical note */
43
43
  preg_t2_note?: (string | null) | undefined;
44
44
  /** Second trimester note in Arabic */
45
45
  preg_t2_note_ar?: (string | null) | undefined;
46
46
  /** Third trimester pregnancy risk classification */
47
- preg_t3_risk?: (string | null) | undefined;
47
+ preg_t3_risk?: (number | null) | undefined;
48
48
  /** Third trimester clinical note */
49
49
  preg_t3_note?: (string | null) | undefined;
50
50
  /** Third trimester note in Arabic */
@@ -18,17 +18,11 @@ export * from "./ErrorResponse.mjs";
18
18
  export * from "./FoodConflict.mjs";
19
19
  export * from "./FoodData.mjs";
20
20
  export * from "./ForbiddenErrorBody.mjs";
21
- export * from "./IntelligenceClinicalProfile.mjs";
22
- export * from "./IntelligenceContext.mjs";
23
- export * from "./IntelligenceProcessorError.mjs";
24
- export * from "./IntelligenceResult.mjs";
25
- export * from "./IntelligenceSynthesis.mjs";
26
21
  export * from "./Interaction.mjs";
27
22
  export * from "./InteractionSummary.mjs";
28
23
  export * from "./InteractionsData.mjs";
29
24
  export * from "./InternalServerErrorBody.mjs";
30
25
  export * from "./MealTiming.mjs";
31
- export * from "./MedicationHistoryItem.mjs";
32
26
  export * from "./Meta.mjs";
33
27
  export * from "./MetadataResponse.mjs";
34
28
  export * from "./Monitoring.mjs";
@@ -18,17 +18,11 @@ export * from "./ErrorResponse.mjs";
18
18
  export * from "./FoodConflict.mjs";
19
19
  export * from "./FoodData.mjs";
20
20
  export * from "./ForbiddenErrorBody.mjs";
21
- export * from "./IntelligenceClinicalProfile.mjs";
22
- export * from "./IntelligenceContext.mjs";
23
- export * from "./IntelligenceProcessorError.mjs";
24
- export * from "./IntelligenceResult.mjs";
25
- export * from "./IntelligenceSynthesis.mjs";
26
21
  export * from "./Interaction.mjs";
27
22
  export * from "./InteractionSummary.mjs";
28
23
  export * from "./InteractionsData.mjs";
29
24
  export * from "./InternalServerErrorBody.mjs";
30
25
  export * from "./MealTiming.mjs";
31
- export * from "./MedicationHistoryItem.mjs";
32
26
  export * from "./Meta.mjs";
33
27
  export * from "./MetadataResponse.mjs";
34
28
  export * from "./Monitoring.mjs";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "0.0.39";
1
+ export declare const SDK_VERSION = "0.0.42";
@@ -1 +1 @@
1
- export const SDK_VERSION = "0.0.39";
1
+ export const SDK_VERSION = "0.0.42";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "saferx-pharma-sdk",
3
- "version": "0.0.39",
3
+ "version": "0.0.42",
4
4
  "private": false,
5
5
  "type": "commonjs",
6
6
  "main": "./dist/cjs/index.js",
@@ -1,24 +0,0 @@
1
- /**
2
- * Patient profile fields used by intelligence processors.
3
- */
4
- export interface IntelligenceClinicalProfile {
5
- age?: number | undefined;
6
- /** Creatinine clearance in mL/min. */
7
- crcl?: number | undefined;
8
- hepatic_status?: IntelligenceClinicalProfile.HepaticStatus | undefined;
9
- pregnancy?: boolean | undefined;
10
- lactation?: boolean | undefined;
11
- conditions?: string[] | undefined;
12
- populations?: string[] | undefined;
13
- allergies?: string[] | undefined;
14
- diet_habits?: string[] | undefined;
15
- }
16
- export declare namespace IntelligenceClinicalProfile {
17
- const HepaticStatus: {
18
- readonly Normal: "normal";
19
- readonly Mild: "mild";
20
- readonly Moderate: "moderate";
21
- readonly Severe: "severe";
22
- };
23
- type HepaticStatus = (typeof HepaticStatus)[keyof typeof HepaticStatus];
24
- }
@@ -1,13 +0,0 @@
1
- "use strict";
2
- // This file was auto-generated by Fern from our API Definition.
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.IntelligenceClinicalProfile = void 0;
5
- var IntelligenceClinicalProfile;
6
- (function (IntelligenceClinicalProfile) {
7
- IntelligenceClinicalProfile.HepaticStatus = {
8
- Normal: "normal",
9
- Mild: "mild",
10
- Moderate: "moderate",
11
- Severe: "severe",
12
- };
13
- })(IntelligenceClinicalProfile || (exports.IntelligenceClinicalProfile = IntelligenceClinicalProfile = {}));
@@ -1,17 +0,0 @@
1
- import type * as SafeRx from "../index.js";
2
- /**
3
- * Optional Medication Intelligence Platform context. When present and the
4
- * intelligence layer is enabled, SafeRx adds a top-level `intelligence`
5
- * block without changing the standard safety response.
6
- */
7
- export interface IntelligenceContext {
8
- /** Optional caller-side patient or profile identifier. */
9
- user_id?: string | undefined;
10
- clinical_profile?: SafeRx.IntelligenceClinicalProfile | undefined;
11
- /**
12
- * Longitudinal medication list used for active-medication cumulative
13
- * dose tracking. Items with `status: historical` are retained as
14
- * context but excluded from active overdose aggregation.
15
- */
16
- medication_history?: SafeRx.MedicationHistoryItem[] | undefined;
17
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- // This file was auto-generated by Fern from our API Definition.
3
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,4 +0,0 @@
1
- export interface IntelligenceProcessorError {
2
- processor?: string | undefined;
3
- error?: string | undefined;
4
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- // This file was auto-generated by Fern from our API Definition.
3
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,16 +0,0 @@
1
- import type * as SafeRx from "../index.js";
2
- /**
3
- * Optional Medication Intelligence Platform post-processing output.
4
- */
5
- export interface IntelligenceResult {
6
- status?: string | undefined;
7
- /** Active-medication cumulative dose warnings. */
8
- cumulative_warnings?: Record<string, unknown>[] | undefined;
9
- synthesis?: SafeRx.IntelligenceSynthesis | undefined;
10
- /** Allergy/profile-filtered alternative candidates keyed by source `sfrx_id`. */
11
- safer_alternatives?: Record<string, unknown> | undefined;
12
- /** Best-effort processor errors; standard safety output remains valid. */
13
- processor_errors?: SafeRx.IntelligenceProcessorError[] | undefined;
14
- /** Top-level degradation reason when the whole intelligence layer fails. */
15
- error?: string | undefined;
16
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- // This file was auto-generated by Fern from our API Definition.
3
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,6 +0,0 @@
1
- export interface IntelligenceSynthesis {
2
- cross_domain_findings?: Record<string, unknown>[] | undefined;
3
- summary?: string | undefined;
4
- /** Condition-specific adverse effects elevated for the supplied context. */
5
- predictive_ae?: Record<string, unknown>[] | undefined;
6
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- // This file was auto-generated by Fern from our API Definition.
3
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,22 +0,0 @@
1
- export interface MedicationHistoryItem {
2
- /** SafeRx product identifier. */
3
- sfrx_id: string;
4
- /** Caller-provided start date, preferably ISO 8601. */
5
- start_date?: string | undefined;
6
- /**
7
- * Active medications participate in cumulative dose checks.
8
- * Historical medications are retained as context only.
9
- */
10
- status?: MedicationHistoryItem.Status | undefined;
11
- }
12
- export declare namespace MedicationHistoryItem {
13
- /**
14
- * Active medications participate in cumulative dose checks.
15
- * Historical medications are retained as context only.
16
- */
17
- const Status: {
18
- readonly Active: "active";
19
- readonly Historical: "historical";
20
- };
21
- type Status = (typeof Status)[keyof typeof Status];
22
- }
@@ -1,15 +0,0 @@
1
- "use strict";
2
- // This file was auto-generated by Fern from our API Definition.
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.MedicationHistoryItem = void 0;
5
- var MedicationHistoryItem;
6
- (function (MedicationHistoryItem) {
7
- /**
8
- * Active medications participate in cumulative dose checks.
9
- * Historical medications are retained as context only.
10
- */
11
- MedicationHistoryItem.Status = {
12
- Active: "active",
13
- Historical: "historical",
14
- };
15
- })(MedicationHistoryItem || (exports.MedicationHistoryItem = MedicationHistoryItem = {}));
@@ -1,24 +0,0 @@
1
- /**
2
- * Patient profile fields used by intelligence processors.
3
- */
4
- export interface IntelligenceClinicalProfile {
5
- age?: number | undefined;
6
- /** Creatinine clearance in mL/min. */
7
- crcl?: number | undefined;
8
- hepatic_status?: IntelligenceClinicalProfile.HepaticStatus | undefined;
9
- pregnancy?: boolean | undefined;
10
- lactation?: boolean | undefined;
11
- conditions?: string[] | undefined;
12
- populations?: string[] | undefined;
13
- allergies?: string[] | undefined;
14
- diet_habits?: string[] | undefined;
15
- }
16
- export declare namespace IntelligenceClinicalProfile {
17
- const HepaticStatus: {
18
- readonly Normal: "normal";
19
- readonly Mild: "mild";
20
- readonly Moderate: "moderate";
21
- readonly Severe: "severe";
22
- };
23
- type HepaticStatus = (typeof HepaticStatus)[keyof typeof HepaticStatus];
24
- }
@@ -1,10 +0,0 @@
1
- // This file was auto-generated by Fern from our API Definition.
2
- export var IntelligenceClinicalProfile;
3
- (function (IntelligenceClinicalProfile) {
4
- IntelligenceClinicalProfile.HepaticStatus = {
5
- Normal: "normal",
6
- Mild: "mild",
7
- Moderate: "moderate",
8
- Severe: "severe",
9
- };
10
- })(IntelligenceClinicalProfile || (IntelligenceClinicalProfile = {}));
@@ -1,17 +0,0 @@
1
- import type * as SafeRx from "../index.mjs";
2
- /**
3
- * Optional Medication Intelligence Platform context. When present and the
4
- * intelligence layer is enabled, SafeRx adds a top-level `intelligence`
5
- * block without changing the standard safety response.
6
- */
7
- export interface IntelligenceContext {
8
- /** Optional caller-side patient or profile identifier. */
9
- user_id?: string | undefined;
10
- clinical_profile?: SafeRx.IntelligenceClinicalProfile | undefined;
11
- /**
12
- * Longitudinal medication list used for active-medication cumulative
13
- * dose tracking. Items with `status: historical` are retained as
14
- * context but excluded from active overdose aggregation.
15
- */
16
- medication_history?: SafeRx.MedicationHistoryItem[] | undefined;
17
- }
@@ -1,2 +0,0 @@
1
- // This file was auto-generated by Fern from our API Definition.
2
- export {};
@@ -1,4 +0,0 @@
1
- export interface IntelligenceProcessorError {
2
- processor?: string | undefined;
3
- error?: string | undefined;
4
- }
@@ -1,2 +0,0 @@
1
- // This file was auto-generated by Fern from our API Definition.
2
- export {};
@@ -1,16 +0,0 @@
1
- import type * as SafeRx from "../index.mjs";
2
- /**
3
- * Optional Medication Intelligence Platform post-processing output.
4
- */
5
- export interface IntelligenceResult {
6
- status?: string | undefined;
7
- /** Active-medication cumulative dose warnings. */
8
- cumulative_warnings?: Record<string, unknown>[] | undefined;
9
- synthesis?: SafeRx.IntelligenceSynthesis | undefined;
10
- /** Allergy/profile-filtered alternative candidates keyed by source `sfrx_id`. */
11
- safer_alternatives?: Record<string, unknown> | undefined;
12
- /** Best-effort processor errors; standard safety output remains valid. */
13
- processor_errors?: SafeRx.IntelligenceProcessorError[] | undefined;
14
- /** Top-level degradation reason when the whole intelligence layer fails. */
15
- error?: string | undefined;
16
- }
@@ -1,2 +0,0 @@
1
- // This file was auto-generated by Fern from our API Definition.
2
- export {};
@@ -1,6 +0,0 @@
1
- export interface IntelligenceSynthesis {
2
- cross_domain_findings?: Record<string, unknown>[] | undefined;
3
- summary?: string | undefined;
4
- /** Condition-specific adverse effects elevated for the supplied context. */
5
- predictive_ae?: Record<string, unknown>[] | undefined;
6
- }
@@ -1,2 +0,0 @@
1
- // This file was auto-generated by Fern from our API Definition.
2
- export {};
@@ -1,22 +0,0 @@
1
- export interface MedicationHistoryItem {
2
- /** SafeRx product identifier. */
3
- sfrx_id: string;
4
- /** Caller-provided start date, preferably ISO 8601. */
5
- start_date?: string | undefined;
6
- /**
7
- * Active medications participate in cumulative dose checks.
8
- * Historical medications are retained as context only.
9
- */
10
- status?: MedicationHistoryItem.Status | undefined;
11
- }
12
- export declare namespace MedicationHistoryItem {
13
- /**
14
- * Active medications participate in cumulative dose checks.
15
- * Historical medications are retained as context only.
16
- */
17
- const Status: {
18
- readonly Active: "active";
19
- readonly Historical: "historical";
20
- };
21
- type Status = (typeof Status)[keyof typeof Status];
22
- }
@@ -1,12 +0,0 @@
1
- // This file was auto-generated by Fern from our API Definition.
2
- export var MedicationHistoryItem;
3
- (function (MedicationHistoryItem) {
4
- /**
5
- * Active medications participate in cumulative dose checks.
6
- * Historical medications are retained as context only.
7
- */
8
- MedicationHistoryItem.Status = {
9
- Active: "active",
10
- Historical: "historical",
11
- };
12
- })(MedicationHistoryItem || (MedicationHistoryItem = {}));