FHIR Implementation Guide Lab2patient V1.0.0

Uit informatiestandaarden
Ga naar: navigatie, zoeken

Icoon Nictiz Cirkel Informatie Oranje.svg

This IG is currently under development and can not be considered stable and ready for use.


FunctionalTechnicalFunctioneel-Technisch


1 Introduction

Go to functional design

This page describes the technical design of Lab2patient (L2P) as a subset of the Information standard lab exchange (Dutch: Labuitwisseling or abbreviated to LU). This technical specification is implementer centric and complements the functional design. This page uses various terms as defined in the glossary. This page implements general principles applicable to FHIR as outlined by a central FHIR IG for R4. Please make sure you familiarize yourself with both the functional design and the FHIR IG for full appreciation of the context of this page.

Many laboratory results have important relationships to other observations and need to be grouped together. The FHIR specification defines several structures to do this:

  • Observation and one or more Observation.hasMember elements.
    • Each .hasMember element references another Observation and the Observation with .hasMember elements thus serves as grouper for all Observations it references. Each Observation can be accessed individually. This is useful for panels and/or batteries of tests. This is what NL-CM:13.1.3 LaboratoryTest maps into.
    • Note that while FHIR Observation also allows references to resource types MolecularSequence and QuestionnaireResponse, there is no identified use case for that at the time of writing.
    • An Observation without .hasMember elements is expected to be an individual result and has a value when one can be/is determined.
  • Observation and one or more Observation.derivedFrom elements.
    • Each .derivedFrom element references another Observation references related measurements the observation is made from. This is what NL-CM:13.1.33 RelatedResult::LaboratoryTestResult maps into.
    • Note that while FHIR Observation also allows references to resource types DocumentReference, ImagingStudy, Media, QuestionnaireResponse and MolecularSequence, there is no identified use case for those at the time of writing.
  • Observation and one or more Observation.component elements.
    • .component elements of an Observation are not accessible individually. Whenever you access the Observation, you also access all its components. This is mostly useful when certain context is provided around the result. For lab observations this is expected to be less common. An example outside of the lab realm could be BloodPressure where systolic, diastolic, and cuff size are all in one Observation with 3 components.

This FHIR implementation guide assumes that systems (XIS) are able to make a connection to the right systems. It does not provide information on finding the right XIS nor does it provide information about security including authentication and authorization. Finding the right system, and security aspects of the connection, are dealt with by the infrastructure. Any relevant infrastructure is expected to have a framework in place to deal with this. The only assumption/requirement for an infrastructure is that this allows RESTful FHIR-based exchange as specified here.

2 Boundaries and relationships

2.1 Mappings between profiles and data set

Each transaction starts with links to the functional definition in an ART-DECOR publication and references one or several FHIR profiles. Where the functional definition contains all specific data elements for the transaction (prefixed with ‘lu-concept-v2’), the FHIR profiles only contain a mapping to these data elements that do not have a dependency on a zib counterpart. For example: ‘lu-concept-v2-4266’ (Specimen) has a relation with the zib element with id ‘NL-CM-13.1.2’, therefore no mapping with ‘lu-concept-v2-4266’ can be found in the profiles. On the other hand, ‘lu-concept-v2-4296’ (LaboratoryResultIdentification) has no relation with a zib element, therefore a mapping can be found in the relevant FHIR profile.

Because of open world modeling, the cardinality of elements in the FHIR profiles can be less strict than the cardinalities in the ART-DECOR transactions. However, the latter cardinality is leading when it comes to exchanging building blocks in the context of a specific transaction. For example: in the nl-core-LaboratoryTestResult profile, .performer has a core cardinality of 0..*, while in both the 'Send laboratory results' and ‘Serve laboratory results’ ART-DECOR transactions, the Performer element has a cardinality of 1..1 M. Therefore, .performer is expected to be filled with either a reference to an nl-core-HealthcareProvider-Organization resource.

Each transaction contains a Patient building block with cardinality 1..1 M. This patient is the subject of all other building blocks in the transaction, although no explicit relation exists in the data set. Therefore, a reference to a Patient resource conforming to the nl-core-Patient profile is expected in .subject of each FHIR instance of each building block.

Laboratory results in FHIR R4 overview

The single zib LaboratoryTestResult consists of objects that in FHIR are represented using different (instances of) resources:

  • NL-CM:13.1.1 LaboratoryTestResult maps into profile nl-core-LaboratoryTestResult Observation and has .hasMember relationships with individual NL-CM:13.1.3 LaboratoryTests.
    • Note that this level only exists when LaboratoryTestResult contains NL-CM:13.1.4 PanelOrBattery. The concepts NL-CM:13.1.7 ResultType, NL-CM:13.1.5 Comment, and NL-CM:13.1.6 ResultStatus are not mapped in the absence of NL-CM:13.1.4 PanelOrBattery.
  • NL-CM:13.1.3 LaboratoryTest also maps into profile nl-core-LaboratoryTestResult Observation and MAY be referenced by a different Observation.hasMember containing NL-CM:13.1.1 LaboratoryTestResult.
  • NL-CM:13.1.2 Specimen maps into profile nl-core-LaboratoryTestResult.Specimen Specimen.
    • Note that there could be multiple instances of Specimen: one for the main NL-CM:13.1.16 SpecimenMaterial, and one per isolated NL-CM:13.1.22 Microorganism with a .parent relationship to the main specimen.
  • NL-CM:13.1.29 SpecimenSource maps into profile nl-core-LaboratoryTestResult.Specimen.Source Device. This is a special case where the specimen did not come from the Patient directly.

2.2 Patient identification

This implementation guide assumes that the client system is able to make a connection to the right server that contains the patient's information. It does not provide information on finding the right server nor does it provide information about security. Moreover, each transaction is performed in the context of a specific (authenticated) patient, whose context might have been established using the authentication mechanisms described in external specifications such as the MedMij Afsprakenstelsel or through the usage of search parameters for patient identification. Each server is required to perform filtering based on the patient associated with the context for the request or based on the patient identification search parameters, so only the records associated with the authenticated patient are returned.

When patient identification requires the use of search parameters, the following search parameters SHALL be supported:

  • Patient: identifier
  • Observation: patient

An example of a request that retrieves all Observation resources of a patient with a fake BSN of 11122233:

GET [base]/Observation?patient:identifier=http://fhir.nl/fhir/NamingSystem/bsn|111222333

2.3 Resource identification

All profiles used within the information standard contain .identifier elements with a cardinality of 0..* because of open world modeling. However, all ART-DECOR transactions referenced within this IG assign a 1..1 R cardinality, meaning a stable identifier SHOULD be provided, or the DataAbsentReason extension if a value is missing. Identifiers SHALL contain both a .system and a .value.

Because in HL7v3 (CDA) an identifier can only be composed using OIDs, the .system SHALL be an OID to accommodate compatibility in transformations to and from FHIR. The Dutch HL7v3 datatype variant of II also defines additional restrictions on the maximum length of both @root and @extension (equivalent to respectively .system and .value in FHIR). For the same compatibility reasons, .system SHALL have a maximum of 128 characters and .value SHALL have a maximum of 64 characters.

Systems that encounter or resolve references, either logical or literal, in resources they receive, SHALL NOT rewrite these references to a copy of these resources (with http://nictiz.nl/fhir/StructureDefinition/ext-CopyIndicator present) they may store. This means that relative literal references may need to be rewritten to absolute ones. This also goes for included secondary resources in transactions.

2.4 FHIR Profile Package

All use cases in this specification depend on the same set of FHIR profiles. The table below lists profiles that represent applicable zibs for laboratory result information exchange.

FHIR Profile FHIR Resource Based on zib (EN)
nl-core-LaboratoryTestResult Observation LaboratoryResult
nl-core-LaboratoryTestResult.Specimen Specimen
nl-core-LaboratoryTestResult.Specimen.Source Device
nl-core-Patient Patient Patient
nl-core-HealthcareProvider-Organization Organization HealthcareProvider

3 Actors involved

Actors Systems FHIR CapabilityStatements
Name Description Name Description Name Description
Patient The user of a personal healthcare environment. PHR Personal health record CapabilityStatement: Lab2Healthcare-Results-RetrieveServe Retrieve [LAB-LRR-PGO]/serve [LAB-LRB-PGO] lab results requirements.
Lab Professional The user of a LIS LIS Laboratory information system

4 Use cases

4.1 Patient retrieves laboratory results in their PGO

4.1.1 Introduction

This FHIR implementation guide assumes that the PHR system is able to make a connection to the right LIS that contains the patient's information. It does not provide information on finding the right LIS nor does it provide information about security. Moreover, each transaction is performed in the context of a specific authenticated patient, for whose context (token) has been established using the authentication mechanisms described in the 'Afsprakenstelsel'. Each XIS Gateway is required to perform filtering based on the patient associated with the context for the request, so only the records associated with the authenticated patient are returned. For this reason, search parameters should not be included for patient identification.

4.1.2 Actors

Transaction group Transaction Actor Role
Retrieve laboratory results (PULL) Retrieve laboratory results request LaboratoriumresultaatResultaatRaadplegend Systeem [LAB-LRR-PGO] Send a query to the LAB-LRB-PGO to retrieve lab results
Retrieve laboratory results response LaboratoriumresultaatResultaatBeschikbaarstellend Systeem [LAB-LRB-PGO] Respond to a query from the LAB-LRR-PGO to retrieve lab results

4.1.3 Invocations

4.1.3.1 LAB-LRR-PGO: request message

The request message represents an HTTP GET parameterized query from the PHR (LAB-LRR-PGO) to the LIS (LAB-LRB-PGO).

4.1.3.1.1 Trigger events

When the PHR wants to obtain laboratory results, it issues a retrieve laboratory results request message.

4.1.3.1.2 Message semantics

The PHR (LAB-LRR-PGO) executes an HTTP GET conforming to the FHIR RESTful and search specification against the LIS's Observation endpoint.

  • Laboratory results are all under the .category observation, using query parameter category as token.
  • Requesting data for a specific .subject is done using query parameter patient as reference, or on some network infrastructures with an authorization token. The FHIR query parameter type reference can take on many forms.
    • If you know what the Patient.id is, e.g. from previous interactions with the same endpoint, you may use:
      • patient=[id]
      • patient=[type]/[id]
      • patient=[url]
    • If you don't know what the Patient.id is, but you know the Patient.identifier, e.g. the Burgerservicenummer (BSN), you may use:
      • patient:identifier=[system]|[value]
  • Requesting laboratory results of a specific type is done using query parameter code as token.
  • Requesting laboratory results of a specific date (range) is done using query parameter date as token.

Basic query syntax

GET [base]/Observation?category=http://terminology.hl7.org/CodeSystem/observation-category|laboratory{&patient=Patient/[id] | &patient:identifier=[system]|[value]}{&[parameter(s)]&_include=[resource(s)]}

Examples

Parameter values have not been uri escaped in these examples for readability. This is likely necessary in practice.

Query parameters overview

Servers SHALL at minimum support all stated parameters and modifiers, and MAY support additional parameters and modifiers. Clients SHALL support required parameters, and MAY support optional parameters.

  • category - token - 1..1 required - fixed value http://terminology.hl7.org/CodeSystem/observation-category|laboratory
  • patient - token - 0..1 conditional - required if not solved using an alternative method like an authorization token
    • Modifier :identifier - 0..1 optional - required when searching by identifier
  • code - token - 0..1 optional
  • date - date - 0..1 optional
    • Prefix eq - 0..1 optional - required when searching for results with .effective on exact date
    • Prefix lt - 0..1 optional - required when searching for results with .effective before date
    • Prefix le - 0..1 optional - required when searching for results with .effective on or before date
    • Prefix gt - 0..1 optional - required when searching for results with .effective after date
    • Prefix ge - 0..1 optional - required when searching for results with .effective on or after date
  • _count - positiveInt - 0..1 optional
  • _include - reference - 0..* optional - useful for request to include secondary related resources, e.g.:
    _include=Observation:patient,Observation:performer,Observation:has-member,Observation:specimen
    • Note that servers MAY, depending on their read capabilities, choose to implement inclusion of resources regardless of a client requesting this to satisfy the generic requirement that references SHALL be resolvable.

Operations

  • lastn - shortcut FHIR core operation for getting the latest X results of specified types, or 'any' type
    • Parameter max - positiveInt - optional - default is max=1
4.1.3.1.2.1 Expected actions

The LIS (LAB-LRB-PGO) SHALL process the query to retrieve laboratory results.

4.1.3.2 LAB-LRB-PGO: response message

The LIS (LAB-LRB-PGO) returns an HTTP Status code appropriate to the processing as well as a FHIR Bundle including the matching information. Refer to the generic FHIR IG for more information on handling errors and status codes. Not finding a match based on stated parameters does not constitute an error.

4.1.3.2.1 Trigger events

The LIS (LAB-LRB-PGO) completed the processing of the retrieve laboratory results request message.

4.1.3.2.2 Message semantics

The LIS (LAB-LRB-PGO) SHALL process the request and, unless an error is found, respond with a Bundle resource of type searchset. Each Observation matching the request SHALL be marked with .entry.search.mode=match. Each otherwise included resource SHALL be marked with .entry.search.mode=include. If the searchset bundle contains less matching resources than the actual total set, then:

  • the Bundle.link that holds the self link, SHOULD include the _count parameter to inform the client of what max was applied
  • an OperationOutcome SHOULD be included marked with .entry.search.mode=outcome.

The resources in the response Bundle SHALL be a valid instance of their stated profile. All resources SHALL include their related profile canonical URL in the .meta.profile element in order to show compliance. The exception is the OperationOutcome resource for which there is no profile in this specification.

Example searchset Bundle

Example OperationOutcome

4.1.3.2.3 LAB-LRB-PGO: Expected actions

The LIS (LAB-LRB-PGO) SHALL process the response Bundle in accordance with the intentions of the trigger event that caused the retrieve. Actions may include discrete rendering on screen or in context with other information, triggering alerts on trends, ordering of (other) tests and more.