Version Availability - $versions

Firely Server can be configured to support multiple FHIR versions. $versions operation returns the list of available versions. This is a system-level operation.

Operation details

The client shall invoke the operation with no parameters. The response lists all currently available and enabled FHIR versions. It also lists the default version which is used when no fhirVersion parameter is listed in a request. Supported response formats are:

  1. application/fhir+xml or application/fhir+json results in a Parameters resource as a response. FHIR Versions are listed as items of the resource.

  2. application/json or application/xml.

Configuration

In the PipelineOptions section of the appsettings it is enabled by default when Vonk.Plugin.Operations is present in the include section:

"PipelineOptions": {
    "PluginDirectory": "./plugins",
    "Branches": [
      {
        "Path": "/",
        "Include": [
          ...
          "Vonk.Plugin.Operations",
        ],
        "Exclude": [
          ...
        ]
      }, ...etc...

Manual control over this operation is possible by using Vonk.Plugin.Operations.VersionsOperationConfiguration in either include or exclude sections.

Example

Request:

GET <base-url>/$versions
Accept: application/fhir+json

Response:

{
    "resourceType": "Parameters",
    "parameter": [
        {
            "name": "version",
            "valueString": "3.0"
        },
        {
            "name": "version",
            "valueString": "4.0"
        },
        {
            "name": "version",
            "valueString": "5.0"
        },
        {
            "name": "default",
            "valueString": "4.0"
        }
    ]
}