Skip to main content
Glama
reuvenaor

Israel Statistics MCP

by reuvenaor

get_chapter_topics

Retrieve specific economic data topics from Israel's Central Bureau of Statistics by selecting a chapter category like Consumer Price Index or Housing Market Index.

Instructions

Get topics for a specific chapter from Israel Statistics API

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
chapterIdYesIndex category filter. Options: a=Consumer Price Index (groceries, retail) | aa=Housing Market Index | b=Producer Price Index Industrial | ba=Producer Price Index Exports | bb=Producer Price Index Services | c=Residential Building Input | ca=Commercial Building Input | d=Road Construction Input | e=Agriculture Input | f=Bus Input | fa=Public Minibus Input. Leave empty for all.
langNoLanguage for response. Options: he=Hebrew (default) | en=English. Use 'en' for English responses.
pageNoPage number for pagination. Start with 1 for first page. Use with pagesize to navigate large result sets.
pagesizeNoNumber of results per page (maximum 1000). Controls how many items to return. Use with page for pagination.
explanationNoAdditional explanation or context for the request

Implementation Reference

  • The main handler function that executes the tool logic: extracts params, fetches chapter topics via secureFetch from 'index/catalog/chapter' endpoint, adds housing warnings to summary, and returns topics array with summary.
    export async function getChapterTopics(
      args: z.infer<typeof getChapterTopicsSchema>
    ) {
      // Extract global parameters
      const globalParams: GlobalParams = {
        lang: args.lang,
        page: args.page,
        pagesize: args.pagesize,
      }
    
      const data = await secureFetch(
        "index/catalog/chapter",
        { id: args.chapterId, format: "json", download: "false" },
        chapterTopicsResponseSchema,
        globalParams
      )
    
      // Check for housing-related warnings
      const housingWarning = checkHousingWarnings(args.chapterId)
      const baseSummary = `Found ${data.subject.length} topics in chapter ${args.chapterId}.`
    
      return {
        topics: data.subject,
        summary: addHousingWarningsToSummary(baseSummary, housingWarning),
      }
    }
  • Input schema using Zod: requires chapterId (number), optional lang, page, pagesize, explanation.
    export const getChapterTopicsSchema = z.object({
      chapterId: chapterSchema,
      ...globalParamsSchema,
      explanation: z
        .string()
        .optional()
        .describe("Additional explanation or context for the request"),
    })
  • src/index.ts:126-144 (registration)
    Registers the tool named 'get_chapter_topics' with the MCP server, providing description, inputSchema from getChapterTopicsSchema, and a rate-limited wrapper that calls the handler and returns JSON stringified result as text content.
    server.registerTool(
      "get_chapter_topics",
      {
        description:
          "Get topics for a specific chapter from Israel Statistics API",
        inputSchema: getChapterTopicsSchema.shape,
      },
      withRateLimit(async (args) => {
        const result = await getChapterTopics(args)
        return {
          content: [
            {
              type: "text",
              text: JSON.stringify(result),
            },
          ],
        }
      })
    )
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure but only states the basic action. It doesn't mention whether this is a read-only operation, potential rate limits, authentication needs, error handling, or the format of returned topics (e.g., list, structured data). For a tool with 5 parameters and no output schema, this leaves significant gaps in understanding its behavior.

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 a single, efficient sentence that directly states the tool's purpose without unnecessary words. It's appropriately sized for a straightforward data retrieval tool, though its brevity contributes to gaps in other dimensions like guidelines and transparency.

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

Completeness2/5

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

Given the tool's complexity (5 parameters, no output schema, and no annotations), the description is incomplete. It doesn't explain what 'topics' are in this context, how results are structured, or handling of large datasets via pagination. Without annotations or output schema, the agent lacks critical context for effective use, especially compared to sibling tools in the same API domain.

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?

The description adds no parameter-specific information beyond what's already in the schema, which has 100% coverage with detailed descriptions for all parameters. Since the schema fully documents parameters like 'chapterId' with enum mappings and 'page' for pagination, the description meets the baseline but doesn't enhance understanding of parameter usage or interactions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Get topics') and resource ('for a specific chapter from Israel Statistics API'), making the purpose understandable. However, it doesn't differentiate this tool from sibling tools like 'get_index_topics' or 'get_catalog_chapters', which likely retrieve similar statistical data, leaving some ambiguity about when to choose this specific tool.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'get_index_topics' or 'get_catalog_chapters'. It mentions the API source but doesn't specify use cases, prerequisites, or exclusions, leaving the agent to infer usage from the tool name and parameters alone.

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/reuvenaor/israel-statistics-mcp'

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