Export CCDA ($export-ccda)

The FHIR R4 $export-ccda operation generates a structured clinical summary for a patient in CCDA format. It is commonly used to support document exchange, referrals, care transitions, compliance workflows, and human-readable summaries.

The response can be returned in structured XML or as a PDF formatted for clinical review.

Use Cases

  • Export a CCDA document for patient transitions or referrals
  • Generate a human-readable summary of a patient’s medical history
  • Share patient documentation with external systems or providers

Base URLs

  • Production: https://api.healthgorilla.com/fhir/R4/Patient/{id}/$export-ccda
  • Sandbox: https://sandbox.healthgorilla.com/fhir/R4/Patient/{id}/$export-ccda

Authentication

All requests require OAuth 2.0 authentication using a Bearer Token. Unauthorized requests return 401 Unauthorized responses.

Required Scope: patient.read

For more information, go to: OAuth 2.0 Authentication

Method

MethodOperationDescription
POSTExport CCDAGenerates a CCDA document for the specified patient

Output Types

FormatDescription
PDFHuman-readable version of the CCDA
XMLMachine-readable structured CCDA document

Example Request

POST /fhir/R4/Patient/123456/$export-ccda
Content-Type: application/fhir+json
Authorization: Bearer {access_token}

If Accept: application/xml is provided, the server may return XML instead of a PDF.

Error Handling

The $export-ccda operation returns standard FHIR OperationOutcome structures in the event of errors.

Examples:

  • 401 Unauthorized — token missing or expired
  • 404 Not Found — patient ID not found
  • 500 Internal Server Error — export failed

For more information, go to: Error Handling