Skip to main content
Glama

initialize_data

Manually trigger GTFS data initialization for the CATA Bus MCP Server to enable real-time bus tracking, arrival predictions, and route information.

Instructions

Manually trigger GTFS data initialization.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the 'initialize_data' tool. It is registered via the @mcp.tool decorator. Calls ensure_initialized() to load GTFS static and realtime data if not already done, then returns a status dictionary with loaded data counts.
    @mcp.tool async def initialize_data() -> dict[str, Any]: """Manually trigger GTFS data initialization.""" await ensure_initialized() return { "status": "initialized" if initialized else "failed", "routes_loaded": len(gtfs_data.routes) if gtfs_data else 0, "stops_loaded": len(gtfs_data.stops) if gtfs_data else 0, "message": "GTFS data has been loaded" if initialized else "Failed to load GTFS data", }

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/Pranav-Karra-3301/catabus-mcp'

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