2nd DSTU Draft For Comment

This page is part of the FHIR Specification (v0.4.0: DSTU 2 Draft). The current version which supercedes this version is 5.0.0. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3 R2

Operation-valueset-expand

This is the narrative for the resource. See also the XML or JSON format.

Value Set Expansion

OPERATION: Value Set Expansion

The definition of a value set is used to create a simple collection of codes suitable for use for data entry or validation.

If the operation is not called at the instance level, one of the in parameters identifier or valueset must be provided.

An expanded value set will be returned, or an OperationOutcome with an error message

URL: [base]/ValueSet/$Value Set Expansion

URL: [base]/ValueSet/[id]/$Value Set Expansion

Parameters

UseNameCardinalityTypeDocumentation
INidentifier0..1uri

A logical value set identifier (i.e. ValueSet.identifier). The server must know the value set (e.g. it is defined explicitly in the server's valuesets, or it is defined implicitly by some code system known to the server

INvalueSet0..1ValueSet

The value set is provided directly as part of the request. Servers may choose not to accept value sets in this fashion

INfilter0..1string

A text filter that is applied to restrict the codes that are returned (this is useful in a UI context)

INdate0..1dateTime

The date for which the expansion should be generated. Normally, this is the current conditions (which is the default value) but under some circumstances, systems need to generate an expansion as it would have been in the past. A typical example of this would be where code selection is constrained to the set of codes that were available when the patient was treated, not when the record is being edited. Note that which date is appropriate is a matter for implementation policy.

OUTreturn1..1ValueSet

The result of the expansion

The value set expansion returned by this query should be treated as a transient result that will change over time (whether it does or not depends on how the value set is specified), so applications should repeat the operation each time the value set is used.

Different servers may return different results from expanding a value set for the following reasons:

  • The underlying code systems are different (e.g. different versions, possibly with different defined behaviour)
  • The server optimises filter includes differently, such as sorting by code frequency
  • Servers introduce arbitrary groups to assist a user to navigate the lists based either on extensions in the definition, or additional knowledge available to the server

 

Usage note: every effort has been made to ensure that the examples are correct and useful, but they are not a normative part of the specification.