Skip to main content

Get Mappings for a Concept

Find how a concept maps to other vocabularies:
get() returns one page. pageSize defaults to 100 and the server caps it at 200, so a concept with more mappings than that yields a subset that looks exactly like a complete answer. When you are building a code list, use getAll() or getIter() below.

Get Every Mapping

getAll() walks all pages and collects them. Errors are accumulated rather than thrown, so a partial result is distinguishable from a complete one:
getIter() is the streaming equivalent - it yields one mapping at a time and throws OMOPHubIteratorError on the first failed page:
Both accept the same filters as get(), plus pageSize and maxPages:

Page Through Manually

Filter by Target Vocabulary

Relationship Types

The endpoint returns Maps to relationships by default. Composite concepts decompose across two relationships, and asking only for the default gets you half the answer:
Without Maps to value you learn the patient is allergic to a drug but not which drug. This is the Value-as-Concept pattern - the target belongs in value_as_concept_id on the OMOP row, not in the main concept column. getIter() and getAll() take the same option.

Invalid Mappings

includeInvalid defaults to true on this endpoint. Pass false to return only mappings whose relationship and target concept are currently valid:
The source concept is never filtered, so a deprecated concept still returns what it maps to - which is usually why you looked it up.
This parameter was accepted but not applied before 2026-08-11. The default matches what the endpoint returned then, so nothing changes unless you pass false.

Use Specific Vocabulary Version

Map Multiple Concepts

Map a batch of concept IDs to a target vocabulary:

Map Using Vocabulary Codes

Map concepts directly using vocabulary codes instead of OMOP concept IDs:
Use sourceCodes when you have vocabulary-specific codes (e.g. SNOMED codes from your source system). Use sourceConcepts when you already have OMOP concept IDs. You cannot use both in the same request - the SDK enforces this at the type level via a discriminated union and re-validates at runtime so JS callers also get a structured missing_required_field error rather than a wire 400.

Map with Specific Mapping Type

Filter mappings by type:

Vocabulary Release Pinning

vocabRelease is sent as a query-string parameter, not in the JSON body - matches the Python SDK convention:

Procedure-Domain Vocabulary Priority

For Procedure-domain sources, the API applies a fallback vocabulary priority when targetVocabulary is left to “best fit” semantics:

Common Use Case: SNOMED → ICD-10

Option 1: Direct mapping using vocabulary codes (recommended)
Option 2: Using OMOP concept IDs

Idempotency

POST endpoints (mappings.map) only retry on transient failures when an Idempotency-Key is provided:

Parameters