Skip to main content
Glama

medical-codes-mcp-server

medcode_check_code
Read-onlyIdempotent

Validate 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

TableJSON Schema
NameRequiredDescriptionDefault
codeYesThe code to validate, with or without dots. Must not be blank or whitespace-only.
systemNoForce the lookup into this system. Omit to auto-detect from the code's shape.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeNoThe code in display form (ICD-10-CM carries the dot).
errorNoPresent when the call failed. Absent on success.
statusNoValidity status. valid_billable = submit as-is; valid_header/valid_not_billable = needs a more specific code; terminated = retired.
systemNoThe system the code was resolved in, echoed for chaining.
whyNotNoExplanation for non-billable/terminated statuses, or null when valid_billable.
billableNoTrue only when status is valid_billable.
alsoInSystemsNoOther 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.

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With readOnlyHint and idempotentHint already present, the description still adds crucial behavioral detail: non-billable/terminated codes are successful results carrying a whyNot, only codes absent from all bundled systems raise unknown_code, and alsoInSystems clarifies multi-system matches. This goes well beyond the annotations and fully discloses the tool's result semantics.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is lengthy but every sentence carries unique, non-redundant information. It is front-loaded with the core contract and proceeds to edge cases in a logical order. No sentence is wasted, and the length is justified by the tool's complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the presence of an output schema and the complexity of the tool's discriminated statuses, the description covers all essential facets: existence, currency, billability, whyNot explanations, multi-system aliases, and error semantics. An agent has everything needed to invoke it correctly and interpret the result.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3. The description adds meaningful context beyond the schema: it clarifies that 'code' can include or exclude dots, explains that 'system' is optional and used to disambiguate auto-detection, and notes the system enum values. This enriches parameter understanding without redundancy.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a precise verb+resource contract: 'Validate whether a US medical code exists, is current, and is billable in the active bundled release.' It further distinguishes itself via the discriminated statuses (valid_billable, valid_not_billable, etc.) and explicitly frames it as 'the detail a coder needs before submitting a claim.' This makes the tool's role clear against siblings like search, browse, or map.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives strong context for when to use it ('before submitting a claim') and explains the auto-detection vs. forcing a system ('pass an explicit system to disambiguate'). However, it does not explicitly state when *not* to use it or name alternative tools. The distinction from siblings is implied but not spelled out, so it falls short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

TDQS

A4.7/5.0
Disambiguation5/5

Each tool serves a unique, non-overlapping function: browsing hierarchy, validating codes, decoding descriptions, listing systems, mapping between codes, and searching by clinical description. There is no ambiguity in selecting the right tool for a task.

Naming Consistency5/5

All tool names follow the 'medcode_' prefix with a clear verb_noun pattern: browse_hierarchy, check_code, get_code, list_systems, map_codes, search_codes. This is a perfectly consistent naming convention.

Tool Count5/5

With six tools, the server is well-scoped for its purpose of decoding, validating, searching, and crosswalking medical codes. Each tool covers a distinct essential capability, and the count feels appropriate for a focused domain.

Completeness5/5

The tool set covers the full read-only lifecycle: discovering codes (browse), searching (search), decoding (get), validating (check), crosswalking (map), and identifying release versions (list_systems). There are no obvious dead ends or missing operations for this domain.