Skip to main content
curl -X GET "https://api.omophub.com/v1/concepts/201826/level" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "success": true,
  "data": {
    "concept_id": 201826,
    "level": 0,
    "depth_from_root": 4,
    "breadth_at_level": null,
    "total_descendants": 15,
    "total_ancestors": 3
  },
  "meta": {
    "request_id": "req_concept_level_123",
    "timestamp": "2024-12-22T10:00:00Z",
    "vocab_release": "2025.1"
  }
}

Overview

This endpoint returns basic hierarchical positioning information for a concept, including its depth from root concepts and counts of ancestors and descendants.

Path Parameters

conceptId
integer
required
The unique OMOP concept ID to get level information for

Query Parameters

vocab_release
string
Specific vocabulary release version (e.g., β€œ2025.1”)

Response

success
boolean
required
Indicates whether the request was successful
data
object
required
Response data containing concept level information
meta
object
required
Response metadata and API information
curl -X GET "https://api.omophub.com/v1/concepts/201826/level" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "success": true,
  "data": {
    "concept_id": 201826,
    "level": 0,
    "depth_from_root": 4,
    "breadth_at_level": null,
    "total_descendants": 15,
    "total_ancestors": 3
  },
  "meta": {
    "request_id": "req_concept_level_123",
    "timestamp": "2024-12-22T10:00:00Z",
    "vocab_release": "2025.1"
  }
}

Usage Examples

Basic Level Information

Get hierarchy level for a concept:
curl -X GET "https://api.omophub.com/v1/concepts/201826/level" \
  -H "Authorization: Bearer YOUR_API_KEY"

With Specific Vocabulary Version

Get level information for a specific vocabulary release:
curl -X GET "https://api.omophub.com/v1/concepts/201826/level?vocab_release=2025.1" \
  -H "Authorization: Bearer YOUR_API_KEY"

Important Notes

  • Depth interpretation - depth_from_root indicates how many β€œIs a” relationship steps exist between this concept and the root
  • Descendant count - total_descendants includes all child concepts at any depth below
  • Ancestor count - total_ancestors includes all parent concepts up to the root