Skip to main content
Glama

get_health

Check the health status of the Airflow webserver, including metadatabase and scheduler status, using the MCP-Airflow-API tool for cluster monitoring.

Instructions

[Tool Role]: Get the health status of the Airflow webserver instance.

Returns: Health status information including metadatabase and scheduler status

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The primary handler function implementing the get_health tool. It dynamically selects the health check endpoint based on Airflow API version (v1 or v2) and returns the cluster health status.
    @mcp.tool() async def get_health() -> Dict[str, Any]: """[Tool Role]: Checks Airflow cluster health status.""" # Import here to avoid circular imports from ..functions import get_api_version api_version = get_api_version() if api_version == "v2": # v2 API: Use /monitor/health endpoint (Airflow 3.x) resp = await airflow_request("GET", "/monitor/health") else: # v1 API: Use /health endpoint (Airflow 2.x) resp = await airflow_request("GET", "/health") resp.raise_for_status() return resp.json()
  • v1-specific registration that configures the airflow_request function and calls register_common_tools(mcp), which applies the @mcp.tool() decorator to define/register get_health.
    # Set the global request function to v1 common_tools.airflow_request = airflow_request_v1 # Register all 56 common tools (includes management tools) common_tools.register_common_tools(mcp)
  • v2-specific registration that configures the airflow_request function and calls register_common_tools(mcp), which applies the @mcp.tool() decorator to define/register get_health.
    # Set the global request function to v2 common_tools.airflow_request = airflow_request_v2 # Register all 43 common tools common_tools.register_common_tools(mcp)
  • Main entrypoint registration for v1 tools (conditional on API version), which ultimately registers get_health via v1_tools.register_tools.
    logger.info("Loading Airflow API v1 tools (Airflow 2.x)") from mcp_airflow_api.tools import v1_tools v1_tools.register_tools(mcp_instance)
  • Main entrypoint registration for v2 tools (conditional on API version), which ultimately registers get_health via v2_tools.register_tools.
    logger.info("Loading Airflow API v2 tools (Airflow 3.0+)") from mcp_airflow_api.tools import v2_tools v2_tools.register_tools(mcp_instance)

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/call518/MCP-Airflow-API'

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