saferx-pharma-sdk 0.0.39 → 0.0.51

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 (109) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/developers/client/Client.d.ts +1 -1
  3. package/dist/cjs/api/resources/developers/client/Client.js +1 -1
  4. package/dist/cjs/api/resources/drugSafety/client/Client.d.ts +10 -6
  5. package/dist/cjs/api/resources/drugSafety/client/Client.js +10 -6
  6. package/dist/cjs/api/resources/drugSafety/client/requests/DrugSafetyCheckRequest.d.ts +8 -5
  7. package/dist/cjs/api/resources/drugSafety/types/GetDrugSafetyHealthResponse.d.ts +2 -14
  8. package/dist/cjs/api/resources/drugSafety/types/GetDrugSafetyHealthResponse.js +0 -11
  9. package/dist/cjs/api/types/Alert.d.ts +8 -2
  10. package/dist/cjs/api/types/Alert.js +5 -1
  11. package/dist/cjs/api/types/AllergyCrossReactivityReference.d.ts +16 -0
  12. package/dist/cjs/api/types/AllergyCrossReactivityReference.js +3 -0
  13. package/dist/cjs/api/types/AllergyData.d.ts +24 -0
  14. package/dist/cjs/api/types/AllergyData.js +11 -0
  15. package/dist/cjs/api/types/AllergyFamilyReference.d.ts +10 -0
  16. package/dist/cjs/api/types/AllergyFamilyReference.js +3 -0
  17. package/dist/cjs/api/types/AllergyInputEntry.d.ts +10 -0
  18. package/dist/cjs/api/types/AllergyInputEntry.js +3 -0
  19. package/dist/cjs/api/types/AllergyProductFamilyReference.d.ts +9 -0
  20. package/dist/cjs/api/types/AllergyProductFamilyReference.js +3 -0
  21. package/dist/cjs/api/types/AllergySummary.d.ts +14 -0
  22. package/dist/cjs/api/types/AllergySummary.js +3 -0
  23. package/dist/cjs/api/types/AllergyWarning.d.ts +30 -0
  24. package/dist/cjs/api/types/AllergyWarning.js +11 -0
  25. package/dist/cjs/api/types/ClinicalAlert.d.ts +8 -0
  26. package/dist/cjs/api/types/ClinicalContextApplied.d.ts +10 -0
  27. package/dist/cjs/api/types/ClinicalContextApplied.js +3 -0
  28. package/dist/cjs/api/types/ClinicalData.d.ts +7 -4
  29. package/dist/cjs/api/types/DailyLimit.d.ts +1 -1
  30. package/dist/cjs/api/types/DomainCode.d.ts +4 -2
  31. package/dist/cjs/api/types/DomainCode.js +4 -2
  32. package/dist/cjs/api/types/DosingData.d.ts +22 -12
  33. package/dist/cjs/api/types/DosingData.js +3 -3
  34. package/dist/cjs/api/types/ErrorResponse.d.ts +5 -0
  35. package/dist/cjs/api/types/IdentityMatch.d.ts +13 -0
  36. package/dist/cjs/api/types/IdentityMatch.js +3 -0
  37. package/dist/cjs/api/types/Interaction.d.ts +0 -2
  38. package/dist/cjs/api/types/InteractionSummary.d.ts +4 -4
  39. package/dist/cjs/api/types/Meta.d.ts +2 -0
  40. package/dist/cjs/api/types/Meta.js +1 -0
  41. package/dist/cjs/api/types/MetadataResponse.d.ts +14 -6
  42. package/dist/cjs/api/types/MetadataResponse.js +1 -0
  43. package/dist/cjs/api/types/PatientProfile.d.ts +31 -0
  44. package/dist/cjs/api/types/PatientProfile.js +17 -0
  45. package/dist/cjs/api/types/QuotaMeta.d.ts +11 -0
  46. package/dist/cjs/api/types/QuotaMeta.js +3 -0
  47. package/dist/cjs/api/types/RateLimitResponse.d.ts +11 -0
  48. package/dist/cjs/api/types/RateLimitResponse.js +1 -0
  49. package/dist/cjs/api/types/ResolvedDrug.d.ts +26 -0
  50. package/dist/cjs/api/types/SafetyData.d.ts +1 -0
  51. package/dist/cjs/api/types/index.d.ts +10 -0
  52. package/dist/cjs/api/types/index.js +10 -0
  53. package/dist/cjs/version.d.ts +1 -1
  54. package/dist/cjs/version.js +1 -1
  55. package/dist/esm/BaseClient.mjs +2 -2
  56. package/dist/esm/api/resources/developers/client/Client.d.mts +1 -1
  57. package/dist/esm/api/resources/developers/client/Client.mjs +1 -1
  58. package/dist/esm/api/resources/drugSafety/client/Client.d.mts +10 -6
  59. package/dist/esm/api/resources/drugSafety/client/Client.mjs +10 -6
  60. package/dist/esm/api/resources/drugSafety/client/requests/DrugSafetyCheckRequest.d.mts +8 -5
  61. package/dist/esm/api/resources/drugSafety/types/GetDrugSafetyHealthResponse.d.mts +2 -14
  62. package/dist/esm/api/resources/drugSafety/types/GetDrugSafetyHealthResponse.mjs +0 -11
  63. package/dist/esm/api/types/Alert.d.mts +8 -2
  64. package/dist/esm/api/types/Alert.mjs +5 -1
  65. package/dist/esm/api/types/AllergyCrossReactivityReference.d.mts +16 -0
  66. package/dist/esm/api/types/AllergyCrossReactivityReference.mjs +2 -0
  67. package/dist/esm/api/types/AllergyData.d.mts +24 -0
  68. package/dist/esm/api/types/AllergyData.mjs +8 -0
  69. package/dist/esm/api/types/AllergyFamilyReference.d.mts +10 -0
  70. package/dist/esm/api/types/AllergyFamilyReference.mjs +2 -0
  71. package/dist/esm/api/types/AllergyInputEntry.d.mts +10 -0
  72. package/dist/esm/api/types/AllergyInputEntry.mjs +2 -0
  73. package/dist/esm/api/types/AllergyProductFamilyReference.d.mts +9 -0
  74. package/dist/esm/api/types/AllergyProductFamilyReference.mjs +2 -0
  75. package/dist/esm/api/types/AllergySummary.d.mts +14 -0
  76. package/dist/esm/api/types/AllergySummary.mjs +2 -0
  77. package/dist/esm/api/types/AllergyWarning.d.mts +30 -0
  78. package/dist/esm/api/types/AllergyWarning.mjs +8 -0
  79. package/dist/esm/api/types/ClinicalAlert.d.mts +8 -0
  80. package/dist/esm/api/types/ClinicalContextApplied.d.mts +10 -0
  81. package/dist/esm/api/types/ClinicalContextApplied.mjs +2 -0
  82. package/dist/esm/api/types/ClinicalData.d.mts +7 -4
  83. package/dist/esm/api/types/DailyLimit.d.mts +1 -1
  84. package/dist/esm/api/types/DomainCode.d.mts +4 -2
  85. package/dist/esm/api/types/DomainCode.mjs +4 -2
  86. package/dist/esm/api/types/DosingData.d.mts +22 -12
  87. package/dist/esm/api/types/DosingData.mjs +3 -3
  88. package/dist/esm/api/types/ErrorResponse.d.mts +5 -0
  89. package/dist/esm/api/types/IdentityMatch.d.mts +13 -0
  90. package/dist/esm/api/types/IdentityMatch.mjs +2 -0
  91. package/dist/esm/api/types/Interaction.d.mts +0 -2
  92. package/dist/esm/api/types/InteractionSummary.d.mts +4 -4
  93. package/dist/esm/api/types/Meta.d.mts +2 -0
  94. package/dist/esm/api/types/Meta.mjs +1 -0
  95. package/dist/esm/api/types/MetadataResponse.d.mts +14 -6
  96. package/dist/esm/api/types/MetadataResponse.mjs +1 -0
  97. package/dist/esm/api/types/PatientProfile.d.mts +31 -0
  98. package/dist/esm/api/types/PatientProfile.mjs +16 -1
  99. package/dist/esm/api/types/QuotaMeta.d.mts +11 -0
  100. package/dist/esm/api/types/QuotaMeta.mjs +2 -0
  101. package/dist/esm/api/types/RateLimitResponse.d.mts +11 -0
  102. package/dist/esm/api/types/RateLimitResponse.mjs +1 -0
  103. package/dist/esm/api/types/ResolvedDrug.d.mts +26 -0
  104. package/dist/esm/api/types/SafetyData.d.mts +1 -0
  105. package/dist/esm/api/types/index.d.mts +10 -0
  106. package/dist/esm/api/types/index.mjs +10 -0
  107. package/dist/esm/version.d.mts +1 -1
  108. package/dist/esm/version.mjs +1 -1
  109. package/package.json +1 -1
@@ -11,6 +11,16 @@ export interface RateLimitResponse {
11
11
  daily_limit?: number | undefined;
12
12
  /** Requests made today (present on daily limit errors) */
13
13
  requests_today?: number | undefined;
14
+ /** Machine-readable limit reason */
15
+ reason?: string | undefined;
16
+ /** Your monthly commercial quota (present on monthly quota errors) */
17
+ monthly_limit?: number | undefined;
18
+ /** Requests consumed in the current monthly quota period */
19
+ requests_this_month?: number | undefined;
20
+ /** Remaining monthly quota units */
21
+ monthly_remaining?: number | undefined;
22
+ /** Monthly quota reset timestamp */
23
+ reset_at?: string | undefined;
14
24
  tier?: RateLimitResponse.Tier | undefined;
15
25
  /** Upgrade guidance */
16
26
  hint?: string | undefined;
@@ -19,6 +29,7 @@ export interface RateLimitResponse {
19
29
  export declare namespace RateLimitResponse {
20
30
  const Tier: {
21
31
  readonly Free: "free";
32
+ readonly Startup: "startup";
22
33
  readonly Pro: "pro";
23
34
  readonly Enterprise: "enterprise";
24
35
  };
@@ -3,6 +3,7 @@ export var RateLimitResponse;
3
3
  (function (RateLimitResponse) {
4
4
  RateLimitResponse.Tier = {
5
5
  Free: "free",
6
+ Startup: "startup",
6
7
  Pro: "pro",
7
8
  Enterprise: "enterprise",
8
9
  };
@@ -1,3 +1,4 @@
1
+ import type * as SafeRx from "../index.mjs";
1
2
  export interface ResolvedDrug {
2
3
  /** The original drug name as submitted in the request */
3
4
  input: string;
@@ -17,6 +18,10 @@ export interface ResolvedDrug {
17
18
  brand_name: string;
18
19
  /** Arabic trade name */
19
20
  brand_name_ar?: string | undefined;
21
+ /** Concise registered name plus strength, useful for app display and local matching. */
22
+ display_name?: string | undefined;
23
+ /** Arabic concise registered name plus strength, when available. */
24
+ display_name_ar?: string | undefined;
20
25
  /** Active pharmaceutical ingredient(s), pipe-separated for combinations */
21
26
  active_ingredient: string;
22
27
  /** Arabic active ingredient name */
@@ -29,10 +34,30 @@ export interface ResolvedDrug {
29
34
  form: string;
30
35
  /** Arabic dosage form */
31
36
  form_ar?: string | undefined;
37
+ /** Registered strength text as listed for the product. */
38
+ strength?: string | undefined;
39
+ /** Administration route, when available. */
40
+ route?: string | undefined;
32
41
  /** Marketing authorization holder */
33
42
  manufacturer_en?: string | undefined;
34
43
  /** ATC-based therapeutic classification, pipe-separated hierarchy */
35
44
  therapeutic_class?: string | undefined;
45
+ /** Public therapeutic/pharmacology summary in English. */
46
+ therapeutic_class_detail?: string | undefined;
47
+ /** Public therapeutic/pharmacology summary in Arabic, when available. */
48
+ therapeutic_class_detail_ar?: string | undefined;
49
+ /** Registered pharmaceutical uses or indications in English, when available. */
50
+ pharma_uses?: string | undefined;
51
+ /** Registered pharmaceutical uses or indications in Arabic, when available. */
52
+ pharma_uses_ar?: string | undefined;
53
+ /** Patient/app-friendly product description in English, when available. */
54
+ description?: string | undefined;
55
+ /** Patient/app-friendly product description in Arabic, when available. */
56
+ description_ar?: string | undefined;
57
+ /** Mechanism of action summary in English, when available. */
58
+ mechanism?: string | undefined;
59
+ /** Public warning summary in English, when available. */
60
+ warnings?: string | undefined;
36
61
  /** Primary prescribing specialty */
37
62
  medical_specialty?: string | undefined;
38
63
  /** Distribution/supply company (may be empty) */
@@ -41,4 +66,5 @@ export interface ResolvedDrug {
41
66
  barcode?: string | undefined;
42
67
  /** Current price in Egyptian Pounds (EGP) */
43
68
  price_egp?: number | undefined;
69
+ identity_match?: SafeRx.IdentityMatch | undefined;
44
70
  }
@@ -19,4 +19,5 @@ export interface SafetyData {
19
19
  clinical?: SafeRx.ClinicalData | undefined;
20
20
  /** Maximum daily dose data keyed by sfrx_id */
21
21
  dosing?: Record<string, SafeRx.DosingData> | undefined;
22
+ allergy?: SafeRx.AllergyData | undefined;
22
23
  }
@@ -1,10 +1,18 @@
1
1
  export * from "./AdverseEffect.mjs";
2
2
  export * from "./Alert.mjs";
3
+ export * from "./AllergyCrossReactivityReference.mjs";
4
+ export * from "./AllergyData.mjs";
5
+ export * from "./AllergyFamilyReference.mjs";
6
+ export * from "./AllergyInputEntry.mjs";
7
+ export * from "./AllergyProductFamilyReference.mjs";
8
+ export * from "./AllergySummary.mjs";
9
+ export * from "./AllergyWarning.mjs";
3
10
  export * from "./BadRequestErrorBody.mjs";
4
11
  export * from "./BlackBoxWarning.mjs";
5
12
  export * from "./BlockedResponse.mjs";
6
13
  export * from "./ClinicalAlert.mjs";
7
14
  export * from "./ClinicalConcern.mjs";
15
+ export * from "./ClinicalContextApplied.mjs";
8
16
  export * from "./ClinicalData.mjs";
9
17
  export * from "./Condition.mjs";
10
18
  export * from "./DailyLimit.mjs";
@@ -18,6 +26,7 @@ export * from "./ErrorResponse.mjs";
18
26
  export * from "./FoodConflict.mjs";
19
27
  export * from "./FoodData.mjs";
20
28
  export * from "./ForbiddenErrorBody.mjs";
29
+ export * from "./IdentityMatch.mjs";
21
30
  export * from "./IntelligenceClinicalProfile.mjs";
22
31
  export * from "./IntelligenceContext.mjs";
23
32
  export * from "./IntelligenceProcessorError.mjs";
@@ -35,6 +44,7 @@ export * from "./Monitoring.mjs";
35
44
  export * from "./PatientProfile.mjs";
36
45
  export * from "./Population.mjs";
37
46
  export * from "./PopulationMonitoring.mjs";
47
+ export * from "./QuotaMeta.mjs";
38
48
  export * from "./RateLimitResponse.mjs";
39
49
  export * from "./ReferenceDose.mjs";
40
50
  export * from "./ReproductiveSafetyData.mjs";
@@ -1,10 +1,18 @@
1
1
  export * from "./AdverseEffect.mjs";
2
2
  export * from "./Alert.mjs";
3
+ export * from "./AllergyCrossReactivityReference.mjs";
4
+ export * from "./AllergyData.mjs";
5
+ export * from "./AllergyFamilyReference.mjs";
6
+ export * from "./AllergyInputEntry.mjs";
7
+ export * from "./AllergyProductFamilyReference.mjs";
8
+ export * from "./AllergySummary.mjs";
9
+ export * from "./AllergyWarning.mjs";
3
10
  export * from "./BadRequestErrorBody.mjs";
4
11
  export * from "./BlackBoxWarning.mjs";
5
12
  export * from "./BlockedResponse.mjs";
6
13
  export * from "./ClinicalAlert.mjs";
7
14
  export * from "./ClinicalConcern.mjs";
15
+ export * from "./ClinicalContextApplied.mjs";
8
16
  export * from "./ClinicalData.mjs";
9
17
  export * from "./Condition.mjs";
10
18
  export * from "./DailyLimit.mjs";
@@ -18,6 +26,7 @@ export * from "./ErrorResponse.mjs";
18
26
  export * from "./FoodConflict.mjs";
19
27
  export * from "./FoodData.mjs";
20
28
  export * from "./ForbiddenErrorBody.mjs";
29
+ export * from "./IdentityMatch.mjs";
21
30
  export * from "./IntelligenceClinicalProfile.mjs";
22
31
  export * from "./IntelligenceContext.mjs";
23
32
  export * from "./IntelligenceProcessorError.mjs";
@@ -35,6 +44,7 @@ export * from "./Monitoring.mjs";
35
44
  export * from "./PatientProfile.mjs";
36
45
  export * from "./Population.mjs";
37
46
  export * from "./PopulationMonitoring.mjs";
47
+ export * from "./QuotaMeta.mjs";
38
48
  export * from "./RateLimitResponse.mjs";
39
49
  export * from "./ReferenceDose.mjs";
40
50
  export * from "./ReproductiveSafetyData.mjs";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "0.0.39";
1
+ export declare const SDK_VERSION = "0.0.51";
@@ -1 +1 @@
1
- export const SDK_VERSION = "0.0.39";
1
+ export const SDK_VERSION = "0.0.51";
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.51",
4
4
  "private": false,
5
5
  "type": "commonjs",
6
6
  "main": "./dist/cjs/index.js",