Skip to main content
Glama
MCP Server for Apache Airflow

MCP Server for Apache Airflow

by yangkyeongmo

mcp-server-apache-airflow

鍛冶屋のバッジ

Apache Airflow 向けのモデルコンテキストプロトコル (MCP) サーバー実装。MCP クライアントとのシームレスな統合を可能にします。このプロジェクトは、モデルコンテキストプロトコルを介して Apache Airflow と対話するための標準化された方法を提供します。

について

このプロジェクトは、Apache AirflowのREST APIをラップするモデルコンテキストプロトコル( MCP)サーバーを実装し、MCPクライアントが標準化された方法でAirflowとやり取りできるようにします。互換性と保守性を確保するために、公式のApache Airflowクライアントライブラリを使用しています。

Related MCP server: astro-airflow-mcp

機能実装状況

特徴

APIパス

状態

DAG管理

DAGの一覧

/api/v1/dags

✅

DAGの詳細を取得する

/api/v1/dags/{dag_id}

✅

DAGを一時停止

/api/v1/dags/{dag_id}

✅

DAG の一時停止を解除

/api/v1/dags/{dag_id}

✅

DAGを更新

/api/v1/dags/{dag_id}

✅

DAGを削除

/api/v1/dags/{dag_id}

✅

DAGソースを取得

/api/v1/dagSources/{file_token}

✅

複数のDAGをパッチする

/api/v1/dags

✅

DAG ファイルの再解析

/api/v1/dagSources/{file_token}/reparse

✅

DAGラン

DAG実行の一覧

/api/v1/dags/{dag_id}/dagRuns

✅

DAG 実行の作成

/api/v1/dags/{dag_id}/dagRuns

✅

DAG 実行の詳細を取得する

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}

✅

DAG 実行の更新

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}

✅

DAG実行を削除

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}

✅

DAG実行バッチを取得

/api/v1/dags/~/dagRuns/list

✅

DAGランをクリア

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/clear

✅

DAG実行ノートの設定

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/setNote

✅

アップストリームデータセットイベントを取得する

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/upstreamDatasetEvents

✅

タスク

DAGタスクの一覧

/api/v1/dags/{dag_id}/tasks

✅

タスクの詳細を取得

/api/v1/dags/{dag_id}/tasks/{task_id}

✅

タスクインスタンスの取得

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/taskInstances/{task_id}

✅

タスクインスタンスの一覧表示

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/taskInstances

✅

タスクインスタンスの更新

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/taskInstances/{task_id}

✅

タスクインスタンスをクリア

/api/v1/dags/{dag_id}/clearTaskInstances

✅

タスクインスタンスの状態を設定する

/api/v1/dags/{dag_id}/updateTaskInstancesState

✅

変数

リスト変数

/api/v1/variables

✅

変数を作成

/api/v1/variables

✅

変数を取得

/api/v1/variables/{variable_key}

✅

変数の更新

/api/v1/variables/{variable_key}

✅

変数を削除

/api/v1/variables/{variable_key}

✅

接続

接続の一覧

/api/v1/connections

✅

接続を作成

/api/v1/connections

✅

接続を取得

/api/v1/connections/{connection_id}

✅

接続の更新

/api/v1/connections/{connection_id}

✅

接続を削除

/api/v1/connections/{connection_id}

✅

テスト接続

/api/v1/connections/test

✅

プール

リストプール

/api/v1/pools

✅

プールを作成

/api/v1/pools

✅

プールを取得

/api/v1/pools/{pool_name}

✅

アップデートプール

/api/v1/pools/{pool_name}

✅

プールを削除

/api/v1/pools/{pool_name}

✅

Xコム

XComsのリスト

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/taskInstances/{task_id}/xcomEntries

✅

XComエントリーを入手

/api/v1/dags/{dag_id}/dagRuns/{dag_run_id}/taskInstances/{task_id}/xcomEntries/{xcom_key}

✅

データセット

データセットの一覧

/api/v1/datasets

✅

データセットを取得

/api/v1/datasets/{uri}

✅

データセットイベントを取得する

/api/v1/datasetEvents

✅

データセットイベントの作成

/api/v1/datasetEvents

✅

DAG データセットのキューイベントの取得

/api/v1/dags/{dag_id}/dagRuns/queued/datasetEvents/{uri}

✅

DAG データセットのキューイベントを取得する

/api/v1/dags/{dag_id}/dagRuns/queued/datasetEvents

✅

DAG データセットのキューイベントの削除

/api/v1/dags/{dag_id}/dagRuns/queued/datasetEvents/{uri}

✅

DAG データセットのキューイベントの削除

/api/v1/dags/{dag_id}/dagRuns/queued/datasetEvents

✅

データセットのキューイベントを取得する

/api/v1/datasets/{uri}/dagRuns/queued/datasetEvents

✅

データセットのキューイベントの削除

/api/v1/datasets/{uri}/dagRuns/queued/datasetEvents

✅

監視

健康になる

/api/v1/health

✅

DAG統計

DAG統計を取得

/api/v1/dags/statistics

✅

設定

設定を取得

/api/v1/config

✅

プラグイン

プラグインを入手

/api/v1/plugins

✅

プロバイダー

リストプロバイダー

/api/v1/providers

✅

イベントログ

イベントログの一覧表示

/api/v1/eventLogs

✅

イベントログを取得

/api/v1/eventLogs/{event_log_id}

✅

システム

インポートエラーを取得する

/api/v1/importErrors

✅

インポートエラーの詳細を取得する

/api/v1/importErrors/{import_error_id}

✅

健康状態を取得する

/api/v1/health

✅

バージョンを取得

/api/v1/version

✅

設定

依存関係

このプロジェクトは、Apache Airflow公式クライアントライブラリ( apache-airflow-client )に依存しています。このパッケージをインストールすると、自動的にインストールされます。

環境変数

次の環境変数を設定します。

AIRFLOW_HOST=<your-airflow-host>
AIRFLOW_USERNAME=<your-airflow-username>
AIRFLOW_PASSWORD=<your-airflow-password>

Claude Desktopでの使用

claude_desktop_config.jsonに追加します:

{
  "mcpServers": {
    "mcp-server-apache-airflow": {
      "command": "uvx",
      "args": ["mcp-server-apache-airflow"],
      "env": {
        "AIRFLOW_HOST": "https://your-airflow-host",
        "AIRFLOW_USERNAME": "your-username",
        "AIRFLOW_PASSWORD": "your-password"
      }
    }
  }
}

uvを使用した代替構成:

{
  "mcpServers": {
    "mcp-server-apache-airflow": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/mcp-server-apache-airflow",
        "run",
        "mcp-server-apache-airflow"
      ],
      "env": {
        "AIRFLOW_HOST": "https://your-airflow-host",
        "AIRFLOW_USERNAME": "your-username",
        "AIRFLOW_PASSWORD": "your-password"
      }
    }
  }
}

/path/to/mcp-server-apache-airflowリポジトリのクローンを作成した実際のパスに置き換えます。

APIグループの選択

--apisフラグを設定することで、使用する API グループを選択できます。

uv run mcp-server-apache-airflow --apis "dag,dagrun"

デフォルトではすべての API が使用されます。

許可される値は次のとおりです。

  • 設定

  • 接続

  • ダグ

  • ダグルン

  • ダグスタッツ

  • データセット

  • イベントログ

  • インポートエラー

  • 監視

  • プラグイン

  • プール

  • プロバイダー

  • タスクインスタンス

  • 変数

  • エックスコム

手動実行

サーバーを手動で実行することもできます。

make run

make run次のオプションを受け入れます:

オプション:

  • --port : SSEをリッスンするポート(デフォルト: 8000)

  • --transport : トランスポートタイプ (stdio/sse、デフォルト: stdio)

または、同じパラメータを受け入れる sse サーバーを直接実行することもできます。

make run-sse

Smithery経由でインストール

Smithery経由で Claude Desktop 用の Apache Airflow MCP サーバーを自動的にインストールするには:

npx -y @smithery/cli install @yangkyeongmo/mcp-server-apache-airflow --client claude

貢献

貢献を歓迎します!お気軽にプルリクエストを送信してください。

ライセンス

MITライセンス

Available Tools

68 tools
clear_dag_runD

Clear a DAG run

Inputs: dag_id (required), dag_run_id (required), dry_run.

clear_task_instancesD

Clear a set of task instances

Inputs: dag_id (required), task_ids, start_date, end_date, +8 more.

create_connectionD

Create a connection

Inputs: conn_id (required), conn_type (required), host, port, +4 more.

create_dataset_eventD

Create dataset event

Inputs: dataset_uri (required), extra.

create_variableD

Create a variable

Inputs: key (required), value (required), description.

delete_connectionC

Delete a connection by ID

Inputs: conn_id (required).

delete_dagD

Delete a DAG

Inputs: dag_id (required).

delete_dag_dataset_queued_eventC

Delete a queued Dataset event for a DAG

Inputs: dag_id (required), uri (required).

delete_dag_dataset_queued_eventsC

Delete queued Dataset events for a DAG

Inputs: dag_id (required), before.

delete_dag_runC

Delete a DAG run by DAG ID and DAG run ID

Inputs: dag_id (required), dag_run_id (required).

delete_dataset_queued_eventsC

Delete queued Dataset events for a Dataset

Inputs: uri (required), before.

delete_poolD

Delete a pool

Inputs: pool_name (required).

delete_variableC

Delete a variable by key

Inputs: key (required).

fetch_dagsC

Fetch all DAGs

Inputs: limit, offset, order_by, tags, +3 more.

get_configD

Get current configuration

Inputs: section.

get_connectionC

Get a connection by ID

Inputs: conn_id (required).

get_dagC

Get a DAG by ID

Inputs: dag_id (required).

get_dag_dataset_queued_eventC

Get a queued Dataset event for a DAG

Inputs: dag_id (required), uri (required).

get_dag_dataset_queued_eventsC

Get queued Dataset events for a DAG

Inputs: dag_id (required).

get_dag_detailsC

Get a simplified representation of DAG

Inputs: dag_id (required), fields.

get_dag_runC

Get a DAG run by DAG ID and DAG run ID

Inputs: dag_id (required), dag_run_id (required).

get_dag_runsD

Get DAG runs by ID

Inputs: dag_id (required), limit, offset, execution_date_gte, +9 more.

get_dag_runs_batchD

List DAG runs (batch)

Inputs: dag_ids, execution_date_gte, execution_date_lte, start_date_gte, +7 more.

get_dag_sourceD

Get a source code

Inputs: file_token (required).

get_dag_statsD

Get DAG stats

Inputs: dag_ids.

get_dag_tasksD

Get tasks for DAG

Inputs: dag_id (required).

get_datasetC

Get a dataset by URI

Inputs: uri (required).

get_dataset_eventsD

Get dataset events

Inputs: limit, offset, order_by, dataset_id, +4 more.

get_dataset_queued_eventsC

Get queued Dataset events for a Dataset

Inputs: uri (required).

get_datasetsC

List datasets

Inputs: limit, offset, order_by, uri_pattern, +1 more.

get_event_logC

Get a specific log entry by ID

Inputs: event_log_id (required).

get_event_logsC

List log entries from event log

Inputs: limit, offset, order_by, dag_id, +10 more.

get_healthC

Get instance status

Inputs: no named parameters.

get_import_errorC

Get a specific import error by ID

Inputs: import_error_id (required).

get_import_errorsC

List import errors

Inputs: limit, offset, order_by.

get_logC

Get the log from a task instance by DAG ID, task ID, DAG run ID and task try number

Inputs: dag_id (required), task_id (required), dag_run_id (required), task_try_number (required).

get_pluginsC

Get a list of loaded plugins

Inputs: limit, offset.

get_poolC

Get a pool by name

Inputs: pool_name (required).

get_poolsD

List pools

Inputs: limit, offset, order_by.

get_providersC

Get a list of loaded providers

Inputs: limit, offset.

get_taskC

Get a task by ID

Inputs: dag_id (required), task_id (required).

get_task_instanceC

Get a task instance by DAG ID, task ID, and DAG run ID

Inputs: dag_id (required), task_id (required), dag_run_id (required).

get_tasksD

Get tasks for DAG

Inputs: dag_id (required), order_by.

get_upstream_dataset_eventsC

Get dataset events for a DAG run

Inputs: dag_id (required), dag_run_id (required).

get_valueC

Get a specific option from configuration

Inputs: section (required), option (required).

get_variableD

Get a variable by key

Inputs: key (required).

get_versionC

Get version information

Inputs: no named parameters.

get_xcom_entriesC

Get all XCom entries

Inputs: dag_id (required), dag_run_id (required), task_id (required), map_index, +3 more.

get_xcom_entryD

Get an XCom entry

Inputs: dag_id (required), dag_run_id (required), task_id (required), xcom_key (required), +3 more.

list_connectionsC

List all connections

Inputs: limit, offset, order_by.

list_task_instancesC

List task instances by DAG ID and DAG run ID

Inputs: dag_id (required), dag_run_id (required), execution_date_gte, execution_date_lte, +13 more.

list_task_instance_triesC

List task instance tries by DAG ID, DAG run ID, and task ID

Inputs: dag_id (required), dag_run_id (required), task_id (required), limit, +2 more.

list_variablesD

List all variables

Inputs: limit, offset, order_by.

patch_dagD

Update a DAG

Inputs: dag_id (required), is_paused, tags.

patch_dagsC

Update multiple DAGs

Inputs: dag_id_pattern, is_paused, tags.

patch_poolD

Update a pool

Inputs: pool_name (required), slots, description, include_deferred.

pause_dagC

Pause a DAG by ID

Inputs: dag_id (required).

post_dag_runC

Trigger a DAG by ID

Inputs: dag_id (required), dag_run_id, data_interval_end, data_interval_start, +3 more.

post_poolC

Create a pool

Inputs: name (required), slots (required), description, include_deferred.

reparse_dag_fileC

Request re-parsing of a DAG file

Inputs: file_token (required).

set_dag_run_noteC

Update the DagRun note

Inputs: dag_id (required), dag_run_id (required), note (required).

set_task_instances_stateD

Set a state of task instances

Inputs: dag_id (required), state (required), task_ids, execution_date, +5 more.

test_connectionD

Test a connection

Inputs: conn_type (required), host, port, login, +3 more.

unpause_dagC

Unpause a DAG by ID

Inputs: dag_id (required).

update_connectionC

Update a connection by ID

Inputs: conn_id (required), conn_type, host, port, +4 more.

update_dag_run_stateC

Update a DAG run state by DAG ID and DAG run ID

Inputs: dag_id (required), dag_run_id (required), state.

update_task_instanceC

Update a task instance by DAG ID, DAG run ID, and task ID

Inputs: dag_id (required), dag_run_id (required), task_id (required), state.

update_variableC

Update a variable by key

Inputs: key (required), value, description.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.5/5.0

    Scored across 68 tools

    Disambiguation4/5

    Most tools have distinct purposes targeting specific Airflow entities (DAGs, tasks, connections, variables, datasets), but there is some overlap between get_dag_details and get_dag, and between get_tasks and get_dag_tasks, which could cause minor confusion. The descriptions help differentiate, but the sheer number of tools increases cognitive load.

    Naming Consistency5/5

    Tool names follow a highly consistent verb_noun pattern throughout (e.g., get_dag, create_connection, delete_variable, update_task_instance). There are no deviations in naming conventions, making the set predictable and easy to navigate.

    Tool Count2/5

    With 68 tools, this server is overloaded for typical agent use. While Airflow is a complex system, this count far exceeds the 3-15 range for well-scoped servers, making it heavy and likely overwhelming for agents to handle efficiently.

    Completeness5/5

    The tool surface provides comprehensive CRUD/lifecycle coverage for all key Airflow domains (DAGs, tasks, connections, variables, datasets, pools, logs, XComs). There are no obvious gaps, and operations like create, get, update, delete, list, and state management are fully represented across entities.

    Maintenance

    ActivityMaintained
    ResponsivenessLimited data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      F
      maintenance
      An MCP server that enables AI assistants to interact with Apache Airflow's REST API for DAG management, task monitoring, and system diagnostics. It provides comprehensive tools for triggering workflows, retrieving logs, and inspecting system health across Airflow 2.x and 3.x versions.
      31
      13
      Apache 2.0
    • A
      license
      Not graded
      quality
      Not graded
      maintenance
      An MCP server that wraps the Apache Airflow REST API, enabling clients to manage DAGs, monitor task instances, and handle workflows through a standardized interface. It provides comprehensive access to Airflow features including DAG runs, variables, connections, and XComs.
      MIT