UNPKG

@aashari/boilerplate-mcp-server

Version:

TypeScript MCP server boilerplate with STDIO and HTTP transport support, CLI tools, and extensible architecture

38 lines (37 loc) 1.58 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.IpAddressToolArgs = exports.OutputFormat = void 0; const zod_1 = require("zod"); /** * Output format options for API responses * - toon: Token-Oriented Object Notation (default, more token-efficient for LLMs) * - json: Standard JSON format */ exports.OutputFormat = zod_1.z .enum(['toon', 'json']) .optional() .describe('Output format: "toon" (default, 30-60% fewer tokens) or "json". TOON is optimized for LLMs with tabular arrays and minimal syntax.'); /** * Zod schema for the IP address tool arguments. */ exports.IpAddressToolArgs = zod_1.z .object({ // Note: The ipAddress itself is handled as a separate optional positional argument in the tool/CLI, // not as part of the options object validated by this schema. includeExtendedData: zod_1.z .boolean() .optional() .default(false) .describe('Whether to include extended data (ASN, host, organization, etc.). Requires API token.'), useHttps: zod_1.z .boolean() .optional() .default(true) .describe('Whether to use HTTPS for the API call (recommended).'), jq: zod_1.z .string() .optional() .describe('JMESPath expression to filter/transform the response. IMPORTANT: Always use this to extract only needed fields and reduce token costs. Examples: "{ip: query, country: country}" (extract specific fields), "lat" (single field). See https://jmespath.org'), outputFormat: exports.OutputFormat, }) .strict();