toronto-opendata-mcp

sanchorelaxo/toronto-opendata-mcp

3.2

If you are the rightful owner of toronto-opendata-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 henry@mcphub.com.

The Toronto Open Data Catalogue MCP Server is a comprehensive Model Context Protocol server built with FastMCP, providing access to Toronto's open government data through CKAN API endpoints.

Toronto Open Data Catalogue MCP Server

A comprehensive Model Context Protocol (MCP) server for the Toronto Open Data Catalogue, built with FastMCP. This server provides access to the Toronto Open Data Catalogue through CKAN API endpoints, enabling AI assistants to access Toronto's open government data.

📊 Features

This MCP server provides access to the Toronto Open Data Catalogue API including:

Dataset Search and Discovery

  • Search datasets by keywords and filters
  • Get detailed dataset information and metadata
  • List datasets with customizable filtering options
  • Search by specific tags or categories

Organization and Taxonomy

  • List all organizations publishing datasets
  • Browse available tags and categories
  • Explore dataset groups and classifications

Resource Data Access

  • Access resource data through the datastore API
  • Search within resource data
  • Apply filters to resource queries

🚀 Installation

  1. Clone or download this repository
  2. Install the required dependencies:
    pip install -r requirements.txt
    
  3. Configure your MCP server settings in config.json
  4. Run the server:
    python toronto_data_mcp_server.py
    

📖 Usage

The MCP server exposes several functions that can be used to interact with the Toronto Open Data Catalogue:

  • list_datasets: List available datasets with pagination
  • search_datasets: Search for datasets by keyword
  • get_dataset: Get detailed information about a specific dataset
  • get_dataset_resources: Get resources associated with a dataset
  • get_resource_data: Get data from a specific resource
  • list_organizations: List all organizations publishing datasets
  • list_tags: List all available tags in the catalogue
  • search_by_tag: Search datasets by specific tags
  • search_resource_data: Search within a datastore resource

🔍 Filtering Capabilities

The Toronto Open Data Catalogue offers various filtering mechanisms:

  • Categories/Topics: Filter by dataset category or topic
  • Organizations: Filter by publishing organization
  • Formats: Filter by data format (CSV, JSON, etc.)
  • Tags: Filter by specific tags

The MCP server implements these filtering capabilities through dedicated functions and client-side filtering.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

🔗 Links