How I Unified 3 Fragmented Medical APIs Into a Single Python SDK

Published: (February 28, 2026 at 07:28 PM EST)
2 min read
Source: Dev.to

Source: Dev.to

Overview

I built MedKit because medical data is notoriously difficult to work with. Correlating a drug’s FDA label with its latest clinical trial phases and related research papers typically requires juggling three different APIs, handling idiosyncratic JSON schemas, and dealing with inconsistent identifier types. MedKit is a unified Python SDK that transforms these fragmented sources (OpenFDA, PubMed, and ClinicalTrials.gov) into a single, programmable platform.

Key Features

  • Unified Client – One MedKit() client to rule them all. No more multiple API keys or manual correlation.
  • Clinical Synthesis (med.conclude()) – Aggregates data to give a “snapshot” verdict on a drug or condition, including an evidence‑strength score (0.0–1.0).
  • Interaction Engine – Detects drug‑drug contraindications using cross‑label mentions (brand vs. generic).
  • Medical Relationship Graph – Visualizes connections between drugs, trials, and research papers as a knowledge graph.
  • Intelligence Layer – Natural‑language routing (med.ask()) to query data in plain English.

Why Use It?

Most healthcare developers spend ≈ 80 % of their time just cleaning and joining data. MedKit handles the plumbing—caching, schema normalization, and relationship mapping—so you can focus on analysis or application logic.

Tech Stack

  • Language: Python (both synchronous and asynchronous APIs)
  • Caching: Disk and in‑memory options
  • Architecture: Provider‑based design for easy extensibility

Getting Started

pip install medkit-sdk
from medkit import MedKit

# Initialize the unified client
client = MedKit()

# Example: Get a clinical synthesis for a drug
summary = client.med.conclude("aspirin")
print(summary.verdict, summary.evidence_score)

Extensibility

The provider‑based architecture makes it straightforward to add new data sources, such as pharmacogenomics databases or emerging clinical registries.

Feedback & Contributions

I’d love to hear your thoughts on the med.conclude() synthesis logic, other features, and which additional providers (e.g., pharmacogenomics) would be valuable.

  • GitHub repository:
  • PyPI: medkit-sdk

Your support—whether through issues, pull requests, or starring the repo—is greatly appreciated.

0 views
Back to Blog

Related posts

Read more »