FHIR Ids and Identifiers

How does a FHIR resource id differ from a resource identifier?

The distinction between them is not always obvious to those new to FHIR. Look at this Patient resource for August T. Faulkner.

The resource has an id of “eacce214-93d1-41cd-5cd8-866c785dc5f1” — a random GUID generated by the FHIR server when the resource was created.

  • Every resource stored in FHIR must have an id
  • It does not change for the lifetime of the resource
  • It is unique to that resource type in that FHIR server
  • No meaning should be inferred from its value

The last point is interesting, as many online examples of resources use meaningful id values such as “patient” or “blood-pressure-observation.

These are misleading and can cause confusion as they suggest the id itself has some meaning. It doesn’t.

Here’s how to look up the above patient using the resource’s id:

  • /Patient/eacce214-93d1-41cd-5cd8-866c785dc5f1
  • /Patient?_id=eacce214-93d1-41cd-5cd8-866c785dc5f1

More about the resource id.

Our patient August T. Faulkner also has a Medical Record Number — possibly provided by the hospital — of 78510398960.

This is added to the same FHIR resource as an identifier.

Identifiers in FHIR are business identifiers. Unlike the FHIR resource id they are not created by the FHIR server and have no connection to the server.

Examples of other identifiers used for patients are:

  • Social security number
  • Health card number
  • Passport number

A patient resource in FHIR may have any number of identifiers of various types, or none at all.

Here’s how you look up the patient August T. Faulkner using his Medical Record Number:

  • /Patient?identifier=78510398960
  • /Patient?identifier=http://my.localhospital.ie/fhir/patient-MRN|78510398960

More about identifiers.
And identifier types.

Here’s the Patient resource for August T. Faulkner on the HAPI test server:

http://hapi.fhir.org/baseR4/Patient/eacce214-93d1-41cd-5cd8-866c785dc5f1

Discussion

---

Work With Me

Discover more from Darren Devitt

Subscribe now to keep reading and get access to the full archive.

Continue reading