get_inks_by_maker
Retrieve fountain pen inks from a specific manufacturer to explore available colors and properties for selection.
Instructions
List all inks from a specific manufacturer
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| maker | Yes | Manufacturer name (e.g., "sailor", "diamine") | |
| max_results | No | Maximum number of results to return (default: 50) |
Implementation Reference
- src/index.ts:439-470 (handler)The main handler function that executes the tool logic: filters ink search data by maker name (case-insensitive), retrieves corresponding color data, creates search results, and returns formatted JSON response.private getInksByMaker(maker: string, maxResults: number): MCPTextResponse { const makerLower = maker.toLowerCase(); const makerInks = this.inkSearchData .filter((item) => item.maker.toLowerCase() === makerLower) .slice(0, maxResults); const results: SearchResult[] = []; for (const metadata of makerInks) { const inkColor = this.inkColors.find((ink) => ink.ink_id === metadata.ink_id); if (inkColor) { results.push(createSearchResult(inkColor, metadata)); } } return { content: [ { type: 'text', text: JSON.stringify( { maker, results_count: results.length, results, }, null, 2, ), }, ], } satisfies MCPTextResponse; }
- src/index.ts:192-210 (registration)Tool registration in ListToolsRequest handler, defining the tool name, description, and input schema (maker: string required, max_results: number optional default 50).{ name: 'get_inks_by_maker', description: 'List all inks from a specific manufacturer', inputSchema: { type: 'object', properties: { maker: { type: 'string', description: 'Manufacturer name (e.g., "sailor", "diamine")', }, max_results: { type: 'number', description: 'Maximum number of results to return (default: 50)', default: 50, }, }, required: ['maker'], }, },
- src/index.ts:286-290 (handler)Dispatcher case in CallToolRequest handler that routes the tool call to the getInksByMaker implementation with argument parsing.case 'get_inks_by_maker': return this.getInksByMaker( args.maker as string, (args.max_results as number) || 50, );