@metriport/shared 0.23.4-alpha.0 → 0.23.6

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 (26) hide show
  1. package/dist/domain/__tests__/dob.test.js +2 -2
  2. package/dist/domain/__tests__/dob.test.js.map +1 -1
  3. package/dist/domain/dob.d.ts +7 -0
  4. package/dist/domain/dob.d.ts.map +1 -1
  5. package/dist/domain/dob.js +10 -2
  6. package/dist/domain/dob.js.map +1 -1
  7. package/dist/interface/external/ehr/eclinicalworks/index.d.ts +2 -0
  8. package/dist/interface/external/ehr/eclinicalworks/index.d.ts.map +1 -0
  9. package/dist/interface/external/ehr/eclinicalworks/index.js +18 -0
  10. package/dist/interface/external/ehr/eclinicalworks/index.js.map +1 -0
  11. package/dist/interface/external/ehr/eclinicalworks/jwt-token.d.ts +18 -0
  12. package/dist/interface/external/ehr/eclinicalworks/jwt-token.d.ts.map +1 -0
  13. package/dist/interface/external/ehr/eclinicalworks/jwt-token.js +15 -0
  14. package/dist/interface/external/ehr/eclinicalworks/jwt-token.js.map +1 -0
  15. package/dist/interface/external/ehr/fhir-resource.d.ts +29 -37
  16. package/dist/interface/external/ehr/fhir-resource.d.ts.map +1 -1
  17. package/dist/interface/external/ehr/fhir-resource.js +8 -10
  18. package/dist/interface/external/ehr/fhir-resource.js.map +1 -1
  19. package/dist/interface/external/ehr/source.d.ts +2 -1
  20. package/dist/interface/external/ehr/source.d.ts.map +1 -1
  21. package/dist/interface/external/ehr/source.js +1 -0
  22. package/dist/interface/external/ehr/source.js.map +1 -1
  23. package/dist/interface/internal/consolidated.d.ts +3 -3
  24. package/dist/interface/internal/consolidated.js +1 -1
  25. package/dist/interface/internal/consolidated.js.map +1 -1
  26. package/package.json +2 -2
@@ -18,8 +18,8 @@ describe("dob", () => {
18
18
  const expectedOutput = undefined;
19
19
  expect((0, dob_1.normalizeDobSafe)(input)).toBe(expectedOutput);
20
20
  });
21
- it("should throw when gets invalid date", () => {
22
- expect(() => (0, dob_1.normalizeDob)("something thats not a date")).toThrow();
21
+ it("should return undefined when gets invalid date", () => {
22
+ expect((0, dob_1.normalizeDobSafe)("something thats not a date")).toBeUndefined();
23
23
  });
24
24
  describe("examples from the wild", () => {
25
25
  const tests = [
@@ -1 +1 @@
1
- {"version":3,"file":"dob.test.js","sourceRoot":"","sources":["../../../src/domain/__tests__/dob.test.ts"],"names":[],"mappings":";;AAAA,gCAAwD;AAExD,QAAQ,CAAC,KAAK,EAAE,GAAG,EAAE;IACnB,QAAQ,CAAC,cAAc,EAAE,GAAG,EAAE;QAC5B,EAAE,CAAC,iDAAiD,EAAE,GAAG,EAAE;YACzD,MAAM,CAAC,GAAG,EAAE,CAAC,IAAA,kBAAY,EAAC,EAAE,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;QAC3C,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,iCAAiC,EAAE,GAAG,EAAE;YACzC,MAAM,GAAG,GAAG,IAAA,kBAAY,EAAC,YAAY,CAAC,CAAC;YACvC,MAAM,CAAC,GAAG,CAAC,CAAC,UAAU,EAAE,CAAC;YACzB,MAAM,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,YAAY,CAAC,CAAC;QACpC,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,uBAAuB,EAAE,GAAG,EAAE;QACrC,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE;YAC3D,MAAM,KAAK,GAAG,EAAE,CAAC;YACjB,MAAM,cAAc,GAAG,SAAS,CAAC;YACjC,MAAM,CAAC,IAAA,sBAAgB,EAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;QACvD,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,qCAAqC,EAAE,GAAG,EAAE;YAC7C,MAAM,CAAC,GAAG,EAAE,CAAC,IAAA,kBAAY,EAAC,4BAA4B,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC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E;QACrC,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE;YAC3D,MAAM,KAAK,GAAG,EAAE,CAAC;YACjB,MAAM,cAAc,GAAG,SAAS,CAAC;YACjC,MAAM,CAAC,IAAA,sBAAgB,EAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;QACvD,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,gDAAgD,EAAE,GAAG,EAAE;YACxD,MAAM,CAAC,IAAA,sBAAgB,EAAC,4BAA4B,CAAC,CAAC,CAAC,aAAa,EAAE,CAAC;QACzE,CAAC,CAAC,CAAC;QAEH,QAAQ,CAAC,wBAAwB,EAAE,GAAG,EAAE;YACtC,MAAM,KAAK,GAAG;gBACZ,EAAE,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,YAAY,EAAE;gBACtD,EAAE,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,YAAY,EAAE;aACvD,CAAC;YACF,KAAK,MAAM,EAAE,KAAK,EAAE,cAAc,EAAE,IAAI,KAAK,EAAE;gBAC7C,EAAE,CAAC,iBAAiB,cAAc,kBAAkB,KAAK,EAAE,EAAE,GAAG,EAAE;oBAChE,MAAM,CAAC,IAAA,sBAAgB,EAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;gBACvD,CAAC,CAAC,CAAC;aACJ;QACH,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,3 +1,10 @@
1
+ /**
2
+ * TODO Consider renaming this function to parseDobSafe
3
+ * - normalize: make all dates the same format
4
+ * - parse: try to convert the value to date
5
+ * - return undefined (or throw) if it's invalid
6
+ * - normalize it and return the result
7
+ */
1
8
  export declare function normalizeDobSafe(date: string): string | undefined;
2
9
  export declare function normalizeDob(date: string): string;
3
10
  //# sourceMappingURL=dob.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"dob.d.ts","sourceRoot":"","sources":["../../src/domain/dob.ts"],"names":[],"mappings":"AAEA,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAKjE;AAED,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAIjD"}
1
+ {"version":3,"file":"dob.d.ts","sourceRoot":"","sources":["../../src/domain/dob.ts"],"names":[],"mappings":"AAGA;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAKjE;AAED,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAIjD"}
@@ -2,19 +2,27 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.normalizeDob = exports.normalizeDobSafe = void 0;
4
4
  const date_1 = require("../common/date");
5
+ const bad_request_1 = require("../error/bad-request");
6
+ /**
7
+ * TODO Consider renaming this function to parseDobSafe
8
+ * - normalize: make all dates the same format
9
+ * - parse: try to convert the value to date
10
+ * - return undefined (or throw) if it's invalid
11
+ * - normalize it and return the result
12
+ */
5
13
  function normalizeDobSafe(date) {
6
14
  const trimmedDate = date.trim();
7
15
  if (trimmedDate.length < 1)
8
16
  return undefined;
9
17
  if (!(0, date_1.validateDateOfBirth)(trimmedDate))
10
- throw new Error("Invalid date of birth.");
18
+ return undefined;
11
19
  return (0, date_1.buildDayjs)(trimmedDate).format(date_1.ISO_DATE);
12
20
  }
13
21
  exports.normalizeDobSafe = normalizeDobSafe;
14
22
  function normalizeDob(date) {
15
23
  const dateOrUndefined = normalizeDobSafe(date);
16
24
  if (!dateOrUndefined)
17
- throw new Error("Invalid date of birth.");
25
+ throw new bad_request_1.BadRequestError("Invalid date of birth", undefined, { date });
18
26
  return dateOrUndefined;
19
27
  }
20
28
  exports.normalizeDob = normalizeDob;
@@ -1 +1 @@
1
- {"version":3,"file":"dob.js","sourceRoot":"","sources":["../../src/domain/dob.ts"],"names":[],"mappings":";;;AAAA,y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,CAAC;IAC9F,OAAO,eAAe,CAAC;AACzB,CAAC;AAJD,oCAIC"}
@@ -0,0 +1,2 @@
1
+ export * from "./jwt-token";
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/eclinicalworks/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC"}
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./jwt-token"), exports);
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/eclinicalworks/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B"}
@@ -0,0 +1,18 @@
1
+ import z from "zod";
2
+ import { EhrSources } from "../source";
3
+ export declare const eclinicalworksDashSource: EhrSources.eclinicalworks;
4
+ export declare const eclinicalworksDashJwtTokenDataSchema: z.ZodObject<{
5
+ practiceId: z.ZodString;
6
+ patientId: z.ZodString;
7
+ source: z.ZodLiteral<"eclinicalworks">;
8
+ }, "strip", z.ZodTypeAny, {
9
+ patientId: string;
10
+ source: "eclinicalworks";
11
+ practiceId: string;
12
+ }, {
13
+ patientId: string;
14
+ source: "eclinicalworks";
15
+ practiceId: string;
16
+ }>;
17
+ export type EClinicalWorksDashJwtTokenData = z.infer<typeof eclinicalworksDashJwtTokenDataSchema>;
18
+ //# sourceMappingURL=jwt-token.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jwt-token.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/eclinicalworks/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AACpB,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAEvC,eAAO,MAAM,wBAAwB,2BAAqC,CAAC;AAC3E,eAAO,MAAM,oCAAoC;;;;;;;;;;;;EAI/C,CAAC;AACH,MAAM,MAAM,8BAA8B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oCAAoC,CAAC,CAAC"}
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.eclinicalworksDashJwtTokenDataSchema = exports.eclinicalworksDashSource = void 0;
7
+ const zod_1 = __importDefault(require("zod"));
8
+ const source_1 = require("../source");
9
+ exports.eclinicalworksDashSource = source_1.EhrSources.eclinicalworks;
10
+ exports.eclinicalworksDashJwtTokenDataSchema = zod_1.default.object({
11
+ practiceId: zod_1.default.string(),
12
+ patientId: zod_1.default.string(),
13
+ source: zod_1.default.literal(`${exports.eclinicalworksDashSource}`),
14
+ });
15
+ //# sourceMappingURL=jwt-token.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jwt-token.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/eclinicalworks/jwt-token.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAoB;AACpB,sCAAuC;AAE1B,QAAA,wBAAwB,GAAG,mBAAU,CAAC,cAAuB,CAAC;AAC9D,QAAA,oCAAoC,GAAG,aAAC,CAAC,MAAM,CAAC;IAC3D,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,SAAS,EAAE,aAAC,CAAC,MAAM,EAAE;IACrB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,GAAG,gCAAwB,EAAE,CAAC;CACjD,CAAC,CAAC"}
@@ -1,73 +1,72 @@
1
+ import { Bundle, Resource } from "@medplum/fhirtypes";
1
2
  import { z } from "zod";
2
- declare const supportedResourceTypes: readonly ["Account", "AllergyIntolerance", "Appointment", "AppointmentResponse", "AuditEvent", "Basic", "BodyStructure", "CarePlan", "CareTeam", "ChargeItem", "Claim", "ClaimResponse", "ClinicalImpression", "Communication", "CommunicationRequest", "Composition", "Condition", "Consent", "Contract", "Coverage", "CoverageEligibilityRequest", "CoverageEligibilityResponse", "DetectedIssue", "Device", "DeviceRequest", "DeviceUseStatement", "DiagnosticReport", "DocumentManifest", "DocumentReference", "Encounter", "EnrollmentRequest", "EpisodeOfCare", "ExplanationOfBenefit", "FamilyMemberHistory", "Flag", "Goal", "GuidanceResponse", "ImagingStudy", "Immunization", "ImmunizationEvaluation", "ImmunizationRecommendation", "Invoice", "List", "MeasureReport", "Media", "MedicationAdministration", "MedicationDispense", "MedicationRequest", "MedicationStatement", "MolecularSequence", "NutritionOrder", "Observation", "Person", "Procedure", "Provenance", "QuestionnaireResponse", "RelatedPerson", "RequestGroup", "ResearchSubject", "RiskAssessment", "ServiceRequest", "Specimen", "AdverseEvent", "Task", "Location", "Organization", "Patient", "Practitioner", "Binary", "Medication"];
3
- export type SupportedResourceType = (typeof supportedResourceTypes)[number];
4
- export declare const fhirResourceSchema: z.ZodIntersection<z.ZodObject<{
3
+ export declare const ehrFhirResourceSchema: z.ZodIntersection<z.ZodObject<{
5
4
  id: z.ZodString;
6
- resourceType: z.ZodEnum<["Account", "AllergyIntolerance", "Appointment", "AppointmentResponse", "AuditEvent", "Basic", "BodyStructure", "CarePlan", "CareTeam", "ChargeItem", "Claim", "ClaimResponse", "ClinicalImpression", "Communication", "CommunicationRequest", "Composition", "Condition", "Consent", "Contract", "Coverage", "CoverageEligibilityRequest", "CoverageEligibilityResponse", "DetectedIssue", "Device", "DeviceRequest", "DeviceUseStatement", "DiagnosticReport", "DocumentManifest", "DocumentReference", "Encounter", "EnrollmentRequest", "EpisodeOfCare", "ExplanationOfBenefit", "FamilyMemberHistory", "Flag", "Goal", "GuidanceResponse", "ImagingStudy", "Immunization", "ImmunizationEvaluation", "ImmunizationRecommendation", "Invoice", "List", "MeasureReport", "Media", "MedicationAdministration", "MedicationDispense", "MedicationRequest", "MedicationStatement", "MolecularSequence", "NutritionOrder", "Observation", "Person", "Procedure", "Provenance", "QuestionnaireResponse", "RelatedPerson", "RequestGroup", "ResearchSubject", "RiskAssessment", "ServiceRequest", "Specimen", "AdverseEvent", "Task", "Location", "Organization", "Patient", "Practitioner", "Binary", "Medication"]>;
5
+ resourceType: z.ZodString;
7
6
  }, "strip", z.ZodTypeAny, {
8
7
  id: string;
9
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
8
+ resourceType: string;
10
9
  }, {
11
10
  id: string;
12
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
11
+ resourceType: string;
13
12
  }>, z.ZodRecord<z.ZodString, z.ZodAny>>;
14
- export type FhirResource = z.infer<typeof fhirResourceSchema>;
15
- export declare const fhirResourcesSchema: z.ZodArray<z.ZodIntersection<z.ZodObject<{
13
+ export type EhrFhirResource = z.infer<typeof ehrFhirResourceSchema>;
14
+ export declare const ehrFhirResourcesSchema: z.ZodArray<z.ZodIntersection<z.ZodObject<{
16
15
  id: z.ZodString;
17
- resourceType: z.ZodEnum<["Account", "AllergyIntolerance", "Appointment", "AppointmentResponse", "AuditEvent", "Basic", "BodyStructure", "CarePlan", "CareTeam", "ChargeItem", "Claim", "ClaimResponse", "ClinicalImpression", "Communication", "CommunicationRequest", "Composition", "Condition", "Consent", "Contract", "Coverage", "CoverageEligibilityRequest", "CoverageEligibilityResponse", "DetectedIssue", "Device", "DeviceRequest", "DeviceUseStatement", "DiagnosticReport", "DocumentManifest", "DocumentReference", "Encounter", "EnrollmentRequest", "EpisodeOfCare", "ExplanationOfBenefit", "FamilyMemberHistory", "Flag", "Goal", "GuidanceResponse", "ImagingStudy", "Immunization", "ImmunizationEvaluation", "ImmunizationRecommendation", "Invoice", "List", "MeasureReport", "Media", "MedicationAdministration", "MedicationDispense", "MedicationRequest", "MedicationStatement", "MolecularSequence", "NutritionOrder", "Observation", "Person", "Procedure", "Provenance", "QuestionnaireResponse", "RelatedPerson", "RequestGroup", "ResearchSubject", "RiskAssessment", "ServiceRequest", "Specimen", "AdverseEvent", "Task", "Location", "Organization", "Patient", "Practitioner", "Binary", "Medication"]>;
16
+ resourceType: z.ZodString;
18
17
  }, "strip", z.ZodTypeAny, {
19
18
  id: string;
20
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
19
+ resourceType: string;
21
20
  }, {
22
21
  id: string;
23
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
22
+ resourceType: string;
24
23
  }>, z.ZodRecord<z.ZodString, z.ZodAny>>, "many">;
25
- export type FhirResources = z.infer<typeof fhirResourcesSchema>;
26
- export declare const fhirResourceWrapperSchema: z.ZodObject<{
24
+ export type EhrFhirResources = z.infer<typeof ehrFhirResourcesSchema>;
25
+ export declare const ehrFhirResourceWrapperSchema: z.ZodObject<{
27
26
  resource: z.ZodIntersection<z.ZodObject<{
28
27
  id: z.ZodString;
29
- resourceType: z.ZodEnum<["Account", "AllergyIntolerance", "Appointment", "AppointmentResponse", "AuditEvent", "Basic", "BodyStructure", "CarePlan", "CareTeam", "ChargeItem", "Claim", "ClaimResponse", "ClinicalImpression", "Communication", "CommunicationRequest", "Composition", "Condition", "Consent", "Contract", "Coverage", "CoverageEligibilityRequest", "CoverageEligibilityResponse", "DetectedIssue", "Device", "DeviceRequest", "DeviceUseStatement", "DiagnosticReport", "DocumentManifest", "DocumentReference", "Encounter", "EnrollmentRequest", "EpisodeOfCare", "ExplanationOfBenefit", "FamilyMemberHistory", "Flag", "Goal", "GuidanceResponse", "ImagingStudy", "Immunization", "ImmunizationEvaluation", "ImmunizationRecommendation", "Invoice", "List", "MeasureReport", "Media", "MedicationAdministration", "MedicationDispense", "MedicationRequest", "MedicationStatement", "MolecularSequence", "NutritionOrder", "Observation", "Person", "Procedure", "Provenance", "QuestionnaireResponse", "RelatedPerson", "RequestGroup", "ResearchSubject", "RiskAssessment", "ServiceRequest", "Specimen", "AdverseEvent", "Task", "Location", "Organization", "Patient", "Practitioner", "Binary", "Medication"]>;
28
+ resourceType: z.ZodString;
30
29
  }, "strip", z.ZodTypeAny, {
31
30
  id: string;
32
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
31
+ resourceType: string;
33
32
  }, {
34
33
  id: string;
35
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
34
+ resourceType: string;
36
35
  }>, z.ZodRecord<z.ZodString, z.ZodAny>>;
37
36
  }, "strip", z.ZodTypeAny, {
38
37
  resource: {
39
38
  id: string;
40
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
39
+ resourceType: string;
41
40
  } & Record<string, any>;
42
41
  }, {
43
42
  resource: {
44
43
  id: string;
45
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
44
+ resourceType: string;
46
45
  } & Record<string, any>;
47
46
  }>;
48
- export type FhirResourceWrapper = z.infer<typeof fhirResourceWrapperSchema>;
49
- export declare const fhirResourceBundleSchema: z.ZodObject<{
47
+ export type EhrFhirResourceWrapper = z.infer<typeof ehrFhirResourceWrapperSchema>;
48
+ export declare const ehrFhirResourceBundleSchema: z.ZodObject<{
50
49
  resourceType: z.ZodLiteral<"Bundle">;
51
50
  entry: z.ZodOptional<z.ZodArray<z.ZodObject<{
52
51
  resource: z.ZodIntersection<z.ZodObject<{
53
52
  id: z.ZodString;
54
- resourceType: z.ZodEnum<["Account", "AllergyIntolerance", "Appointment", "AppointmentResponse", "AuditEvent", "Basic", "BodyStructure", "CarePlan", "CareTeam", "ChargeItem", "Claim", "ClaimResponse", "ClinicalImpression", "Communication", "CommunicationRequest", "Composition", "Condition", "Consent", "Contract", "Coverage", "CoverageEligibilityRequest", "CoverageEligibilityResponse", "DetectedIssue", "Device", "DeviceRequest", "DeviceUseStatement", "DiagnosticReport", "DocumentManifest", "DocumentReference", "Encounter", "EnrollmentRequest", "EpisodeOfCare", "ExplanationOfBenefit", "FamilyMemberHistory", "Flag", "Goal", "GuidanceResponse", "ImagingStudy", "Immunization", "ImmunizationEvaluation", "ImmunizationRecommendation", "Invoice", "List", "MeasureReport", "Media", "MedicationAdministration", "MedicationDispense", "MedicationRequest", "MedicationStatement", "MolecularSequence", "NutritionOrder", "Observation", "Person", "Procedure", "Provenance", "QuestionnaireResponse", "RelatedPerson", "RequestGroup", "ResearchSubject", "RiskAssessment", "ServiceRequest", "Specimen", "AdverseEvent", "Task", "Location", "Organization", "Patient", "Practitioner", "Binary", "Medication"]>;
53
+ resourceType: z.ZodString;
55
54
  }, "strip", z.ZodTypeAny, {
56
55
  id: string;
57
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
56
+ resourceType: string;
58
57
  }, {
59
58
  id: string;
60
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
59
+ resourceType: string;
61
60
  }>, z.ZodRecord<z.ZodString, z.ZodAny>>;
62
61
  }, "strip", z.ZodTypeAny, {
63
62
  resource: {
64
63
  id: string;
65
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
64
+ resourceType: string;
66
65
  } & Record<string, any>;
67
66
  }, {
68
67
  resource: {
69
68
  id: string;
70
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
69
+ resourceType: string;
71
70
  } & Record<string, any>;
72
71
  }>, "many">>;
73
72
  link: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -89,7 +88,7 @@ export declare const fhirResourceBundleSchema: z.ZodObject<{
89
88
  entry?: {
90
89
  resource: {
91
90
  id: string;
92
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
91
+ resourceType: string;
93
92
  } & Record<string, any>;
94
93
  }[] | undefined;
95
94
  }, {
@@ -101,22 +100,15 @@ export declare const fhirResourceBundleSchema: z.ZodObject<{
101
100
  entry?: {
102
101
  resource: {
103
102
  id: string;
104
- resourceType: "Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary" | "Medication";
103
+ resourceType: string;
105
104
  } & Record<string, any>;
106
105
  }[] | undefined;
107
106
  }>;
108
- export type FhirResourceBundle = z.infer<typeof fhirResourceBundleSchema>;
107
+ export type EhrFhirResourceBundle = z.infer<typeof ehrFhirResourceBundleSchema>;
109
108
  export type BundleWithLastModified = {
110
- bundle: {
111
- resourceType: "Bundle";
112
- entry: {
113
- resource: FhirResource;
114
- }[];
115
- };
109
+ bundle: Bundle;
116
110
  lastModified: Date | undefined;
117
111
  };
118
- export type Bundle = BundleWithLastModified["bundle"];
119
- export declare function createBundleFromResourceList(resourceList: FhirResource[]): Bundle;
112
+ export declare function createBundleFromResourceList(resourceList: Resource[]): Bundle;
120
113
  export declare function getDefaultBundle(): Bundle;
121
- export {};
122
114
  //# sourceMappingURL=fhir-resource.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fhir-resource.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/ehr/fhir-resource.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,QAAA,MAAM,sBAAsB,4pCAA2D,CAAC;AAExF,MAAM,MAAM,qBAAqB,GAAG,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE5E,eAAO,MAAM,kBAAkB;;;;;;;;;uCAM9B,CAAC;AACF,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAE9D,eAAO,MAAM,mBAAmB;;;;;;;;;g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gB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAEtE,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;EAEvC,CAAC;AACH,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC;AAElF,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAItC,CAAC;AACH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAEhF,MAAM,MAAM,sBAAsB,GAAG;IACnC,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,IAAI,GAAG,SAAS,CAAC;CAChC,CAAC;AAEF,wBAAgB,4BAA4B,CAAC,YAAY,EAAE,QAAQ,EAAE,GAAG,MAAM,CAK7E;AAED,wBAAgB,gBAAgB,IAAI,MAAM,CAKzC"}
@@ -1,20 +1,18 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getDefaultBundle = exports.createBundleFromResourceList = exports.fhirResourceBundleSchema = exports.fhirResourceWrapperSchema = exports.fhirResourcesSchema = exports.fhirResourceSchema = void 0;
3
+ exports.getDefaultBundle = exports.createBundleFromResourceList = exports.ehrFhirResourceBundleSchema = exports.ehrFhirResourceWrapperSchema = exports.ehrFhirResourcesSchema = exports.ehrFhirResourceSchema = void 0;
4
4
  const zod_1 = require("zod");
5
- const resources_1 = require("../../../medical/fhir/resources");
6
- const supportedResourceTypes = [...resources_1.resourceTypeForConsolidation, "Medication"];
7
- exports.fhirResourceSchema = zod_1.z.intersection(zod_1.z.object({
5
+ exports.ehrFhirResourceSchema = zod_1.z.intersection(zod_1.z.object({
8
6
  id: zod_1.z.string(),
9
- resourceType: zod_1.z.enum(supportedResourceTypes),
7
+ resourceType: zod_1.z.string(),
10
8
  }), zod_1.z.record(zod_1.z.string(), zod_1.z.any()));
11
- exports.fhirResourcesSchema = exports.fhirResourceSchema.array();
12
- exports.fhirResourceWrapperSchema = zod_1.z.object({
13
- resource: exports.fhirResourceSchema,
9
+ exports.ehrFhirResourcesSchema = exports.ehrFhirResourceSchema.array();
10
+ exports.ehrFhirResourceWrapperSchema = zod_1.z.object({
11
+ resource: exports.ehrFhirResourceSchema,
14
12
  });
15
- exports.fhirResourceBundleSchema = zod_1.z.object({
13
+ exports.ehrFhirResourceBundleSchema = zod_1.z.object({
16
14
  resourceType: zod_1.z.literal("Bundle"),
17
- entry: exports.fhirResourceWrapperSchema.array().optional(),
15
+ entry: exports.ehrFhirResourceWrapperSchema.array().optional(),
18
16
  link: zod_1.z.object({ relation: zod_1.z.string(), url: zod_1.z.string() }).array().optional(),
19
17
  });
20
18
  function createBundleFromResourceList(resourceList) {
@@ -1 +1 @@
1
- {"version":3,"file":"fhir-resource.js","sourceRoot":"","sources":["../../../../src/interface/external/ehr/fhir-resource.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,+DAA+E;AAE/E,MAAM,sBAAsB,GAAG,CAAC,GAAG,wCAA4B,EAAE,YAAY,CAAU,CAAC;AAI3E,QAAA,kBAAkB,GAAG,OAAC,CAAC,YAAY,CAC9C,OAAC,CAAC,MAAM,CAAC;IACP,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE;IACd,YAAY,EAAE,OAAC,CAAC,IAAI,CAAC,sBAAsB,CAAC;CAC7C,CAAC,EACF,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,CAC9B,CAAC;AAGW,QAAA,mBAAmB,GAAG,0BAAkB,CAAC,KAAK,EAAE,CAAC;AAGjD,QAAA,yBAAyB,GAAG,OAAC,CAAC,MAAM,CAAC;IAChD,QAAQ,EAAE,0BAAkB;CAC7B,CAAC,CAAC;AAGU,QAAA,wBAAwB,GAAG,OAAC,CAAC,MAAM,C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;IAClD,YAAY,EAAE,OAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;IACjC,KAAK,EAAE,oCAA4B,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE;IACtD,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,EAAE,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE;CAC7E,CAAC,CAAC;AAQH,SAAgB,4BAA4B,CAAC,YAAwB;IACnE,OAAO;QACL,YAAY,EAAE,QAAQ;QACtB,KAAK,EAAE,YAAY,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,QAAQ,EAAE,CAAC,CAAC;KACpD,CAAC;AACJ,CAAC;AALD,oEAKC;AAED,SAAgB,gBAAgB;IAC9B,OAAO;QACL,YAAY,EAAE,QAAQ;QACtB,KAAK,EAAE,EAAE;KACV,CAAC;AACJ,CAAC;AALD,4CAKC"}
@@ -2,7 +2,8 @@ export declare enum EhrSources {
2
2
  athena = "athenahealth",
3
3
  elation = "elation",
4
4
  canvas = "canvas",
5
- healthie = "healthie"
5
+ healthie = "healthie",
6
+ eclinicalworks = "eclinicalworks"
6
7
  }
7
8
  export declare const ehrSources: readonly EhrSources[];
8
9
  export type EhrSource = (typeof ehrSources)[number];
@@ -1 +1 @@
1
- {"version":3,"file":"source.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/ehr/source.ts"],"names":[],"mappings":"AAAA,oBAAY,UAAU;IACpB,MAAM,iBAAiB;IACvB,OAAO,YAAY;IACnB,MAAM,WAAW;IACjB,QAAQ,aAAa;CACtB;AACD,eAAO,MAAM,UAAU,uBAA0C,CAAC;AAClE,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC;AACpD,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,SAAS,CAE/D;AAED,eAAO,MAAM,kBAAkB,YAAY,CAAC;AAC5C,eAAO,MAAM,mBAAmB,aAAa,CAAC;AAE9C,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAE5D;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAE7D"}
1
+ {"version":3,"file":"source.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/ehr/source.ts"],"names":[],"mappings":"AAAA,oBAAY,UAAU;IACpB,MAAM,iBAAiB;IACvB,OAAO,YAAY;IACnB,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,cAAc,mBAAmB;CAClC;AACD,eAAO,MAAM,UAAU,uBAA0C,CAAC;AAClE,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC;AACpD,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,SAAS,CAE/D;AAED,eAAO,MAAM,kBAAkB,YAAY,CAAC;AAC5C,eAAO,MAAM,mBAAmB,aAAa,CAAC;AAE9C,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAE5D;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAE7D"}
@@ -7,6 +7,7 @@ var EhrSources;
7
7
  EhrSources["elation"] = "elation";
8
8
  EhrSources["canvas"] = "canvas";
9
9
  EhrSources["healthie"] = "healthie";
10
+ EhrSources["eclinicalworks"] = "eclinicalworks";
10
11
  })(EhrSources = exports.EhrSources || (exports.EhrSources = {}));
11
12
  exports.ehrSources = [...Object.values(EhrSources)];
12
13
  function isEhrSource(source) {
@@ -1 +1 @@
1
- {"version":3,"file":"source.js","sourceRoot":"","sources":["../../../../src/interface/external/ehr/source.ts"],"names":[],"mappings":";;;AAAA,IAAY,UAKX;AALD,WAAY,UAAU;IACpB,qCAAuB,CAAA;IACvB,i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C/C,OAAO,MAAM,CAAC,OAAO,CAAC,0BAAkB,EAAE,EAAE,CAAc,CAAC;AAC7D,CAAC;AAFD,gDAEC;AAED,SAAgB,mBAAmB,CAAC,MAAc;IAChD,OAAO,MAAM,CAAC,OAAO,CAAC,2BAAmB,EAAE,EAAE,CAAc,CAAC;AAC9D,CAAC;AAFD,kDAEC"}
@@ -3,7 +3,7 @@ export declare const internalSendConsolidatedSchema: z.ZodObject<{
3
3
  bundleLocation: z.ZodString;
4
4
  bundleFilename: z.ZodString;
5
5
  requestId: z.ZodString;
6
- conversionType: z.ZodOptional<z.ZodEnum<["html", "pdf", "json"]>>;
6
+ conversionType: z.ZodEnum<["html", "pdf", "json"]>;
7
7
  resources: z.ZodOptional<z.ZodArray<z.ZodEnum<["Account", "AllergyIntolerance", "Appointment", "AppointmentResponse", "AuditEvent", "Basic", "BodyStructure", "CarePlan", "CareTeam", "ChargeItem", "Claim", "ClaimResponse", "ClinicalImpression", "Communication", "CommunicationRequest", "Composition", "Condition", "Consent", "Contract", "Coverage", "CoverageEligibilityRequest", "CoverageEligibilityResponse", "DetectedIssue", "Device", "DeviceRequest", "DeviceUseStatement", "DiagnosticReport", "DocumentManifest", "DocumentReference", "Encounter", "EnrollmentRequest", "EpisodeOfCare", "ExplanationOfBenefit", "FamilyMemberHistory", "Flag", "Goal", "GuidanceResponse", "ImagingStudy", "Immunization", "ImmunizationEvaluation", "ImmunizationRecommendation", "Invoice", "List", "MeasureReport", "Media", "MedicationAdministration", "MedicationDispense", "MedicationRequest", "MedicationStatement", "MolecularSequence", "NutritionOrder", "Observation", "Person", "Procedure", "Provenance", "QuestionnaireResponse", "RelatedPerson", "RequestGroup", "ResearchSubject", "RiskAssessment", "ServiceRequest", "Specimen", "AdverseEvent", "Task", "Location", "Organization", "Patient", "Practitioner", "Binary"]>, "many">>;
8
8
  dateFrom: z.ZodOptional<z.ZodString>;
9
9
  dateTo: z.ZodOptional<z.ZodString>;
@@ -12,7 +12,7 @@ export declare const internalSendConsolidatedSchema: z.ZodObject<{
12
12
  requestId: string;
13
13
  bundleLocation: string;
14
14
  bundleFilename: string;
15
- conversionType?: "html" | "pdf" | "json" | undefined;
15
+ conversionType: "html" | "pdf" | "json";
16
16
  resources?: ("Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary")[] | undefined;
17
17
  dateFrom?: string | undefined;
18
18
  dateTo?: string | undefined;
@@ -21,7 +21,7 @@ export declare const internalSendConsolidatedSchema: z.ZodObject<{
21
21
  requestId: string;
22
22
  bundleLocation: string;
23
23
  bundleFilename: string;
24
- conversionType?: "html" | "pdf" | "json" | undefined;
24
+ conversionType: "html" | "pdf" | "json";
25
25
  resources?: ("Organization" | "Account" | "AllergyIntolerance" | "Appointment" | "AppointmentResponse" | "AuditEvent" | "Basic" | "BodyStructure" | "CarePlan" | "CareTeam" | "ChargeItem" | "Claim" | "ClaimResponse" | "ClinicalImpression" | "Communication" | "CommunicationRequest" | "Composition" | "Condition" | "Consent" | "Contract" | "Coverage" | "CoverageEligibilityRequest" | "CoverageEligibilityResponse" | "DetectedIssue" | "Device" | "DeviceRequest" | "DeviceUseStatement" | "DiagnosticReport" | "DocumentManifest" | "DocumentReference" | "Encounter" | "EnrollmentRequest" | "EpisodeOfCare" | "ExplanationOfBenefit" | "FamilyMemberHistory" | "Flag" | "Goal" | "GuidanceResponse" | "ImagingStudy" | "Immunization" | "ImmunizationEvaluation" | "ImmunizationRecommendation" | "Invoice" | "List" | "MeasureReport" | "Media" | "MedicationAdministration" | "MedicationDispense" | "MedicationRequest" | "MedicationStatement" | "MolecularSequence" | "NutritionOrder" | "Observation" | "Person" | "Procedure" | "Provenance" | "QuestionnaireResponse" | "RelatedPerson" | "RequestGroup" | "ResearchSubject" | "RiskAssessment" | "ServiceRequest" | "Specimen" | "AdverseEvent" | "Task" | "Location" | "Patient" | "Practitioner" | "Binary")[] | undefined;
26
26
  dateFrom?: string | undefined;
27
27
  dateTo?: string | undefined;
@@ -7,7 +7,7 @@ exports.internalSendConsolidatedSchema = zod_1.z.object({
7
7
  bundleLocation: zod_1.z.string(),
8
8
  bundleFilename: zod_1.z.string(),
9
9
  requestId: zod_1.z.string(),
10
- conversionType: zod_1.z.enum(medical_1.consolidationConversionType).optional(),
10
+ conversionType: zod_1.z.enum(medical_1.consolidationConversionType),
11
11
  resources: zod_1.z.array(zod_1.z.enum(medical_1.resourceTypeForConsolidation)).optional(),
12
12
  dateFrom: zod_1.z.string().optional(),
13
13
  dateTo: zod_1.z.string().optional(),
@@ -1 +1 @@
1
- {"version":3,"file":"consolidated.js","sourceRoot":"","sources":["../../../src/interface/internal/consolidated.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,2CAA0F;AAE7E,QAAA,8BAA8B,GAAG,OAAC,CAAC,MAAM,CAAC;IACrD,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,cAAc,EAAE,OAAC,CAAC,IAAI,CAAC,qCAA2B,CAAC,CAAC,QAAQ,EAAE;IAC9D,SAAS,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,IAAI,CAAC,sCAA4B,CAAC,CAAC,CAAC,QAAQ,EAAE;IACnE,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,aAAa,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CACtC,CAAC,CAAC"}
1
+ {"version":3,"file":"consolidated.js","sourceRoot":"","sources":["../../../src/interface/internal/consolidated.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,2CAA0F;AAE7E,QAAA,8BAA8B,GAAG,OAAC,CAAC,MAAM,CAAC;IACrD,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,cAAc,EAAE,OAAC,CAAC,IAAI,CAAC,qCAA2B,CAAC;IACnD,SAAS,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,IAAI,CAAC,sCAA4B,CAAC,CAAC,CAAC,QAAQ,EAAE;IACnE,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,aAAa,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CACtC,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metriport/shared",
3
- "version": "0.23.4-alpha.0",
3
+ "version": "0.23.6",
4
4
  "description": "Common code shared across packages - by Metriport Inc.",
5
5
  "author": "Metriport Inc. <contact@metriport.com>",
6
6
  "homepage": "https://metriport.com/",
@@ -110,5 +110,5 @@
110
110
  "ts-jest": "29.1.1",
111
111
  "typescript": "^4.9.5"
112
112
  },
113
- "gitHead": "3da0d26f0ca52232d3d4a10279a259ae58c92ade"
113
+ "gitHead": "c365e556b131e35a62d7f7a5c5c8cd625b525480"
114
114
  }