npm i @medishift/sdk
Docs
The whole surface, on one page.
REST and GraphQL share the same Postgres. The MCP server is a 1:1 translation layer over REST. Pick the shape your runtime speaks.
REST
Versioned at /v1. Breaking changes get a /v2 with ≥ 18 months of overlap.
| Method | Path | What it does |
|---|---|---|
| GET | /v1/drugs?q=…&country=CH&limit=20 | Typeahead. Trigram on name, prefix on ATC, ingredient lookup. country accepts CH, DE, FR, IT, ES, AT, UK, US, … |
| GET | /v1/drugs/:id | Full record + identifiers + indications + contraindications. |
| GET | /v1/drugs/:id/monograph?lang=de | AIPS / SmPC / DailyMed monograph subset. Languages depend on source jurisdiction. |
| GET | /v1/drugs/lookup?system=ndc11&code=00021011230 | Resolve a US National Drug Code to the canonical record. |
| GET | /v1/drugs/lookup?system=gtin&code=7680651870019 | Resolve a Swiss / EU GTIN — same shape across jurisdictions. |
| GET | /v1/drugs/lookup?system=…&code=… | Other systems: dmd, cis, pzn, aic, ema-eudra, swissmedic, rxcui, unii, pharmacode. |
| POST | /v1/interactions/check | Pairwise + N-way interaction check. Body: { drugs: [...] }. |
| GET | /v1/atc/:code{,/children,/drugs} | ATC node + label translations + DDD; descendants; mapped drugs. |
| GET | /v1/changes?since=…&limit=500 | Diff feed for cache invalidation. Cursor pagination. |
| POST | /v1/prescriptions/validate | PHI · opt-in · routes through PHI Gateway. Bucketed context only. |
GraphQL
Hosted at /v1/graphql. Persisted queries on Growth+.
type Drug {
id: ID!
productName: String!
atc: AtcCode
manufacturer: String
identifiers: [Identifier!]!
indications(lang: Language): [Indication!]!
contraindications: [Contraindication!]!
monograph(lang: Language): Monograph
interactionsWith(drugs: [DrugInput!]!): [Interaction!]!
}
type Query {
drugs(q: String, atc: String, country: String, limit: Int): [Drug!]!
drug(id: ID!): Drug
drugByCode(system: IdentifierSystem!, code: String!): Drug
atc(code: String!): AtcCode
changes(since: DateTime!, limit: Int): ChangeConnection!
}MCP
See the MCP server page for the full tool catalog and install snippets.
SDKs & adapters
pip install medishift
npm i @medishift/react
npm i @medishift/hl7v2
FHIR R4 Medication resource via ?format=fhir on every drug endpoint — needed for CH-EPR and most national EHR shells. HL7v2 RXE helper carries the precompiled Pharmacode / NDC / dm+d → RxNorm + ATC + UCUM mapping.
Data sources & attribution
28 public sources across 13 jurisdictions. Every API response cites sources under _meta.sources. Public-source-only, by choice.
Switzerland
5 sourcesFederal price list. Monthly tab-delimited CSV, ~13k rows. Public-domain redistribution with attribution.
Swissmedic-curated monograph store. Weekly XML, ~120MB. DE/FR/IT full text.
ATC-pair interaction JSON. Severity A/B/C/D/X + mechanism + recommendation. MIT-style.
Nightly CSV bridging Pharmacode ↔ GTIN ↔ Swissmedic-No for OTC longtail.
Authorisation register + dispensing category + recall feed. Weekly XLSX.
Europe
15 sourcesNHS Dictionary of Medicines and Devices. Weekly XML via TRUD. VTM/VMP/AMP hierarchy.
AEMPS Centro de Información online de Medicamentos. JSON + SmPC PDFs.
Base de données publique des médicaments. Tab-separated, monthly. CIS codes.
PZN registry + Pharmazentralnummer mapping. PDF + XML.
Italian medicines agency drug bank. AIC codes + price tariff XLSX.
Austrian arzneispezialitätenregister. Public XLSX export.
Substance, Product, Organisation, Referential master data. ISO IDMP-aligned.
Danish medicines agency drug index. CSV.
Swedish MPA approved drugs register. CSV.
Finnish medicines agency public product register. XML.
Norwegian medicines agency product register. CSV.
Dutch Medicines Evaluation Board register. XML.
Belgian Federal Agency for Medicines product DB. XLSX.
Irish Health Products Regulatory Authority register. CSV.
Portuguese authority drug index. CSV.
United States
8 sourcesNational Drug Code Directory. Weekly text dump, ~120k rows.
FDA Approved Drug Products with Therapeutic Equivalence Evaluations. Monthly TSV.
NLM SPL monograph store. Bulk XML download, weekly.
Normalised drug naming + RXCUI ingredient mapping. Monthly RRF.
Unique Ingredient Identifier registry. Weekly TSV.
Controlled-substance schedule list. Quarterly PDF + parsed CSV.
CMS billing code catalogue, J-codes for injectables. Quarterly TXT.
FDA umbrella API: drug labels, recalls, FAERS adverse events. JSON.
Cross-jurisdictional
1 sourceCross-jurisdictional drug classification. Yearly CSV. Commercial WHO licence held centrally.
HCI Solutions (CH), Vidal (FR), Rote Liste (DE), BNF (UK), USP-NF (US), KNMP G-Standaard (NL), and Austria-Codex (AT) are deliberately excluded from the shared catalogue. Customers with their own licence can BYOL credentials for per-tenant passthrough. See the watchtower for ingestion details.