israeli-cbs-mcp

amirrosi/israeli-cbs-mcp

3.1

If you are the rightful owner of israeli-cbs-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to dayong@mcphub.com.

An MCP server providing access to statistical data from the Israeli Central Bureau of Statistics (CBS).

Tools
4
Resources
0
Prompts
0

Israeli CBS MCP Server

An Model Context Protocol (MCP) server that provides access to statistical data from the Israeli Central Bureau of Statistics (CBS).

It supports both Statistical Series (e.g., Unemployment, GDP) and Price Indices (e.g., CPI, Construction Inputs).

Data Sources & API Documentation

This server retrieves data directly from the official CBS APIs:

Features

  • Hierarchical Exploration: Navigate topics and subtopics (list_main_topics, list_subtopics).
  • Unified Search: Access both Statistical Series and Price Indices.
  • Data Retrieval: Fetch time-series data with year filtering (get_series_data).
  • Smart Caching: Builds a local index for fast lookups and offline navigation.
  • Auto-Refresh: Keeps the cache up-to-date with a background task.

Indexing Behavior

Upon startup, the server traverses the entire CBS catalog to build a comprehensive local index.

  • Duration: This process takes approximately 5 minutes.
  • Cache Size: The resulting index file is about 20MB.
  • Availability: The server is available immediately, but search/navigation tools will report "Index is building" until completion.

Installation

Using uv (Recommended)

uvx israeli-cbs-mcp

From Source

  1. Clone the repository:
    git clone https://github.com/amirrosi/israeli-cbs-mcp.git
    cd israeli-cbs-mcp
    
  2. Install dependencies:
    pip install .
    

Configuration

You can configure the server using environment variables:

VariableDescriptionDefault
CBS_CACHE_DIRDirectory to store the index cache~/.cache/cbs_mcp
CBS_CACHE_DURATION_DAYSHow long to keep the cache before full rebuild7
CBS_CACHE_REFRESH_INTERVALBackground refresh interval (seconds)86400 (24h)
CBS_API_TIMEOUTAPI timeout in seconds30.0
CBS_MAX_RETRIESNumber of API retries3

Usage with Claude Desktop

Add the following to your claude_desktop_config.json:

{
  "mcpServers": {
    "cbs": {
      "command": "uvx",
      "args": ["israeli-cbs-mcp"]
    }
  }
}

Tools

  • list_main_topics(lang="he"): List top-level categories.
  • list_subtopics(parent_id, lang="he"): List children of a category.
  • get_series_data(series_id, start_year, end_year, last): Get data points.
  • rebuild_index(lang="he"): Force a manual index rebuild.

License

MIT