CTS2-LE REST API: Read Value Set Definitions
A general note on value sets (vs) and value set definitions (vsd):
The underlying implementation of the CTS2 information model identifies a vs by its uri only. A specific definition of a vsd will then have its own name (resourceID wrt. the information model) and a versionId. A vsd can be uniquely identified by the pair of versionOf and versionId. Since the resourceID is a system intern identifier, using it as a path parameter to identify a vsd is not suitable. Because of that any call that
a.) tries to reference a vs by its name rather than by its uri (versionOf) or
b.) tries to reference a vsd without specifying the version id and the uri
will result in an exception.
Response format and language may be controlled either by a Query Parameter: ?referencelanguage={language} or ?format={format} OR by the HTTP 'Accept' and 'Accept-Language' Header Parameters. Query OR Header parameters will both be accepted as valid, however, the Query parameters will ALWAYS take precedence over the Header parameters, if both are present.
Currently, we only support application/xml as format (except for the grouping calls). The language attribute will be ignored.
Root-URL: /WebCts2LE/rest/
Inhaltsverzeichnis
Request all value set groups
- does not belong to the standard CTS2 REST specification
- Path: /valuesetgroups
- Method: GET
- Path Parameters: -
- Query Parameters: -
- returns: an array in which each item represents a value set group
Example Response Structure
[
{
"name": "FHIR",
"relGroup": "FHIR-vs",
"_id": "72"
},
{
"name": "HL7-v3",
"relGroup": "HL7-v3-vs",
"_id": "76"
},
{
"name": "Example",
"relGroup": "EXA-vs",
"_id": "84"
},
{
"name": "EFAv2.x",
"relGroup": "EFAv2.x-vs",
"_id": "88"
}
]
Request value set definitions (vsd) for a given group id
- does not belong to the standard CTS2 REST specification
- Path: /valuesetgroup/{groupid}
- Method: GET
- Path Parameters:
- groupid the id of the group whose items are requested; the id that is used to reference the group is given in the resulting array that is returned when calling /valuesetgroups
- Query Parameters: -
- returns: an array that contains the value set definitions belonging to the requested group
Example Response Structure for call /valuesetgroup/84
[
{
"name": "value-set-99",
"isLeaf": true,
"versionId": "2014-11-01",
"versionOf": "urn:oid:1.2.3.4"
}
]
Meaning of the entry properties:
- name: the resourceID of the value set definitions (see CTS2 information model for further reference)
- isLeaf: true if there are no subordinated value set definitions
- versionId: the versionId that is used to reference the value set definition (see CTS2 information model for further reference)
- versionOf: the uri of the value sets that this specific definition belongs to (see CTS2 information model for further reference)