Site icon Hay on FHIR

clinFHIR Package Viewer

When an Implementation Guide is built by the IG Publisher (and presumably other build applications like simplifier), one of the outputs is a zipped package (actually a tarball)  that contains all the FHIR resources defined by the Implementation guide – profiles, extension definitions, terminology and conformance resources and such like. It’s based on the NPM package scheme as described on the HL7 Confluence page.

This package can then be saved in the International FHIR registry so that it can be discovered and downloaded by implementers. There’s a description of the registry on the HL7 confluence site, as well as from the registry itself.

While the package doesn’t contain the textual part of the IG, it does have all the computable artefacts that an implementer might need, as well as a manifest file (package.json) which contains a number of goodies about the IG – such as the canonical url, which can be used to view the full IG.

This post is to introduce a new clinFHIR module that can display the contents of a package. It works by downloading a copy of the package from the FHIR registry and saving it on the clinFHIR server.  Subsequently, the contents can be displayed to the user. The download only needs to happen once, as a particular version of a package is immutable – it is guaranteed not to change.

The package viewer is located at http://clinfhir.com/packageViewer.html. The front page looks like this (note that the module is being actively enhanced at the moment so may well change over time).

The viewer defaults to loading the IPS (International Patient Summary) package – just so the display has something to show (and it’s an important IG). The image above has the AllergyIntolerance profile selected.

To select another package, there are 2 options.

There’s actually a 3rd option – the viewer can be invoked with the package details, which will cause the package to be displayed immediately (it will be downloaded from the registry if necessary). This ability is used by the Connectathon Manager application to allow Connectathon attendees easy access to the Viewer for an Implementation Guide.

The Viewer has the following layout.

The actual detail shown will depend on the resource type. The ‘raw json’ of the resource is always shown, but some types have specific functionality. These are described in the remainder of this post.

Implementation Guide

This contains the ImplementationGuide resource, as well as the package.json file.

Resource Profile

Profiles on resource types are represented by StructureDefinition resources (as are extension definitions). There are a number of sub-tabs available:

Extension definition

Also described by a StructureDefinition, this has a summary tab of the extension, as well as the snapshot tab and raw StructureDefinition json

ValueSet

All ValueSets defined in the package. Contains tabs to explore the ValueSet contents (similar to that provided for coded elements in the profile) as well as the ValueSet json. Like the view from the profile, it is possible to upload the ValueSet to the Terminology server so that the expansion can work. Note that you may also need to upload any CodeSystems that the ValueSet uses (see next section)

CodeSystem

A list of the contents of the CodeSystem, and the resource Json. Like the ValueSet there is also the option to upload a CodeSystem to the Terminology server if it isn’t already there.

ConceptMap

A table with the translations, and the resource Json

CapabilityStatement, OperationDefinition and SearchParameter

Groupings for each of these types. Some have specialized tabs – all have the resource Json. The CapabilityStatement is borrowed from the clinFHIR Server query module.

DataType profile

As well as profiling a resource type, it’s also possible to profile a datatype – for example to add additional elements to an address or name, or to constrain existing elements. There is a tree view of the profiled DataType as well as the raw json.

Miscellaneous

Resources in the package other than those mentioned above.

Examples

The examples group is slightly different to the others. Within the accordion is a list of the resource types for which there is at least one example. When that is selected, a list of all the examples of that type is shown to the right – selecting one will display the example. All examples are in Json.

As always, use the FHIR Chat if you have issues or suggestions for this module.

Exit mobile version