This wiki has undergone a migration to Confluence found Here
Sending FHIR resources in Direct Messages
Revision as of 13:20, 14 June 2017 by GrahameGrieve (talk | contribs)
this page describes how to send FHIR resources in direct messages.
Overview
For direct, FHIR resources are just another kind of Health Content Package. There's nothing different about FHIR resources from the point of view of Direct, but this page provides some additional details:
- How FHIR resources are represented, for complete interoperability
- The relationship between addressing information inside the FHIR resources, and on the Direct messages
Representing FHIR resources
- one of the entries in a mime package
- using one of the FHIR mime types (e.g. application/fhir+xml or application/fhir+json)
- Always a bundle. type = Document, Collection, or Messages
- Document: standard document handling implications apply
- Collection: expectation that the system decomposes into a RESTful API available store. Update semantics to be applied
- Message: treat as a message, response in a new Direct messages (not in the MDN)
Relationship between addresses
- if a bundle of type message
- sender and recipient must match the email addresses on the direct message?
Example
This is not encrypted, but otherwise this is what it looks like:
MIME-Version: 1.0 From: source@example.org Date: Thu, 14 Jun 2017 23:10:50 +1000 Message-ID: <1a4050d8-c87a-403d-b8c8-f0ddc96a0882@example.org> Subject: Clinical data communication To: <target@example.org> Content-Type: multipart/mixed; boundary=0d451cc9f09f44268d37b820ae1276a9 --0d451cc9f09f44268d37b820ae1276a9 Content-Type: application/fhir+xml; charset=UTF-8 <Bundle xmlns="http://hl7.org/fhir"> <id value="7e375113-f17c-4b99-87ed-0463ead9f22c"/> <type value="collection"/> <entry> <fullUrl value="http://example.org/fhir/Patient/example"/> <resource> <Patient> <id value="example"/> <!-- data for patient --> </Patient> </resource> </entry> </Bundle>
--0d451cc9f09f44268d37b820ae1276a9 Content-Type: signature...
Note that this example shows a FHIR bundle as the only part, but this need not be the case. the message could include other parts (PDFs) etc. And the FHIR resources are able to reference the other parts using the cid: scheme in attachment URLs.