Validating a resource

It’s often helpful to be able to determine whether a particular resource instance is compliant with a given profile or profiles – including the the core profiles defined in the FHIR specification.

The FHIR project has provided validation functionality that can be used for this. It can be downloaded from the spec  and has also been incorporated into a number of the on-line reference servers. This post describes a simple app that acts as an interface to these servers.

There is a separate page that describes the application but briefly it works as follows.

  • Start the app (there is a link from the clinFHIR main page – at the bottom on the left)
  • Past the resource you want to validate into the text box – or enter a url to the resource and load it from there
  • Select the server/s you wish to use to perform the validation. As there can be differences in validate implementation, it is possible to select multiple servers and all will be used to perform the validation
  • Click the ‘Validate’ button, and the results will be shown in tabs on the right.

Here’s an image of the app with a validated resource. Details of the errors will be in each server tab.

validate

There’s more detail in the documentation.

About David Hay
I'm an independent contractor working with companies like Orion Health and Rhapsody, HL7 Fellow, Chair emeritus of HL7 New Zealand and a co-chair of the FHIR Management Group. I have a keen interest in health IT, especially health interoperability with HL7 and the new FHIR standard.

3 Responses to Validating a resource

  1. Xiao says:

    Hi David! Thanks for your wonderful tool! Can I ask you how could I do if I want to use my own profile to validate FHIR resources? Thank you very much for your help.

    • David Hay says:

      Hi Xiao – thanks for the kind words! Right now, you need to place an entry in the meta.profile element of the instance being validated that refers to the canonical url of your profile and ensure that the profile exists on the validation server – that should work. An alternative is to add the profile to in the validation call (rather than the instance) – which is actually the preferred method. I’m working on supporting that in the tool, but it’s not quite finished yet…

  2. Pingback: Dew Drop – December 4, 2019 (#3085) | Morning Dew

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: