Dashboard

MS-DRG Search

Search Medicare Severity Diagnosis Related Group codes.

Endpoint

GET /v1/msdrg/search

Quick Start

Node.js
import { Fhirfly } from "@fhirfly-io/terminology";

const client = new Fhirfly({ apiKey: "YOUR_API_KEY" });

// Search for cardiac-related MS-DRGs
const results = await client.msdrg.search({
  q: "cardiac"
});

console.log(`Found ${results.total} DRGs`);
for (const item of results.items) {
  console.log(`DRG ${item.drg_code}: ${item.title} (${item.type})`);
}

Parameters

Parameter Description Example
q General text search across DRG titles and descriptions q=cardiac

Filters

Parameter Type Description Example
mdc string Major Diagnostic Category (01-25, PRE) 05, PRE
type string Surgical or medical classification SURG, MED

Pagination & Response

Parameter Default Max Description
limit 20 100 Results per page
page 1 100 Page number
shape compact --- compact, standard, full
sort relevance --- relevance, code, title

Example Response

{
  "facets": {
    "mdc": {
      "05": 92,
      "01": 45,
      "08": 38,
      "04": 32
    },
    "type": {
      "MED": 345,
      "SURG": 401
    }
  },
  "has_more": true,
  "items": [
    {
      "drg_code": "280",
      "title": "ACUTE MYOCARDIAL INFARCTION, DISCHARGED ALIVE WITH MCC",
      "mdc": "05",
      "type": "MED"
    },
    {
      "drg_code": "231",
      "title": "CORONARY BYPASS WITHOUT CARDIAC CATH WITH MCC",
      "mdc": "05",
      "type": "SURG"
    }
  ],
  "limit": 2,
  "meta": {
    "legal": {
      "attribution_required": false,
      "citation": "CMS MS-DRG Definitions Manual. CMS.gov. Accessed 2026-03-15 via FHIRfly.",
      "license": "public_domain",
      "source_name": "CMS MS-DRG"
    }
  },
  "page": 1,
  "total": 127,
  "total_capped": false
}

Use Cases

Filter by Major Diagnostic Category

Node.js
// Find all DRGs in MDC 05 (Diseases of the Circulatory System)
const results = await client.msdrg.search({
  mdc: "05"
});

Search Surgical DRGs Only

Node.js
// Find surgical DRGs for joint procedures
const results = await client.msdrg.search({
  q: "joint",
  type: "SURG"
});

Search Medical DRGs

Node.js
// Find medical DRGs for respiratory conditions
const results = await client.msdrg.search({
  q: "pneumonia",
  type: "MED"
});

Pre-MDC DRGs

Pre-MDC DRGs are assigned before the MDC classification step (e.g., transplants, tracheostomies):

Node.js
const results = await client.msdrg.search({
  mdc: "PRE"
});

Facets

MS-DRG search returns these facets:

Facet Description
mdc Distribution by Major Diagnostic Category
type Distribution by surgical/medical classification

Major Diagnostic Categories

MDC Description
PRE Pre-MDC (Transplants, Tracheostomies, ECMO)
01 Diseases and Disorders of the Nervous System
02 Diseases and Disorders of the Eye
03 Diseases and Disorders of the Ear, Nose, Mouth and Throat
04 Diseases and Disorders of the Respiratory System
05 Diseases and Disorders of the Circulatory System
06 Diseases and Disorders of the Digestive System
07 Diseases and Disorders of the Hepatobiliary System and Pancreas
08 Diseases and Disorders of the Musculoskeletal System and Connective Tissue
09 Diseases and Disorders of the Skin, Subcutaneous Tissue and Breast
10 Endocrine, Nutritional and Metabolic Diseases and Disorders
11 Diseases and Disorders of the Kidney and Urinary Tract
12 Diseases and Disorders of the Male Reproductive System
13 Diseases and Disorders of the Female Reproductive System
14 Pregnancy, Childbirth and the Puerperium
15 Newborns and Other Neonates with Conditions Originating in the Perinatal Period
16 Diseases and Disorders of Blood, Blood Forming Organs and Immunological Disorders
17 Myeloproliferative Diseases and Disorders, Poorly Differentiated Neoplasms
18 Infectious and Parasitic Diseases, Systemic or Unspecified Sites
19 Mental Diseases and Disorders
20 Alcohol/Drug Use and Alcohol/Drug Induced Organic Mental Disorders
21 Injuries, Poisonings and Toxic Effects of Drugs
22 Burns
23 Factors Influencing Health Status and Other Contacts with Health Services
24 Multiple Significant Trauma
25 Human Immunodeficiency Virus Infections

Required Scope

msdrg.search

See Also