get_event_log
Retrieve specific event log details by ID, including timestamp, event type, DAG ID, task ID, and run ID, for precise task monitoring in Apache Airflow clusters.
Instructions
[Tool Role]: Retrieves a specific event log entry by ID.
Args: event_log_id: The event log ID to retrieve
Returns: Single event log entry: event_log_id, when, event, dag_id, task_id, run_id, etc.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| event_log_id | Yes |
Implementation Reference
- The core handler function for the 'get_event_log' tool. It makes a GET request to the Airflow API endpoint /eventLogs/{event_log_id} using the shared airflow_request function and returns the JSON response.@mcp.tool() async def get_event_log(event_log_id: int) -> Dict[str, Any]: """[Tool Role]: Retrieves a specific event log entry.""" resp = await airflow_request("GET", f"/eventLogs/{event_log_id}") resp.raise_for_status() return resp.json()
- src/mcp_airflow_api/tools/v1_tools.py:23-23 (registration)Calls register_common_tools(mcp) which defines and registers the get_event_log tool (among others) for Airflow API v1.common_tools.register_common_tools(mcp)
- src/mcp_airflow_api/tools/v2_tools.py:24-24 (registration)Calls register_common_tools(mcp) which defines and registers the get_event_log tool (among others) for Airflow API v2.common_tools.register_common_tools(mcp)