Te Whatu Ora, Central Region Integration Hub
1.0.12-rc1 - ci-build
Te Whatu Ora, Central Region Integration Hub, published by Te Whatu Ora, Te Pae Hauora o Ruahine o Tararua, MidCentral. This guide is not an authorized publication; it is the continuous build for version 1.0.12-rc1 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/tewhatuora/centralRegion-integrationHub-ig/ and changes regularly. See the Directory of published versions
Full discussion of Subscription payload options is in the Developer's Guide. Two subscriptions are required at various stages of this use case:
ServiceRequest
resource be put in place prior to referrals being created.Patient
resource.For both these subscriptions the client needs to decide if they want to receive a single resource notification, or a bundle resource notification.
The second pre-requisite of this use-case is that a suitable subscription be put in place prior to referrals being created. A sample subscription, returning the triggered ServiceRequest resource that targets referrals to a particular Hospital Clinic e.g. Mental Health and Addiction Services, would look like this:
{
"resourceType": "Subscription",
"status": "active",
"criteria": "ServiceRequest?clinicType=MMA",
"channel": {
"type": "rest-hook",
"endpoint": "http://localhost:3000/fhir/callback/ServiceRequest",
"payload": "application/json"
},
}
Notes
PUT
call to the endpoint URL; You may require separate callback addresses, one for each resource type you expect to receive.Steps 9, 10 & 11, the retrieve patient details steps, can be removed from the above diagram by requesting a suitable bundle resource notification when placing the subscription:
{
"resourceType": "Subscription",
"status": "active",
"criteria": "ServiceRequest?_clinicType=MMA",
"channel": {
"type": "rest-hook",
"endpoint": "http://localhost:3000/fhir/callback",
"payload": "application/json"
},
"extension": [ {
"url": "http://hapifhir.io/fhir/StructureDefinition/subscription-payload-search-criteria",
"valueString": "ServiceRequest?_id=${1}&_include=Patient:*&_revinclude:iterate=AllergyIntolerance:*&_revinclude:iterate=Flag:*&_revinclude:iterate=ClinicalImpression:*"
} ]
}
Notes:
POST
call to the endpoint URLStep 12 in this use case places a subscription on the relevant Patient resource, to receive notifications on all subsequent updates of patient records. It is most likely that you will want to place another bundle resource notification subscription, like this:
{
"resourceType": "Subscription",
"id": "325",
"status": "active",
"criteria": "Patient?identifier=ZKG3868",
"channel": {
"type": "rest-hook",
"endpoint": "http://localhost:3000/fhir/callback",
"payload": "application/json"
},
"extension": [ {
"url": "http://hapifhir.io/fhir/StructureDefinition/subscription-payload-search-criteria",
"valueString": "Patient?_id=${matched_resource_id}&_include=*&_revinclude=Flag:*&_revinclude=AllergyIntolerance:*&_revinclude=ClinicalImpression:*&_revinclude=ServiceRequest:*"
} ]
}