Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between id and identifier for a FHIR resource?

Tags:

hl7-fhir

The Resource entity define an id attribute as "Logical id of this artifact". Meanwhile for resources like MedicationRequest also define an attribute named identifier. The description is "External identifier" or "Business identifier".

I'm wondering what's the difference between these two attributes? From the RESTful API definition like update, the id can be used to uniquely locate the resource, like POST [base]/[resource]/[id]. After POST another GET should be able to retrieve that resource using GET [base]/[resource]/[id]. It's more like something similar to a storage identifier. Then how about that identifier?

like image 601
mg0880gm Avatar asked Apr 26 '19 06:04

mg0880gm


People also ask

What is identifier in FHIR?

According to the FHIR specification: “Each resource has an “id” element which contains the logical identity of the resource assigned by the server responsible for storing it.”. This identifier will differ if the resource is moved or persisted on another server (it is analogous to the primary key in a database).

What is resource type in FHIR?

FHIR Resource Types can be: Administrative. Patient, Practitioner, Organization, Location, Coverage, Invoice.

What is metadata in FHIR?

In DSTU-2 the metadata moved from outside the resource to inside the resource. The LogicalId has moved into the Resource itself and there is now a “Meta” data type that can exist on every FHIR resource. This datatype looks like this: And can be accessed like: Patient.Meta.lastUpdated.


1 Answers

the .id is controlled by the local server. As a resource is coped from server to server, it will change. it's basically the internal primary key for the object, and it's entirely controlled by the FHIR server itself (or, more precisely, by the interaction between the client and server). So it's not a portable identifier.

But almost all the resources correspond to (somewhat) real world entities that also are recorded in other systems, and that are assigned portable identifiers that are used across multiple systems to track the entity. These identifiers are constant as a resource (or other forms of representation of the real world entity) are copied around and moved from place to place. Some identifiers are assigned by external (government) agencies. Identifiers includes things like Patient MRNs, Provider Numbers etc. Often, because of distributed record processing, entities have many identifiers to carry, and there's a whole business in arbitrating between them.

like image 179
Grahame Grieve Avatar answered Sep 24 '22 07:09

Grahame Grieve