Social Care Interoperability Platform FHIR Implementation Guide
Version: 0.1.0, Status: draft
Social Care Interoperability Platform FHIR Implementation Guide - Local Development build (v0.1.0) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions
| Draft as of 2026-06-10 |
<StructureMap xmlns="http://hl7.org/fhir">
<id value="Patient-Registration"/>
<text>
<status value="generated"/>
<div xmlns="http://www.w3.org/1999/xhtml"><p class="res-header-id"><b>Generated Narrative: StructureMap Patient-Registration</b></p><a name="Patient-Registration"> </a><a name="hcPatient-Registration"> </a><pre class="fml">
<b>map</b><span style="color: navy"> "</span>https://metadata.phase2.scip.synanetics.cloud/fhir/r4/StructureMap/Patient-Registration<span style="color: navy">" = "</span>PatientToRegistration<span style="color: navy">"
</span><b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-MODS-Patient.html" title="MODS Patient">https://metadata.phase2.scip.synanetics.cloud/fhir/r4/StructureDefinition/MODS-Patient</a><span style="color: navy">" </span><b>alias </b>Patient <b>as </b><b>source</b>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-MODS-RegistrationStatus.html" title="MODS Registration Status">https://metadata.phase2.scip.synanetics.cloud/fhir/r4/StructureDefinition/MODS-RegistrationStatus</a><span style="color: navy">" </span><b>alias </b>RegistrationStatus <b>as </b><b>target</b>
<b>group </b>PatientRegistration<span style="color: navy">(</span><b>source</b> <span style="color: maroon">src</span><span style="color: navy"> : </span>Patient, <b>target</b> <span style="color: maroon">tgt</span><span style="color: navy"> : </span>RegistrationStatus<span style="color: navy">)</span><span style="color: navy"> {
</span> src<span style="color: navy"><b> -> </b></span>tgt.subjectOfCareId = evaluate<span style="color: navy">(</span>src<span style="color: navy">, </span>id<span style="color: navy">)</span> <i>"867e3c30-bdfe-4f6e-b5fe-bf0957312f58"</i><span style="color: navy">;</span>
src<span style="color: navy"><b> -> </b></span> tgt.meta<b> as </b><span style="color: maroon">meta</span><span style="color: navy">, </span> meta.dataClass<b> as </b><span style="color: maroon">dataClass</span><b> then</b><span style="color: navy"> {
</span> src<span style="color: navy"><b> -> </b></span>dataClass.name = <span style="color: blue">'Registration'</span> <i>"7806cf8c-72e4-46dc-bdbd-32c5c9e5d5f8"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setDataClassName"</i><span style="color: navy">;</span>
src.meta<b> as </b><span style="color: maroon">meta</span><b> then</b><span style="color: navy"> {
</span> src<span style="color: navy"><b> -> </b></span>tgt.updatedAt = evaluate<span style="color: navy">(</span>meta<span style="color: navy">, </span>lastUpdated<span style="color: navy">)</span> <i>"06106e07-df65-4c3b-8bb2-8ada21e43815"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setUpdatedAt"</i><span style="color: navy">;</span>
src.meta<b> as </b><span style="color: maroon">meta</span><span style="color: navy">, </span>meta.tag<b> as </b><span style="color: maroon">tag</span><b> where </b>$this.system='https://yhcr.nhs.uk/pix/registration/status'and$this.code!='success'<b> then</b><span style="color: navy"> {
</span> src<span style="color: navy"><b> -> </b></span>tgt.status = evaluate<span style="color: navy">(</span>tag<span style="color: navy">, </span>code<span style="color: navy">)</span> <i>"c67d24be-4560-4104-89b2-5c01159d990e"</i><span style="color: navy">;</span>
src<span style="color: navy"><b> -> </b></span>tgt.reason = evaluate<span style="color: navy">(</span>tag<span style="color: navy">, </span>display<span style="color: navy">)</span> <i>"5d59340c-e41f-4358-a227-786b904b3bae"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setStatusAndReason"</i><span style="color: navy">;</span>
src.contained<b> as </b><span style="color: maroon">contained</span><span style="color: navy">, </span>contained<b> as </b><span style="color: maroon">oo</span><b> where </b>$this.resourceType='OperationOutcome'<b> then</b><span style="color: navy"> {
</span> oo.issue<b> as </b><span style="color: maroon">issue</span><span style="color: navy"><b> -> </b></span>tgt.diagnostics = evaluate<span style="color: navy">(</span>issue<span style="color: navy">, </span>diagnostics<span style="color: navy">)</span><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setErrorDiagnostics"</i><span style="color: navy">;</span>
src.meta<b> as </b><span style="color: maroon">meta</span><span style="color: navy">, </span>meta.tag<b> as </b><span style="color: maroon">tag</span><b> where </b>$this.system='https://yhcr.nhs.uk/pix/registration/status'and$this.code='success'<b> then</b><span style="color: navy"> {
</span> src<span style="color: navy"><b> -> </b></span>tgt.status = <span style="color: blue">'success'</span> <i>"65554b50-2cbe-4b3d-b585-d65e38066bad"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setSuccessStatus"</i><span style="color: navy">;</span>
tgt<b> where </b>$this.status.exists().not()<b> then</b><span style="color: navy"> {
</span> tgt<span style="color: navy"><b> -> </b></span>tgt.status = <span style="color: blue">'unknown'</span> <i>"e08b0daa-a19a-4992-96f0-d124a86933b6"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"da470550-add5-4098-bdf4-d7d4d145d626"</i><span style="color: navy">;</span>
"setUnknownStatus" <i>"7fb80f03-3e33-4d80-8faa-35b2cb9a7d14"</i><span style="color: navy">;</span>
<span style="color: navy">}
</span></pre></div>
</text>
<url
value="https://metadata.phase2.scip.synanetics.cloud/fhir/r4/StructureMap/Patient-Registration"/>
<version value="0.1.0"/>
<name value="PatientToRegistration"/>
<status value="draft"/>
<date value="2026-06-10T19:05:58+00:00"/>
<publisher
value="Synanetics Ltd on behalf of DHSC/Social Care Interoperability Platform"/>
<contact>
<name
value="Synanetics Ltd on behalf of DHSC/Social Care Interoperability Platform"/>
<telecom>
<system value="url"/>
<value value="https://synanetics.com"/>
</telecom>
<telecom>
<system value="email"/>
<value value="info@synanetics.com"/>
</telecom>
</contact>
<jurisdiction>
<coding>
<system value="urn:iso:std:iso:3166"/>
<code value="GB"/>
<display value="United Kingdom of Great Britain and Northern Ireland"/>
</coding>
</jurisdiction>
<structure>
<url
value="https://metadata.phase2.scip.synanetics.cloud/fhir/r4/StructureDefinition/MODS-Patient"/>
<mode value="source"/>
<alias value="Patient"/>
</structure>
<structure>
<url
value="https://metadata.phase2.scip.synanetics.cloud/fhir/r4/StructureDefinition/MODS-RegistrationStatus"/>
<mode value="target"/>
<alias value="RegistrationStatus"/>
</structure>
<group>
<name value="PatientRegistration"/>
<typeMode value="none"/>
<input>
<name value="src"/>
<type value="Patient"/>
<mode value="source"/>
</input>
<input>
<name value="tgt"/>
<type value="RegistrationStatus"/>
<mode value="target"/>
</input>
<rule>
<name value="867e3c30-bdfe-4f6e-b5fe-bf0957312f58"/>
<source>
<context value="src"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="subjectOfCareId"/>
<transform value="evaluate"/>
<parameter>
<valueId value="src"/>
</parameter>
<parameter>
<valueString value="id"/>
</parameter>
</target>
</rule>
<rule>
<name value="setDataClassName"/>
<source>
<context value="src"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="meta"/>
<variable value="meta"/>
</target>
<target>
<context value="meta"/>
<contextType value="variable"/>
<element value="dataClass"/>
<variable value="dataClass"/>
</target>
<rule>
<name value="7806cf8c-72e4-46dc-bdbd-32c5c9e5d5f8"/>
<source>
<context value="src"/>
</source>
<target>
<context value="dataClass"/>
<contextType value="variable"/>
<element value="name"/>
<transform value="copy"/>
<parameter>
<valueString value="Registration"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setUpdatedAt"/>
<source>
<context value="src"/>
<element value="meta"/>
<variable value="meta"/>
</source>
<rule>
<name value="06106e07-df65-4c3b-8bb2-8ada21e43815"/>
<source>
<context value="src"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="updatedAt"/>
<transform value="evaluate"/>
<parameter>
<valueId value="meta"/>
</parameter>
<parameter>
<valueString value="lastUpdated"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setStatusAndReason"/>
<source>
<context value="src"/>
<element value="meta"/>
<variable value="meta"/>
</source>
<source>
<context value="meta"/>
<element value="tag"/>
<variable value="tag"/>
<condition
value="$this.system='https://yhcr.nhs.uk/pix/registration/status'and$this.code!='success'"/>
</source>
<rule>
<name value="c67d24be-4560-4104-89b2-5c01159d990e"/>
<source>
<context value="src"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="status"/>
<transform value="evaluate"/>
<parameter>
<valueId value="tag"/>
</parameter>
<parameter>
<valueString value="code"/>
</parameter>
</target>
</rule>
<rule>
<name value="5d59340c-e41f-4358-a227-786b904b3bae"/>
<source>
<context value="src"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="reason"/>
<transform value="evaluate"/>
<parameter>
<valueId value="tag"/>
</parameter>
<parameter>
<valueString value="display"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setErrorDiagnostics"/>
<source>
<context value="src"/>
<element value="contained"/>
<variable value="contained"/>
</source>
<source>
<context value="contained"/>
<variable value="oo"/>
<condition value="$this.resourceType='OperationOutcome'"/>
</source>
<rule>
<name value="issue"/>
<source>
<context value="oo"/>
<min value="1"/>
<max value="1"/>
<element value="issue"/>
<variable value="issue"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="diagnostics"/>
<transform value="evaluate"/>
<parameter>
<valueId value="issue"/>
</parameter>
<parameter>
<valueString value="diagnostics"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setSuccessStatus"/>
<source>
<context value="src"/>
<element value="meta"/>
<variable value="meta"/>
</source>
<source>
<context value="meta"/>
<element value="tag"/>
<variable value="tag"/>
<condition
value="$this.system='https://yhcr.nhs.uk/pix/registration/status'and$this.code='success'"/>
</source>
<rule>
<name value="65554b50-2cbe-4b3d-b585-d65e38066bad"/>
<source>
<context value="src"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="status"/>
<transform value="copy"/>
<parameter>
<valueString value="success"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="da470550-add5-4098-bdf4-d7d4d145d626"/>
<source>
<context value="tgt"/>
<condition value="$this.status.exists().not()"/>
</source>
<rule>
<name value="e08b0daa-a19a-4992-96f0-d124a86933b6"/>
<source>
<context value="tgt"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="status"/>
<transform value="copy"/>
<parameter>
<valueString value="unknown"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="7fb80f03-3e33-4d80-8faa-35b2cb9a7d14"/>
<source>
<context value=""setUnknownStatus""/>
</source>
</rule>
</group>
</StructureMap>