Skip to main content
Glama
luizzzvictor

mcp-comexstat

by luizzzvictor

getCityDetails

Retrieve detailed information about a specific city using its unique cityId. Ideal for applications requiring precise city data integration.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cityIdYes

Implementation Reference

  • Core handler function that fetches and returns city details from the Comexstat API endpoint `/tables/cities/${cityId}`.
    async getCityDetails(cityId: string): Promise<{ data: { coMunGeo: string; // Geographic municipality code noMun: string; // Municipality name noMunMin: string; // Short municipality name sgUf: string; // State abbreviation }; success: boolean; message: string | null; processo_info: any; language: string; }> { return this.get(`/tables/cities/${cityId}`); }
  • Input schema validation using Zod for the cityId parameter.
    { cityId: z.string(), },
  • Registers the MCP tool 'getCityDetails' with input schema and a handler that delegates to ComexstatClient.getCityDetails and returns JSON response.
    "getCityDetails", { cityId: z.string(), }, async ({ cityId }) => ({ content: [ { type: "text", text: JSON.stringify(await this.client.getCityDetails(cityId)), }, ], }) );

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/luizzzvictor/mcp-comexstat'

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