healthcare.dev docs
API referenceSearch

Search codes and drugs by meaning

GET /v1/search

GET https://api.healthcare.dev/v1/search

Finds codes and drugs from plain-language descriptions, even when the words differ from the official text (diabetes with kidney disease finds E11.22, Type 2 diabetes mellitus with diabetic chronic kidney disease). Searches ICD-10-CM, ICD-10-PCS, HCPCS Level II, RxNorm and NDC products together, or the systems in system. Each result has a match_score (0 to 1; an exact code or id is 1 and always ranks first), a short reason saying why it matched, and, on the first result when the top results are close but from different code families, did_you_mean with the alternatives. Ranking blends closeness in meaning with the query words the text contains; it is computed from stored data, with no external service involved. Returns up to the best 100 matches per system. Builder plan and up; other plans get 403 plan-upgrade-required.

Requires an API key: Authorization: Bearer hdev_live_.... See Authentication.

Query parameters

NameTypeRequiredDescriptionExample
qstringyesWhat you're looking for, in plain words or a codediabetes with kidney disease
limitintegernoPage size (max 100)25
cursorstringnoOpaque cursor from links.next
systemstringnoOnly these systems, comma-separated: icd10cm, icd10pcs, hcpcs, rxnorm, ndc (default all)icd10cm
view"compact" | "full"nocompact returns only the fields an agent usually needs (fewer tokens); full (default) returns every fieldcompact
fieldsstringnoComma-separated record fields to return, e.g. code,display,billablecode,display,billable

Examples

curl

curl "https://api.healthcare.dev/v1/search?q=diabetes+with+kidney+disease&limit=25" \
  -H "Authorization: Bearer $HDEV_API_KEY"

TypeScript

const res = await fetch("https://api.healthcare.dev/v1/search?q=diabetes+with+kidney+disease&limit=25", {
  headers: { Authorization: `Bearer ${process.env.HDEV_API_KEY}` },
});
const { data, meta } = await res.json();

Python

import os
import requests

res = requests.get("https://api.healthcare.dev/v1/search?q=diabetes+with+kidney+disease&limit=25", headers={"Authorization": f"Bearer {os.environ['HDEV_API_KEY']}"})
body = res.json()

Try it

GEThttps://api.healthcare.dev/v1/search?q=diabetes+with+kidney+disease&limit=25&system=icd10cm&view=compact&fields=code%2Cdisplay%2Cbillable
Get a free key
Copy as curl
curl "https://api.healthcare.dev/v1/search?q=diabetes+with+kidney+disease&limit=25&system=icd10cm&view=compact&fields=code%2Cdisplay%2Cbillable" \
  -H "Authorization: Bearer $HDEV_API_KEY"

Response

Results, best first

{
  "data": [
    {
      "system": "icd10cm",
      "code": "string",
      "display": "string",
      "status": "string",
      "href": "string",
      "match_score": 0,
      "reason": "string",
      "did_you_mean": [
        {
          "system": null,
          "code": null,
          "display": null
        }
      ],
      "record": {
        "system": "icd10cm",
        "code": "E11.9",
        "display": "Type 2 diabetes mellitus without complications",
        "description": "Type 2 diabetes mellitus without complications",
        "billable": true,
        "parent": "E11",
        "attributes": {},
        "status": "active",
        "effective_start": "2015-10-01",
        "effective_end": null,
        "replaced_by": []
      }
    }
  ],
  "meta": {
    "source": "cms-icd10",
    "data_version": "2026.1",
    "retrieved_at": "2026-10-24T12:00:00Z",
    "license": "Public domain (CMS). Reference data, not medical advice."
  },
  "links": {
    "self": "/v1/search?q=diabetes+with+kidney+disease&limit=25",
    "next": "/v1/search?q=diabetes+with+kidney+disease&limit=25&cursor=eyJrIjoiRTExLjkifQ"
  }
}

Fields

FieldTypeAlways presentDescription
systemSearchSystemyes
codestringyesThe code (icd10cm, icd10pcs, hcpcs), RxCUI (rxnorm) or product NDC (ndc)
displaystringyesDescription or drug name
statusstringyesactive (retired records are not searched by meaning)
hrefstringyesLookup path for the full record, e.g. /v1/codes/icd10cm/E11.22
match_scorenumberyesHow well this result matches the query, 0 to 1: 1 is an exact code or id, 0.9 a code prefix; otherwise a blend of closeness in meaning and the query words the text contains (see reason). Below 0.5, check the result before relying on it.
reasonstringyesWhy it matched, in a few words, e.g. matches "kidney" in the description; close in meaning to "diabetes"
did_you_meanSearchAlternative[]noOn the first result only, when the query is ambiguous: the top results are close in score but from different code families. The best match of each other family; narrow the query or pass system to choose.
recordnoThe full record (view=full, the default)

Errors

Errors are application/problem+json (RFC 9457). Branch on type, not on title. See Errors.

StatustypeWhen
400invalid-requestA parameter or the body failed validation; errors lists each field.
401unauthorizedMissing, malformed or revoked API key.
403plan-upgrade-requiredThe plan doesn't include this feature; required_plan names the plan that does.
404not-foundNo record with that id (retired records are still returned).
429rate-limited / quota-exceededToo many requests per second (retry after Retry-After), or the monthly quota is used up.
503dataset-unavailable / unavailableThe dataset has no published version yet, or the service is degraded.

On this page