The FHIR Practitioner
and PractitionerRole
resources are mapped from the HL7v3 AgentDirectory
where the Agent
is an AgentPerson
.
Mapped to (JSON FHIR Practitioner resource field) | Mapped from (XML HL7 / other) |
---|---|
id | Agent / id [@root] |
identifier[0].value | Agent / id [@extension] |
identifier[0].system | https://fhir.hl7.org.uk/Id/gmp-number |
meta.profile[0] | fixed value = "https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-GPC-Practitioner-1" |
name[0].use | fixed value = official |
name[0].family | Agent / AgentPerson / name / family or else "unknown" |
name[0].given[0] | Agent / AgentPerson / name / given |
name[0].prefix[0] | Agent / AgentPerson / name / prefix |
Example JSON
{
"resource": {
"resourceType": "Practitioner",
"id": "C5DEFBF3-0174-BC6F-182C-B777B9C6FF43",
"meta": {
"profile": [
"https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-GPC-Practitioner-1"
]
},
"name": [
{
"use": "official",
"family": "Doe",
"given": [
"John"
],
"prefix": [
"Dr"
]
}
],
"identifier": [ {
"system": "https://fhir.hl7.org.uk/Id/gmp-number",
"value": "112233"
} ]
}
}
The following Practitioner
fields are not currently populated by the adaptor:
- implicitRules
- language
- text
- contained
- extension
- modifierExtension
- active
- name.id
- name.text
- name.suffix
- name.period
- telecom
- address
- gender
- birthDate
- photo
- qualification
A PractionerRole
resource will only be added if the HL7 AgentPerson
has an associated representedOrganization
.
Mapped to (JSON FHIR PractitionerRole resource field) | Mapped from (XML HL7 / other) |
---|---|
id | Agent / id [@root] appended with -PR |
meta | fixed value = "https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-GPC-PractitionerRole-1" |
practitioner.reference | Reference to the mapped Practitioner (see above) |
organization.reference | Reference to the Organisation mapped from Agent / representedOrganization |
code | Agent / code as described in the XML > FHIR section of Codeable Concept |
Example JSON
{
"resource": {
"resourceType": "PractitionerRole",
"id": "94F00D99-0601-4A8E-AD1D-1B564307B0A6-PR",
"meta": {
"profile": [
"https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-GPC-PractitionerRole-1"
]
},
"practitioner": {
"reference": "Practitioner/94F00D99-0601-4A8E-AD1D-1B564307B0A6"
},
"organization": {
"reference": "Organization/94F00D99-0601-4A8E-AD1D-1B564307B0A6-ORG"
},
"code": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "309394004",
"display": "General Practitioner Principal"
}
],
"text": "Partner"
}
]
}
}
The following PractitionerRole
fields are not currently populated by the adaptor:
- implicitRules
- language
- contained
- modifierExtension
- identifier
- active
- period
- practitioner.id
- practitioner.identifier
- practitioner.display
- organization.id
- organization.identifier
- organization.display
- code.id
- code.coding
- specialty
- location
- healthcareService
- telecom
- availableTime
- notAvailable
- availabilityExceptions
- endpoint
A Practitioner is mapped to an Agent
with a role of AgentPerson
.
Mapped to (XML HL7) | Mapped from (JSON FHIR / other source ) |
---|---|
Agent / id [@root] | New UUID generated by the adaptor |
Agent / code [@nullFlavor] | fixed value = "UNK" |
Agent / code / originalText | PractionerRole.code[0].coding[0].display 1 |
Agent / AgentPerson / name | Practitioner.name[0].text 2 |
Agent / AgentPerson / name / prefix | Practitioner.name[0].prefix[0] |
Agent / AgentPerson / name / given | Practitioner.name[0].given[0] |
Agent / AgentPerson / name / family | Practitioner.name[0].family or "Unknown" 2 |
Agent / representedOrganisation | Mapped using the Organisation referenced in PractionerRole (if present) 3 |
- Where the
practitionerRole
references the practitioner - If
Practitioner.name[0].given
orPractitioner.name[0].family
are empty andPractitioner.name[0].text
has a string as a value, thenAgent / AgentPerson / name
is populated with the unstructured string. In the case where all three JSON fields are missing / emptyAgent / AgentPerson / name / family
is set to"Unknown"
. - The mapping of
representedOrganisation
is outlined in the Organisation mapping documentation.
Example XML
<Agent classCode="AGNT">
<id root="BDB45F13-D71B-474B-9A12-BB39A53B6273"/>
<code nullFlavor="UNK">
<originalText>General Medical Practitioner</originalText>
</code>
<agentPerson classCode="PSN" determinerCode="INSTANCE">
<name>
<prefix>Mr</prefix>
<given>NHS</given>
<family>Test</family>
</name>
</agentPerson>
<representedOrganization classCode="ORG" determinerCode="INSTANCE">
<name>TEMPLE SOWERBY MEDICAL PRACTICE</name>
<telecom use="WP" value="tel:01133800000"/>
<addr use="WP">
<streetAddressLine>Fulford Grange</streetAddressLine>
<streetAddressLine>Micklefield Lane</streetAddressLine>
<streetAddressLine>Rawdon</streetAddressLine>
<streetAddressLine>Rawdon</streetAddressLine>
<streetAddressLine>Leeds</streetAddressLine>
<postalCode>LS19 6BA</postalCode>
</addr>
</representedOrganization>
</Agent>