Challenge
Every EHR emits slightly different valid C-CDA
Agnotic approach
We profile a real sample corpus per source and build tolerance for optional sections and vendor template quirks.
We build production C-CDA pipelines — generating, exchanging, and parsing Continuity of Care Documents against the real HL7 CDA R2 template hierarchy, not a happy-path XML reader.
Trusted by global innovators
























C-CDA (Consolidated Clinical Document Architecture) is HL7's XML standard for exchanging summary documents — the Continuity of Care Document (CCD), Discharge Summary, Referral Note, and more. Each document is built from nested sections identified by LOINC codes and constrained by template IDs, with structured entries carrying coded problems, medications, allergies, results, and vitals.
The hard part is not reading XML — it is handling the variance. Every EHR emits valid-but-different C-CDA: optional sections, nullFlavors, narrative-only entries, inconsistent code systems, and vendor template quirks. We build parsers and validators that survive real-world documents and map cleanly onto your data model or a FHIR R4 store.
See how we design C-CDA ingestion, validation, and transformation pipelines that hold up against messy real-world documents.

Common failure modes
Challenge
Every EHR emits slightly different valid C-CDA
Agnotic approach
We profile a real sample corpus per source and build tolerance for optional sections and vendor template quirks.
Challenge
nullFlavor and narrative-only entries break naive parsers
Agnotic approach
Explicit nullFlavor handling and a narrative-fallback path with a human-review reconciliation queue.
Challenge
Code systems drift across documents
Agnotic approach
A terminology mapping layer that normalizes SNOMED, LOINC, RxNorm, and ICD-10 to your canonical vocabularies.
Challenge
Documents pass schema but fail downstream conformance
Agnotic approach
We validate with C-CDA Schematron, not just XSD, so output survives ONC and partner checks.
We name the exact document surface so your integration reaches production, not just a validator.
Continuity of Care Document (CCD), Referral Note, Discharge Summary, Progress Note, and Care Plan — generated and parsed against the C-CDA 2.1 implementation guide.
LOINC-coded sections and templateId-constrained entries for Problems, Medications, Allergies, Results, Immunizations, and Vitals, with correct nullFlavor handling.
Structural and semantic validation using the HL7 CDA R2 schema and C-CDA Schematron rules, so documents pass downstream conformance and ONC checks.
Map C-CDA entries onto FHIR R4 resources (Condition, MedicationStatement, AllergyIntolerance, Observation) for modern API-based consumers.
Where it runs
Ingest CCDs at admission, discharge, and referral to build a longitudinal record.
Generate patient-facing CCDs for portals and third-party app sharing.
Bulk-parse historical C-CDA documents to seed a new platform's clinical record.
Attach Referral Notes to referral workflows with structured reason-for-referral.
Transform C-CDA into FHIR or a warehouse schema for population analytics.
Most C-CDA projects break on document variance, not the schema. We plan for it from the first sample.
Health Insurance Portability and Accountability Act
Protect PHI with privacy-first architecture, encrypted storage and transmission, strict access controls, and traceable audit logs.
General Data Protection Regulation
Implement lawful consent flows, data minimization, retention controls, and secure processing for sensitive health data.
Fast Healthcare Interoperability Resources
Enable standardized health data exchange across apps, care teams, and systems through robust FHIR-ready APIs.
Health Level Seven International
Support enterprise-grade interoperability with HL7-based integrations for records, events, and clinical messaging workflows.
Health Information Trust Alliance
Align security programs to healthcare-specific control and risk management practices trusted by providers and ecosystem partners.
Health Information Technology for Economic and Clinical Health Act
Design with breach notification readiness, digital record safeguards, and operational controls that support regulated care programs.
FDA Software as a Medical Device
Plan software quality, traceability, and documentation pathways for products that may require SaMD review and submission.
Medical Device Regulation (European Union)
Prepare EU market-ready processes for risk classification, evidence tracking, and lifecycle governance under MDR expectations.
Substance Abuse and Mental Health Services Administration
Apply confidentiality controls and consent-aware sharing models for behavioral and mental health data experiences.
Standards we build against
A phased approach that treats document variance and validation as the real risk, not an afterthought.
We collect real sample documents from your source EHRs and profile which sections, templates, and code systems actually appear.
We build the parsing and generation layer against C-CDA 2.1 templates and map entries onto your data model or a FHIR store.
Schematron and schema validation against a corpus of real and synthetic documents, including malformed and nullFlavor edge cases.
Production rollout with parse-failure alerting and a reconciliation queue for documents that need human review.
Document surface
Different C-CDA documents carry different required sections. Here is how we scope each.
| Document | LOINC / purpose | Typical sections | Notes |
|---|---|---|---|
| CCD | 34133-9 — summary of care | Problems, Meds, Allergies, Results, Vitals | The workhorse; most common inbound and outbound document. |
| Referral Note | 57133-1 — referral | Reason for referral, Problems, Meds | Drives care coordination and eReferral flows. |
| Discharge Summary | 18842-5 — discharge | Hospital course, Discharge meds, Follow-up | Care-transition heavy; watch for narrative-only entries. |
| Progress Note | 11506-3 — progress | Assessment, Plan, Vitals | Often lighter structured content. |
| Care Plan | 52521-2 — care plan | Goals, Interventions, Health concerns | Goal and outcome modelling is the tricky part. |
Real documents vary widely by EHR. We profile your actual sample corpus before committing to a mapping.
Lera Health is a women-first health platform where we built the privacy-first data layer and the testing-to-insights workflow end to end. It is related proof of the same discipline C-CDA work demands: clean structured-data modelling, coded clinical vocabularies, and compliant handling of PHI.

Real document exchange, not just familiarity with the spec.
HIPAA-ready pipelines with audit logging around every document parsed, stored, or exchanged.
We work fluently in CDA R2, C-CDA 2.1 templates, LOINC section codes, and FHIR R4 mappings.
We optimize for the documents your partners actually send, so the integration survives real traffic.
We understand what the coded data means clinically, so mappings are correct, not just structurally valid.
Structured clinical documents, done right
Send us sample documents from your source systems. We will return a realistic parse, validate, and transform plan.
contact@agnotic.com
Partnerships
contact@agnotic.com