Stream: implementers
Topic: messageHeader attributes
Wadii TAHRI (May 14 2020 at 15:54):
Hi,
I try to use messageHeader to exchange data between apps.
My questions are related to some attributes in messageHeader Object:
- system, code values are standardized in FHIR System or depends on the project ?
- What's mean focus attribute in messageHeader ?
{
"system" : "<uri>",
"version" : "<string>",
"code" : "<code>",
"display" : "<string>",
"userSelected" : <boolean>
}
Lloyd McKenzie (May 14 2020 at 20:52):
system and code are currently project dependent. So far, there's been little interest in trying to standardize these on an international basis. (In part because most FHIR implementation doesn't make use of messaging at all.) The MessageHeader.focus points to the resource the message event is 'about'. For example, if you were sending a "patient admission" message, the focus would be Encounter - which is the resource that was undergoing a state transition as part of the 'admission' business event. Everything else in the message would have some sort of relationship path to the Encounter. In some cases, a message might have multiple focus resources. For example, a "merge patient" message would have two (or maybe more) focal resources - one for each Patient resource to be merged.
Lloyd McKenzie (May 14 2020 at 20:52):
Make sure you read the messaging section in the core spec and also look at the example message available from the MessageHeader page.
Wadii TAHRI (May 15 2020 at 14:52):
thank you for your answer, but i have seen some examples that they use some standard terminology system as in this link https://www.hl7.org/fhir/terminologies-systems.html.
Also in reason attribute in messageHeader they use some standard valueSet as in this example:
"reason": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/message-reasons-encounter",
"code": "admit"
}
]
},
Lloyd McKenzie (May 15 2020 at 15:29):
That code system is not FHIR-specific. I'm not actually sure where it comes from
Lloyd McKenzie (May 15 2020 at 15:30):
Ah, I see
Lloyd McKenzie (May 15 2020 at 15:30):
Yes, that's an example terminology, not a standard terminology and it's for MessageHeader.reason, not MessageHeader.event.code - which is what actually drives message processing
Wadii TAHRI (May 18 2020 at 09:37):
Thank you LIoyd;
If i have understood you well, MessageHeader.event.code is FHIR standardized !?
In fact, In our architecture we have DTS APP that will notify via messageHeader some others applications as "CRM" and "MOBEX" , so to prepare messageHeader we need to add some new code Systems i mean generate a new Code System ressource type !?
as for example in event: making system: http://host/codeSystem/code-system-definition and Code: myCodeEvent
Lloyd McKenzie (May 18 2020 at 15:14):
MessageHeader.event.code is NOT FHIR-standardized, so yes, you'll need to define your own code system and codes if you're not using an implementation guide that dictates. (Make sure your communication partners actually want to use messaging.)
Wadii TAHRI (May 19 2020 at 00:34):
Thank you,
I have a new question about messageHeader:
In messageHeader we have "definition" : { canonical(MessageDefinition) }
1- what's mean canonical ? which URI we will make in definition ?
2- Is definition attribute is required in messageHeader ?
3- if it's required so we have to prepare messageDefinition before messageHeader OR NOT?
Jean Duteau (May 19 2020 at 00:55):
1) Here is the definition of canonical: http://hl7.org/fhir/datatypes.html#canonical
A URI that refers to a resource by its canonical URL (resources with a url property). The canonical type differs from a uri in that it has special meaning in this specification, and in that it may have a version appended, separated by a vertical bar (|).
It is basically a URL that refers to the actual definition of the message.
2) It's listed 0..1 so it is not required.
3) See above.
Lloyd McKenzie (May 19 2020 at 01:01):
MessageDefinition is the computable way of sharing the definition for what the message is supposed to look like. It's a good idea to have one because it provides a 'standard' way to set the rules for what the message is supposed to contain. However, you don't have to.
Wadii TAHRI (May 19 2020 at 10:12):
Hello,
Please how we can make link between MessageHeader and MessageDefinition using canolical?
Thank you
Lloyd McKenzie (May 19 2020 at 15:27):
You specify the MessageDefinition.url value in MessageHeader.definition.reference
Lloyd McKenzie (May 19 2020 at 15:28):
Read https://build.fhir.org/references.html
Last updated: Apr 12 2022 at 19:14 UTC