Search loading...

API Hub

Explore and Make use of Nationally Defined Messaging APIs

 

PDS Change of GP

The FHIR profiles used for the PDS Change of GP event message bundle

PDS Change of GP event messages are generated by the Spine and published to the NEMS when the registered GP within a patient’s PDS record is changed. The event message contains details of the previous and current registered GP Practice for the patient as per the guidance below.

Bundle structure

Specifies mandatory referencing within the Event Message Bundle.

PDS Change of GP Bundle (open in new TAB)

In the CareConnect-Patient-1 resource, the generalPractitioner element references the organization resource representing the patient’s current GP practice.

In the CareConnect-EpisodeOfCare-1 resource, the managingOrganization element references the organization resource which was the patient’s previous GP practice.

PDS Change of GP Message Life Cycle

The PDS Change of GP event message will always contain a messageEventType extension with value new in the MessageHeader resource. There will be no update or delete version of this event message.

If a subscriber receives multiple PDS Change of GP event messages for the same patient, the last event message as indicated by the meta.lastUpdated element within the MessageHeader resource should be considered the source of truth for the patient’s GP details.

Onward Delivery

The delivery of the PDS Change of GP event messages to subscribers via MESH will use the following WorkflowID within the MESH control file. This WorkflowID will need to be added to the receiving MESH mailbox configuration before event messages can be received.

MESH WorkflowID CHANGEOFGP_1

Resource Population Requirements and Guidance

The following requirements and resource population guidance should be followed in addition to the requirements and guidance outlined in the Generic Requirements page.

Bundle

The Bundle resource is the container for the event message and SHALL conform to the Bundle FHIR profile.

Resource Cardinality 1..1
Element Cardinality Additional Guidance
type 1..1 Fixed value: message

Event-MessageHeader-1

The MessageHeader resource included as part of the event message SHALL conform to the Event-MessageHeader-1 constrained FHIR profile and the additional population guidance as per the table below:

Resource Cardinality 1..1
Element Cardinality Additional Guidance
meta.lastUpdated 1..1 DateTime when the patient record was updated with the details included in this event message. This element should be used for message sequencing
extension(messageEventType) 1..1 Fixed value: new
event 1..1 Fixed Value: pds-change-of-gp-1 (PDS Change of GP)
focus 1..1 This will reference the “CareConnect-Communication-1” resource which contains information relating to the event message.
timestamp 1..1 This timestamp indicates when the message was sent. This date can be used to infer the start date of the new GP registration as the GP system will update the Spine when the patient is registered with the practice.

CareConnect-Communication-1

The Communication resource included in the event message SHALL conform to the CareConnect-Communication-1 constrained FHIR profile and the additional population guidance as per the table below:

Resource Cardinality 1..1
Element Cardinality Additional Guidance
status 1..1 Fixed value: completed
sender 0..1 This will reference the sending organization of the event message.
For PDS events this will be a reference to a CareConnect-Organization-1 resource within the message bundle. *
subject 1..1 This will reference the patient resource representing the patient who is the subject of this event.

CareConnect-Patient-1

The patient resource included in the event message SHALL conform to the CareConnect-Patient-1 constrained FHIR profile and the additional population guidance as per the table below:

Resource Cardinality 1..1
Element Cardinality Additional Guidance
meta.versionId 1..1 This element will contain the serial change number (SCN) of the patient record within Spine at the time this event was published.
identifier 1..1 Patient NHS Number SHALL be included within the nhsNumber identifier slice
generalPractitioner 0..1 References to an organization representing the new GP Practice which is the current primary care provider for the patient. In a de-registration scenario where a new GP is not applied to the patients record, this element will not be included.

The generalPractitioner element does not contain a date indicating when the patient was registered at their new GP practice. The timestamp within the MessageHeader resource may be considered the effective date for the new GP Practice as this is the date when the patient’s GP registration was changed to the new GP on the Spine.

CareConnect-Organization-1

Within the bundle there will be multiple organization resources, including one for the patient’s current GP Practice and one for the patient’s previous GP Practice. Other Organization resources may be included where referenced from within other resources in the bundle. The Organization resources included in the bundle SHALL conform to the CareConnect-Organization-1 constrained FHIR profile and the additional population guidance as per the table below:

Resource Cardinality 1..*
Element Cardinality Additional Guidance
identifier 1..1 The organization ODS code SHALL be included within the odsOrganizationCode identifier slice
name 1..1 A human readable name for the organization SHALL be included in the organization resource
partOf 1..1 Reference to the commissioning organization

* Organization details may be retrieved using the ODS Lookup API as ODSAPI-Organization-1 resources. These MUST then be transformed to CareConnect-Organization-1 resources for use within the event message bundle.

CareConnect-EpisodeOfCare-1

The EpisodeOfCare resource included in the event message SHALL conform to the CareConnect-EpisodeOfCare-1 constrained FHIR profile and the additional population guidance as per the table below.

Where a new GP is registered on the patient record, but there was no previous GP, this resource will not be included in the message.

Resource Cardinality 0..1
Element Cardinality Additional Guidance
status 1..1 Fixed value: finished
type.coding.system 1..1 Fixed value: https://fhir.nhs.uk/STU3/CodeSystem/EMS-PDS-PatientCareProvisionType-1
type.coding.code 1..1 Fixed value: 1
type.coding.display 1..1 Fixed value: Primary care
patient 1..1 The patient who is the focus of this episode of care
managingOrganization 1..1 The previous GP practice
period.start 0..1 Date on which the old GP practice assumed responsibility for the patient.
period.end 0..1 Date on which the old GP Practice stopped being responsible for the patient.

CareConnect-HealthcareService-1

The HealthcareService resource included in the event message SHALL conform to the CareConnect-HealthcareService-1 constrained FHIR profile and the additional population guidance as per the table below:

Resource Cardinality 0..1
Element Cardinality Additional Guidance
providedBy 1..1 This will reference the ‘sender’ organization of the event message.
type 1..1 Fixed value: PDS (Personal Demographics Service)
This will represent the type of service responsible for the event message. This will have a value from the ValueSet EMS-HealthcareServiceType-1

PDS Change of GP Example

<Bundle xmlns="http://hl7.org/fhir">
	<id value="236a1d4a-5d69-4fa9-9c7f-e72bf505aa5b"/>
	<meta>
		<profile value="http://hl7.org/fhir/STU3/StructureDefinition/Bundle"/>
	</meta>
	<type value="message"/>
	<!--Entry for MessageHeader with id, timestamp, event type, source, responsible/publishing organization, communication-->
	<entry>
		<fullUrl value="3cfdf880-13e9-4f6b-8299-53e96ef5ec02"/>
		<resource>
			<MessageHeader>
				<id value="3cfdf880-13e9-4f6b-8299-53e96ef5ec02"/>
				<meta>
					<versionId value="1"/>
					<lastUpdated value="2017-11-01T15:00:33+00:00"/>
					<profile value="https://fhir.nhs.uk/STU3/StructureDefinition/Event-MessageHeader-1"/>
				</meta>
				<extension url="https://fhir.nhs.uk/STU3/StructureDefinition/Extension-RoutingDemographics-1">
					<extension url="nhsNumber">
						<valueIdentifier>
							<system value="https://fhir.nhs.uk/Id/nhs-number"/>
							<value value="9912003888"/>
						</valueIdentifier>
					</extension>
					<extension url="name">
						<valueHumanName>
							<use value="official"/>
							<family value="DAWKINS"/>
							<given value="Jack"/>
						</valueHumanName>
					</extension>
					<extension url="birthDateTime">
						<valueDateTime value="2017-10-02T12:00:00+00:00"/>
					</extension>
				</extension>
				<extension url="https://fhir.nhs.uk/STU3/StructureDefinition/Extension-MessageEventType-1">
					<valueCodeableConcept>
						<coding>
							<system value="https://fhir.nhs.uk/STU3/CodeSystem/MessageEventType-1"/>
							<code value="new"/>
							<display value="New event message"/>
						</coding>
					</valueCodeableConcept>
				</extension>
				<event>
					<system value="https://fhir.nhs.uk/STU3/CodeSystem/EventType-1"/>
					<code value="pds-change-of-gp-1"/>
					<display value="PDS Change of GP"/>
				</event>
				<timestamp value="2019-11-01T15:00:00+00:00"/>
				<source>
					<contact>
						<system value="email"/>
						<value value="ssd.nationalservicedesk@nhs.net"/>
					</contact>
					<endpoint value="urn:nhs:addressing:asid:477121000323"/>
				</source>
				<responsible>
					<reference value="https://directory.spineservices.nhs.uk/STU3/Organization/X26"/>
					<display value="NHS DIGITAL"/>
				</responsible>
				<focus>
					<reference value="urn:uuid:3f98da8c-3fe9-430e-8e7c-6edd078622f0"/>
				</focus>
			</MessageHeader>
		</resource>
	</entry>
	<!--Entry for service type within the Organization i.e. PDS-->
	<entry>
		<fullUrl value="urn:uuid:4c687299-3693-47f0-b477-562b0784d225"/>
		<resource>
			<HealthcareService>
				<id value="4c687299-3693-47f0-b477-562b0784d225"/>
				<meta>
					<profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-HealthcareService-1"/>
				</meta>
				<identifier>
					<system value="https://fhir.nhs.uk/STU3/CodeSystem/EMS-HealthcareServiceType-1"/>
					<value value="PDS"/>
				</identifier>
				<providedBy>
					<reference value="https://directory.spineservices.nhs.uk/STU3/Organization/X26"/>
					<display value="NHS DIGITAL"/>
				</providedBy>
				<type>
					<coding>
						<system value="https://fhir.nhs.uk/STU3/CodeSystem/EMS-HealthcareServiceType-1"/>
						<code value="PDS"/>
						<display value="Personal Demographics Service"/>
					</coding>
				</type>
			</HealthcareService>
		</resource>
	</entry>
	<!--Entry for communication for the event message, with reference to subject and payload-->
	<entry>
		<fullUrl value="urn:uuid:3f98da8c-3fe9-430e-8e7c-6edd078622f0"/>
		<resource>
			<Communication>
				<id value="3f98da8c-3fe9-430e-8e7c-6edd078622f0"/>
				<meta>
					<profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Communication-1"/>
				</meta>
				<status value="completed"/>
				<subject>
					<reference value="urn:uuid:dffd2ca0-dc21-11e7-9296-cec278b6b50a"/>
					<display value="DAWKINS, Jack"/>
				</subject>
				<sent value="2019-12-01"/>
				<payload>
					<contentReference>
						<reference value="urn:uuid:dffd2ca0-dc21-11e7-9296-cec278b6b50a"/>
						<display value="DAWKINS, Jack"/>
					</contentReference>
				</payload>
			</Communication>
		</resource>
	</entry>
	<!--Entry for communication for the Patient with change of GP detail.-->
	<entry>
		<fullUrl value="urn:uuid:dffd2ca0-dc21-11e7-9296-cec278b6b50a"/>
		<resource>
			<Patient>
				<id value="dffd2ca0-dc21-11e7-9296-cec278b6b50a"/>
				<meta>
					<profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Patient-1"/>
				</meta>
				<identifier>
					<extension url="https://fhir.hl7.org.uk/STU3/StructureDefinition/Extension-CareConnect-NHSNumberVerificationStatus-1">
						<valueCodeableConcept>
							<coding>
								<system value="https://fhir.hl7.org.uk/STU3/CareConnect-NHSNumberVerificationStatus-1"/>
								<code value="01"/>
								<display value="Number present and verified"/>
							</coding>
						</valueCodeableConcept>
					</extension>
					<system value="https://fhir.nhs.uk/Id/nhs-number"/>
					<value value="9912003888"/>
				</identifier>
				<name>
					<use value="official"/>
					<family value="DAWKINS"/>
					<given value="Jack"/>
				</name>
				<gender value="male"/>
				<birthDate value="2017-10-02">
					<extension url="http://hl7.org/fhir/StructureDefinition/patient-birthTime">
						<valueDateTime value="2017-10-02T20:12:00+00:00"/>
					</extension>
				</birthDate>
				<address>
					<use value="home"/>
					<line value="4 Sandmoor Drive"/>
					<line value="LEEDS"/>
					<postalCode value="LS17 7DF"/>
				</address>
				<generalPractitioner>
					<reference value="urn:uuid:59a63170-b769-44f7-acb1-95cc3a0cb067"/>
					<display value="SHADWELL MEDICAL CENTRE"/>
				</generalPractitioner>
			</Patient>
		</resource>
	</entry>
	<!--Entry for organisation for current GP with ODS identifier for the primary care organisation with which the patient is registered (GP Practice code)-->
	<entry>
		<fullUrl value="urn:uuid:59a63170-b769-44f7-acb1-95cc3a0cb067"/>
		<resource>
			<Organization>
				<id value="59a63170-b769-44f7-acb1-95cc3a0cb067"/>
				<meta>
					<profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Organization-1"/>
				</meta>
				<identifier>
					<system value="https://fhir.nhs.uk/Id/ods-organization-code"/>
					<value value="B86056"/>
				</identifier>
				<name value="SHADWELL MEDICAL CENTRE"/>
				<partOf>
					<reference value="https://directory.spineservices.nhs.uk/STU3/Organization/02V"/>
					<display value="NHS LEEDS NORTH ICB"/>
				</partOf>
			</Organization>
		</resource>
	</entry>
	<!--Entry for episode of care with reference to finished GP registration.-->
	<entry>
		<fullUrl value="urn:uuid:b13f45db-bd6d-48ef-bf30-3a4c0904a777"/>
		<resource>
			<EpisodeOfCare>
				<id value="b13f45db-bd6d-48ef-bf30-3a4c0904a777"/>
				<meta>
					<profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-EpisodeOfCare-1"/>
				</meta>
				<status value="finished"/>
				<type>
					<coding>
						<system value="https://fhir.nhs.uk/STU3/CodeSystem/EMS-PDS-PatientCareProvisionType-1"/>
						<code value="1"/>
						<display value="Primary care"/>
					</coding>
				</type>
				<patient>
					<reference value="urn:uuid:dffd2ca0-dc21-11e7-9296-cec278b6b50a"/>
					<display value="DAWKINS, Jack"/>
				</patient>
				<managingOrganization>
					<reference value="urn:uuid:e84bfc04-2d79-451e-84ef-a50116506088"/>
					<display value="LIVERSEDGE MEDICAL CENTRE"/>
				</managingOrganization>
				<period>
					<start value="2017-10-09T15:00:00+00:00"/>
					<end value="2017-10-29T15:00:00+00:00"/>
				</period>
			</EpisodeOfCare>
		</resource>
	</entry>
	<!--Entry for organisation with ODS identifier of the General Practitioner or General Practice the patient was previously registered with.-->
	<entry>
		<fullUrl value="urn:uuid:e84bfc04-2d79-451e-84ef-a50116506088"/>
		<resource>
			<Organization>
				<id value="e84bfc04-2d79-451e-84ef-a50116506088"/>
				<meta>
					<profile value="https://fhir.hl7.org.uk/STU3/StructureDefinition/CareConnect-Organization-1"/>
				</meta>
				<identifier>
					<system value="https://fhir.nhs.uk/Id/ods-organization-code"/>
					<value value="B85612"/>
				</identifier>
				<name value="LIVERSEDGE MEDICAL CENTRE"/>
				<partOf>
					<reference value="https://directory.spineservices.nhs.uk/STU3/Organization/03J"/>
					<display value="NHS NORTH KIRKLEES ICB"/>
				</partOf>
			</Organization>
		</resource>
	</entry>
</Bundle>
Tags: fhir

All content is available under the Open Government Licence v3.0, except where otherwise stated