Open Source · Self-Hostable

Drug data, always cached
and ready

A config-driven Go microservice that caches upstream REST APIs in MongoDB. Ships with DailyMed, FDA openFDA, and RxNorm endpoints — add more with a few lines of YAML. Serves consumers in under 50ms. When upstreams go down, cached data keeps you running.

$ docker compose up
19
API Endpoints
<50ms
Cache Response
3
Data Sources
Go
Single Binary
Cached drug data,
one request away

Query cached DailyMed, FDA, and RxNorm data. Cross-slug search, autocomplete, bulk lookups, and per-slug metadata. All responses are JSON with freshness info.

GET /api/cache/{slug}

Cached Data Retrieval

Fetch cached upstream data by slug. Returns paginated results with freshness metadata and staleness indicators.

{ "data": [{ "product_ndc": "0002-1433", "brand_name": "Metformin Hydrochloride", "dosage_form": "TABLET" }], "meta": { "slug": "fda-ndc", "results_count": 1187, "stale": false } }
GET /api/search?q=metformin

Cross-Slug Search

Full-text search across all cached data sources. Results grouped by slug with match counts and duration.

{ "query": "metformin", "total_matches": 42, "results": [{ "slug": "fda-ndc", "matches": 28, "items": [{ "brand_name": "Metformin HCl" }] }], "duration_ms": 23.4 }
GET /api/autocomplete?q=met

Typeahead Autocomplete

Fast prefix-match search for typeahead UIs. Returns ranked drug name suggestions from cached data.

{ "query": "met", "suggestions": [ "Metformin Hydrochloride", "Metoprolol Succinate", "Methotrexate", "Methylphenidate" ] }
POST /api/cache/{slug}/bulk

Bulk Cache Lookup

Submit multiple parameter sets in a single request. Returns results for each query with timing info.

{ "results": [ { "params": { "search": "metformin" }, "count": 28 }, { "params": { "search": "lisinopril" }, "count": 15 } ], "total_queries": 2, "duration_ms": 45.2 }
Batteries included

Everything you need to run a reliable drug data cache. No assembly required.

Circuit Breakers

Automatic circuit breakers on every upstream API. Force-refresh cooldowns and stale-serve fallback keep consumers healthy.

📊

Prometheus Metrics

Cache hit rates, upstream latency, MongoDB health, scheduler stats, system metrics. Grafana dashboards and alerting rules included.

📝

Config-Driven

Add any REST API with a few lines of YAML — URL, pagination style, TTL, schedule. Hot-reloads on save via fsnotify. No code changes needed.

Stop hitting upstream APIs directly

Self-host in minutes. One binary, one config file, one Docker Compose command.