Skip to main content
Glama

get_procedures_for_icd

Look up NHI procedure codes by Taiwan ICD-10 code and specialty, returning payment points and audit notes for accurate billing.

Instructions

Given a Taiwan ICD-10 code and specialty, return the NHI procedure codes applicable. Results include nhi_points (healthcare payment points) and audit_notes (review caveats). 1,497 procedures across 20 specialties curated by OPDSTAR (https://opdstar.com).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
icd10YesICD-10 code, e.g. 'L30.9' (chronic eczema), 'J06.9' (acute URI)
specialtyYesSpecialty ID — one of 20 supported specialties
limitNoMax results (1-20, default 10)

Implementation Reference

  • The main handler function that executes the tool logic: calls client.get('/procedures-for-icd', ...) with icd10, specialty, and optional limit parameters.
    export async function runGetProceduresForIcd(
      client: OpdstarClient,
      args: GetProceduresForIcdArgs
    ): Promise<ProceduresForIcdResult> {
      if (!args || typeof args.icd10 !== 'string' || typeof args.specialty !== 'string') {
        throw new Error('Missing required parameters: icd10 and specialty');
      }
      return (await client.get('/procedures-for-icd', {
        icd10: args.icd10.trim(),
        specialty: args.specialty.trim().toLowerCase(),
        limit: args.limit,
      })) as ProceduresForIcdResult;
    }
  • The tool definition including inputSchema (icd10 string, specialty enum, limit integer) and the GetProceduresForIcdArgs interface.
    export const GET_PROCEDURES_FOR_ICD_DEF = {
      name: 'get_procedures_for_icd',
      description:
        'Given a Taiwan ICD-10 code and specialty, return the NHI procedure codes applicable. Results include nhi_points (healthcare payment points) and audit_notes (review caveats). 1,497 procedures across 20 specialties curated by OPDSTAR (https://opdstar.com).',
      inputSchema: {
        type: 'object',
        properties: {
          icd10: {
            type: 'string',
            description: "ICD-10 code, e.g. 'L30.9' (chronic eczema), 'J06.9' (acute URI)",
          },
          specialty: {
            type: 'string',
            description: 'Specialty ID — one of 20 supported specialties',
            enum: [...SPECIALTIES],
          },
          limit: {
            type: 'integer',
            description: 'Max results (1-20, default 10)',
            minimum: 1,
            maximum: 20,
            default: 10,
          },
        },
        required: ['icd10', 'specialty'],
      },
    } as const;
  • src/index.ts:64-65 (registration)
    Registration in the switch/case dispatch that routes 'get_procedures_for_icd' to the handler.
    case 'get_procedures_for_icd':
      result = await runGetProceduresForIcd(client, args as never);
  • src/index.ts:47-53 (registration)
    Tool is listed in the ListToolsRequestSchema handler, registering GET_PROCEDURES_FOR_ICD_DEF for tool discovery.
    server.setRequestHandler(ListToolsRequestSchema, async () => ({
      tools: [
        LOOKUP_REJECTION_CODE_DEF,
        GET_PROCEDURES_FOR_ICD_DEF,
        GET_INDICATOR_DEF,
        SEARCH_NHI_WIKI_DEF,
      ],
  • The ProceduresForIcdResult interface defining the return shape (icd10, specialty, count, results array of ProcedureItem).
    export interface ProceduresForIcdResult {
      icd10: string;
      specialty: string;
      count: number;
      results: ProcedureItem[];
    }
Behavior3/5

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

With no annotations, the description carries the full burden. It discloses the return fields (procedure codes, nhi_points, audit_notes) and mentions the data is curated from OPDSTAR, adding context. However, it does not mention authentication, rate limits, or idempotency. The information is moderately helpful but not comprehensive.

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 brief and front-loaded: the first sentence immediately states the core functionality, and the second adds context on data scale and source. No unnecessary words, every sentence adds value.

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

Completeness4/5

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

Given no output schema, the description covers return types (procedure codes, nhi_points, audit_notes) and data scope (1,497 procedures, 20 specialties). It does not explain the behavior of the limit parameter or pagination, but overall it is fairly complete for a simple lookup tool.

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

Parameters3/5

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

Schema coverage is 100%, so baseline is 3. The description adds minimal detail: it specifies that icd10 is a Taiwan ICD-10 code and that specialty is one of 20 supported, but the schema already provides examples and an enum. No additional semantics beyond the schema.

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 clearly states the tool's action ('return the NHI procedure codes applicable') given inputs (Taiwan ICD-10 code and specialty). This is distinct from sibling tools like 'get_indicator' or 'lookup_rejection_code', which serve different purposes.

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 specifies the prerequisites: 'Given a Taiwan ICD-10 code and specialty'. It implies when to use this tool (when needing NHI procedure codes for a diagnosis and specialty), but does not explicitly state when not to use it or mention alternative tools. It is clear but lacks exclusion guidance.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/tatsuju/opdstar-nhi-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server