FHIR ConceptMap/$closure for subsumption tables
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
resourceType: '<string>',
parameter: [
{
'parameter[].name': '<string>',
'parameter[].valueString': '<string>',
'parameter[].valueCoding': {},
'parameter[].valueCoding.system': '<string>',
'parameter[].valueCoding.code': '<string>'
}
]
})
};
fetch('https://fhir.omophub.com/fhir/{version}/ConceptMap/$closure', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url 'https://fhir.omophub.com/fhir/{version}/ConceptMap/$closure' \
--header 'Content-Type: application/json' \
--data '
{
"resourceType": "<string>",
"parameter": [
{
"parameter[].name": "<string>",
"parameter[].valueString": "<string>",
"parameter[].valueCoding": {},
"parameter[].valueCoding.system": "<string>",
"parameter[].valueCoding.code": "<string>"
}
]
}
'import requests
url = "https://fhir.omophub.com/fhir/{version}/ConceptMap/$closure"
payload = {
"resourceType": "<string>",
"parameter": [
{
"parameter[].name": "<string>",
"parameter[].valueString": "<string>",
"parameter[].valueCoding": {},
"parameter[].valueCoding.system": "<string>",
"parameter[].valueCoding.code": "<string>"
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"resourceType": "ConceptMap",
"name": "my-closure",
"status": "active",
"group": [
{
"source": "http://snomed.info/sct",
"target": "http://snomed.info/sct",
"element": [
{
"code": "73211009",
"target": [
{ "code": "44054006", "equivalence": "subsumes" },
{ "code": "46635009", "equivalence": "subsumes" }
]
}
]
}
]
}
FHIR ConceptMap/$closure for subsumption tables
Compute and maintain FHIR subsumption closure tables across OMOP concepts - track ancestor/descendant links between vocabulary version updates.
FHIR ConceptMap/$closure for subsumption tables
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
resourceType: '<string>',
parameter: [
{
'parameter[].name': '<string>',
'parameter[].valueString': '<string>',
'parameter[].valueCoding': {},
'parameter[].valueCoding.system': '<string>',
'parameter[].valueCoding.code': '<string>'
}
]
})
};
fetch('https://fhir.omophub.com/fhir/{version}/ConceptMap/$closure', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url 'https://fhir.omophub.com/fhir/{version}/ConceptMap/$closure' \
--header 'Content-Type: application/json' \
--data '
{
"resourceType": "<string>",
"parameter": [
{
"parameter[].name": "<string>",
"parameter[].valueString": "<string>",
"parameter[].valueCoding": {},
"parameter[].valueCoding.system": "<string>",
"parameter[].valueCoding.code": "<string>"
}
]
}
'import requests
url = "https://fhir.omophub.com/fhir/{version}/ConceptMap/$closure"
payload = {
"resourceType": "<string>",
"parameter": [
{
"parameter[].name": "<string>",
"parameter[].valueString": "<string>",
"parameter[].valueCoding": {},
"parameter[].valueCoding.system": "<string>",
"parameter[].valueCoding.code": "<string>"
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"resourceType": "ConceptMap",
"name": "my-closure",
"status": "active",
"group": [
{
"source": "http://snomed.info/sct",
"target": "http://snomed.info/sct",
"element": [
{
"code": "73211009",
"target": [
{ "code": "44054006", "equivalence": "subsumes" },
{ "code": "46635009", "equivalence": "subsumes" }
]
}
]
}
]
}
Overview
Given a set of concept codes, computes all subsumption (is-a) relationships among them and returns a FHIR ConceptMap. Used by advanced FHIR clients for offline hierarchy reasoning. This is a stateless operation — the closure is computed fresh each request.Contract Parameters
FHIR Parameters entries. Include one optional
name entry and between 1 and
50 repeatable concept entries.Show parameter entries
Show parameter entries
Entry name:
name for the client-defined closure-table name, or concept
for a concept Coding.Request
curl -X POST "https://fhir.omophub.com/fhir/r4/ConceptMap/\$closure" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/fhir+json" \
-d '{
"resourceType": "Parameters",
"parameter": [
{ "name": "name", "valueString": "my-closure" },
{ "name": "concept", "valueCoding": { "system": "http://snomed.info/sct", "code": "73211009" } },
{ "name": "concept", "valueCoding": { "system": "http://snomed.info/sct", "code": "44054006" } },
{ "name": "concept", "valueCoding": { "system": "http://snomed.info/sct", "code": "46635009" } }
]
}'
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
parameter | array | Yes | FHIR Parameters entries |
parameter[name=name] | string | No | Client-defined closure table name (accepted but not persisted) |
parameter[name=concept] | Coding | Yes (repeatable) | Concept codes to include in the closure (max 50) |
Response
Response Fields
{
"resourceType": "ConceptMap",
"name": "my-closure",
"status": "active",
"group": [
{
"source": "http://snomed.info/sct",
"target": "http://snomed.info/sct",
"element": [
{
"code": "73211009",
"target": [
{ "code": "44054006", "equivalence": "subsumes" },
{ "code": "46635009", "equivalence": "subsumes" }
]
}
]
}
]
}
Limits
- Maximum 50 concepts per request
- POST only (per FHIR specification)
- Stateless — no server-side closure table is maintained
Errors
| HTTP | Issue Code | Cause |
|---|---|---|
| 400 | invalid | No concept parameters provided, or exceeds 50 concepts |
Was this page helpful?