Receiving Flags (alerts)

Here is an example message for a Flag event. Mapping of the different fields is elaborated below.

POST /luscii/alerts HTTP/1.1
Host: www.yourserver.com
Connection: close
Content-Type: application/fhir+xml
Content-Length: 123
Authorization: your-api-token
User-Agent: GuzzleHttp/6.3.3 curl/7.52.1 PHP/7.3.6
X-Webhook-Signature: 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef

<?xml version="1.0" encoding="UTF-8"?>
<Flag xmlns="http://hl7.org/fhir">
    <meta>
        <tag>
            <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
            <code value="AlertCreated"/>
        </tag>
    </meta>
    <extension url="http://hl7.org/fhir/StructureDefinition/flag-priority">
        <valueCodeableConcept>
            <coding>
                <system value="http://hl7.org/fhir/flag-priority-code"/>
                <code value="PH"/>
            </coding>
        </valueCodeableConcept>
    </extension>
    <identifier>
        <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
        <value value="51ccbed9-0463-4774-a2f5-df4e7a675a18"/>
    </identifier>
    <status value="active"/>
    <category>
        <coding>
            <system value="urn:luscii:alert-status"/>
            <code value="open"/>
        </coding>
    </category>
    <code>
        <coding>
            <system value="http://snomed.info/sct"/>
            <code value="41236000"/>
            <display value="Abnormal vital signs"/>
        </coding>
    </code>
    <subject>
        <identifier>
            <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
            <value value="0a0e9381-1bc2-4965-90b2-4dad0a26f3a9"/>
        </identifier>
    </subject>
    <period>
        <start value="2020-03-09T14:48:01+01:00"/>
    </period>
</Flag>

POST /luscii/alerts HTTP/1.1
Host: www.yourserver.com
Connection: close
Content-Type: application/fhir+xml
Content-Length: 123
Authorization: your-api-token
User-Agent: GuzzleHttp/6.3.3 curl/7.52.1 PHP/7.3.6
X-Webhook-Signature: 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef


<?xml version="1.0" encoding="UTF-8"?>
<Flag xmlns="http://hl7.org/fhir">
    <id value="a647beff-c516-4059-814b-d20c6dff1c28"/>
    <meta>
        <tag>
            <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
            <code value="AlertCreated"/>
        </tag>
    </meta>
    <contained>
        <Observation xmlns="http://hl7.org/fhir">
            <id value="4de1543c-5d9a-4d11-bfea-41cd1c443545"/>
            <identifier>
                <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
                <value value="4de1543c-5d9a-4d11-bfea-41cd1c443545"/>
            </identifier>
            <status value="final"/>
            <code>
                <coding>
                    <system value="http://snomed.info/sct"/>
                    <code value="363787002"/>
                    <display value="Observable entity"/>
                </coding>
                <coding>
                    <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
                    <code value="legacy|wgt"/>
                    <display value="Weight (legacy)"/>
                </coding>
            </code>
            <subject>
                <identifier>
                    <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
                    <value value="0a0e9381-1bc2-4965-90b2-4dad0a26f3a9"/>
                </identifier>
            </subject>
            <effectiveDateTime value="2019-03-04T10:56:01+01:00"/>
            <dataAbsentReason>
                <coding>
                    <system value="http://terminology.hl7.org/CodeSystem/data-absent-reason"/>
                    <code value="not-performed"/>
                </coding>
            </dataAbsentReason>
        </Observation>
    </contained>
    <contained>
        <Flag xmlns="http://hl7.org/fhir">
            <id value="0e86579b-a26d-415b-ac3b-2a98d6459039"/>
            <extension url="http://hl7.org/fhir/StructureDefinition/flag-detail">
                <valueReference>
                    <reference value="#4de1543c-5d9a-4d11-bfea-41cd1c443545"/>
                </valueReference>
            </extension>
            <extension url="http://hl7.org/fhir/StructureDefinition/flag-priority">
                <valueCodeableConcept>
                    <coding>
                        <system value="http://hl7.org/fhir/flag-priority-code"/>
                        <code value="PL"/>
                    </coding>
                </valueCodeableConcept>
            </extension>
            <identifier>
                <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
                <value value="0e86579b-a26d-415b-ac3b-2a98d6459039"/>
            </identifier>
            <status value="active"/>
            <code>
                <coding>
                    <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
                    <code value="overdue"/>
                    <display value="Observation not performed"/>
                </coding>
            </code>
            <subject>
                <identifier>
                    <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
                    <value value="0a0e9381-1bc2-4965-90b2-4dad0a26f3a9"/>
                </identifier>
            </subject>
            <period>
                <start value="2019-03-04T10:56:05+01:00"/>
            </period>
        </Flag>
    </contained>
    <extension url="http://hl7.org/fhir/StructureDefinition/flag-detail">
        <valueReference>
            <reference value="#4de1543c-5d9a-4d11-bfea-41cd1c443545"/>
        </valueReference>
    </extension>
    <extension url="http://hl7.org/fhir/StructureDefinition/flag-detail">
        <valueReference>
            <reference value="#0e86579b-a26d-415b-ac3b-2a98d6459039"/>
        </valueReference>
    </extension>
    <extension url="http://hl7.org/fhir/StructureDefinition/flag-priority">
        <valueCodeableConcept>
            <coding>
                <system value="http://hl7.org/fhir/flag-priority-code"/>
                <code value="PL"/>
            </coding>
        </valueCodeableConcept>
    </extension>
    <identifier>
        <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
        <value value="a647beff-c516-4059-814b-d20c6dff1c28"/>
    </identifier>
    <status value="active"/>
    <category>
        <coding>
            <system value="urn:luscii:alert-status"/>
            <code value="open"/>
        </coding>
    </category>
    <code>
        <coding>
            <system value="http://snomed.info/sct"/>
            <code value="408367005"/>
            <display value="Patient forgets to take medication"/>
        </coding>
    </code>
    <subject>
        <identifier>
            <system value="urn:oid:2.16.840.1.113883.2.4.3.135"/>
            <value value="0a0e9381-1bc2-4965-90b2-4dad0a26f3a9"/>
        </identifier>
    </subject>
    <period>
        <start value="2019-03-04T10:56:05+01:00"/>
    </period>
</Flag>

Notes:

  • Actual message may or may not contain newlines and indentation.
  • The resource may be expanded with additional attributes in the future.
  • The subject identifier is Luscii's patient uuid.

Fields

Meta tags

Event typeDescription
AlertCreatedA new alert was created
AlertEscalatedAn existing alert was escalated to another user
AlertProcessedAn open alert was processed (i.e., closed

Priority codes

FHIR Priority codeMeaningLuscii alert color
PHHigh PriorityRed
PMMedium PriorityAmber
PLLow PriorityGray

Category codes

Category codeLuscii alert status
openOpen for first-line healthcare professional
escalatedOpen for second-line healthcare professional
processedProcessed or closed

Flag meaning

SystemCodeDisplayLuscii meaning
http://snomed.info/sct408367005Patient forgets to take medicationOverdue alert
http://snomed.info/sct118227000Vital signs findingCombination alert
http://snomed.info/sct418799008Finding reported by subject or history providerComment alert
http://snomed.info/sct423986002Does not follow recommended medication scheduleInactivity alert
http://snomed.info/sct404684003Clinical findingFallback if not matchable otherwise (should not happen)
http://snomed.info/sct41236000Abnormal vital signsMeasurement alert