Workflow stats request

Request of live workflow resource stats

Endpoint

GET /api/workflow/stats/

Auth

Authorization: Bearer ${token}

Query Parameters

KeyDefault
identity
step0

step narrows the response to a single 1-based step; all running steps are returned when it is 0.

Response

Streamed — the latest snapshot is pushed on connect, then a fresh one every 2s until the client disconnects. Each entity carries time and per-step points keyed step-{index}.

Json
[
    {
        "kind": "status",
        "payload": {
            "code": 0,
            "message": ""
        }
    },
    {
        "kind": "entity",
        "payload": {
            "points": {
                "step-1": {
                    "cpu_total": 0,
                    "cpu_used": 0,
                    "memory_total": 0,
                    "memory_used": 0
                }
            },
            "time": ""
        }
    }
]

Fields

  • cpu_used / cpu_total — hundredths of a core (100 = one core); total is the step's resources.cpu limit, or the host core count when unset.
  • memory_used / memory_total — MB; total is the step's resources.memory limit, or host total memory when unset.

Notes

  • Workflow Permission Required
  • Always streamed; only started workflows are sampled, and usage is held in memory (never persisted)