medical-codes-mcp-server
medcode_check_codeValidate whether a US medical code exists, is current, and is billable in the active bundled release. Returns a discriminated status — valid_billable, valid_not_billable, valid_header, or terminated — with a whyNot explaining non-billable and terminated cases (e.g. "valid ICD-10-CM category but not billable — submit a more specific child code"). This is the detail a coder needs before submitting a claim. Auto-detects the system from the code's shape; pass an explicit system to disambiguate. A non-billable or terminated code is a successful result with a whyNot, not an error — only a code that exists in no bundled system raises unknown_code. A code string that also exists in another bundled system carries alsoInSystems naming it, since the verdict applies only to the system that answered.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | The code to validate, with or without dots. Must not be blank or whitespace-only. | |
| system | No | Force the lookup into this system. Omit to auto-detect from the code's shape. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | No | The code in display form (ICD-10-CM carries the dot). | |
| error | No | Present when the call failed. Absent on success. | |
| status | No | Validity status. valid_billable = submit as-is; valid_header/valid_not_billable = needs a more specific code; terminated = retired. | |
| system | No | The system the code was resolved in, echoed for chaining. | |
| whyNot | No | Explanation for non-billable/terminated statuses, or null when valid_billable. | |
| billable | No | True only when status is valid_billable. | |
| alsoInSystems | No | Other bundled systems holding this same code string, present only when there is at least one. The verdict above is for the system this code resolved in; the code is a DIFFERENT code in each system listed here, with its own billability — "B00" is the ICD-10-CM category "Herpesviral [herpes simplex] infections" and also the ICD-10-PCS table row "Imaging, Central Nervous System, Plain Radiography". Re-call with `system` set to one of these values to validate it there. |