Search ICD-11 Codes
search_icd11_codesFind ICD-11 diagnosis codes by searching descriptions with keywords. Returns matching codes with descriptions and Foundation URIs for medical coding.
Instructions
Search the ICD-11 code directory by description text. Returns matching codes with descriptions and Foundation URIs. Useful for finding specific ICD-11 diagnosis codes by keyword.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Search query to match against ICD-11 code descriptions | |
| limit | No | Maximum results (1-100, default: 10) |
Implementation Reference
- src/tools.ts:142-176 (registration)The search_icd11_codes tool is registered in this block within registerTools. It validates the input (query and limit) and calls the client.icd11.search method, formatting the result using formatICD11SearchResponse.
server.registerTool( "search_icd11_codes", { title: "Search ICD-11 Codes", description: "Search the ICD-11 code directory by description text. " + "Returns matching codes with descriptions and Foundation URIs. " + "Useful for finding specific ICD-11 diagnosis codes by keyword.", inputSchema: { query: z.string().min(1).describe("Search query to match against ICD-11 code descriptions"), limit: z .number() .int() .min(1) .max(100) .default(10) .describe("Maximum results (1-100, default: 10)"), }, annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, }, }, async (args) => { try { const result = await client.icd11.search(args.query, { limit: args.limit, }); return ok(formatICD11SearchResponse(result)); } catch (error) { return fail(error); } } );