Executions / Webhooks API
実行履歴の取得と、Webhook トリガーによる外部システム連携を行います。
GET /executions — 実行履歴一覧
必要スコープ: executions:read
クエリパラメータ
| 名前 | 型 | 説明 |
|---|---|---|
| workflow_id | integer | 特定ワークフローに絞り込む |
| status | string | queued / running / completed / failed / cancelled |
| created_after | ISO8601 | 指定日時以降の実行のみ |
| created_before | ISO8601 | 指定日時以前の実行のみ |
| limit | integer | 取得件数(1〜100、デフォルト 20) |
| cursor | string | 次ページ取得用カーソル(レスポンスの pagination.next_cursor を指定) |
GET /executions/{id} — 実行履歴詳細
必要スコープ: executions:read
{
"id": 123,
"workflow_id": 45,
"status": "completed",
"display_name": "問い合わせ #4821",
"started_at": "2026-05-07T10:00:00+09:00",
"completed_at": "2026-05-07T10:00:42+09:00",
"duration_ms": 42381,
"consumed_ai_tokens": 124,
"is_test_mode": false,
"input_data": { "...": "トリガーで受け取ったデータ" },
"node_outputs": {
"ai_gen_1": {
"status": "success",
"output": { "...": "このノードの出力" },
"consumed_ai_tokens": 51,
"started_at": "2026-05-07T10:00:05+09:00",
"completed_at": "2026-05-07T10:00:20+09:00"
}
}
}id は整数、ノード単位の入出力は node_outputs(ノード ID をキーにしたオブジェクト)に入ります。AT 消費量は consumed_ai_tokens、終了時刻は completed_at です。実行が failed のときのみ error オブジェクト(code / message / node_id)が付与されます。
POST /webhooks/{hash} — Webhook トリガー
必要スコープ: 不要(hash で認証)
トリガーが Webhook のワークフローを外部システムから起動するための受け口です。 hash は 各ワークフロー固有のランダム文字列で、ワークフロー詳細画面またはGET /workflows/{id}/webhook-info で取得できます。
POST /api/v1/webhooks/abc123def456...
Content-Type: application/json
{
"any": "json",
"shape": "you want"
}
→ 202 Accepted
{
"success": true,
"execution_id": 6821,
"message": "Workflow execution started",
"captured": false
}受け取った JSON は丸ごとワークフローの
trigger.data に渡ります。変数選択 UI で {{trigger.data.field_name}} として参照できます。 想定スキーマと違う場合は Webhook ノード設定で「サンプル受信」して構造を学習させると安全です。実行ステータスの遷移
| ステータス | 意味 |
|---|---|
queued | キュー投入済み・実行待ち |
running | ワーカーが実行中 |
waiting_async | 外部処理待ち(Deep Research / RPA 等の長時間タスク中) |
completed | 正常終了 |
failed | エラー終了。error オブジェクトに詳細 |
cancelled | UI から手動キャンセル |
GET /executions の status フィルタで指定できる値はqueued / running / completed / failed / cancelled です。waiting_async は外部処理待ちの内部状態で、レスポンスには現れますがフィルタ値には使えません。