Count Workflow Runs
Count workflow runs matching the same filters as Search Workflow Runs (workflow ID, status, user IDs, time range, linked ticket, parent run, include_child_runs, include_runs_with_linked_ticket). Use this instead of paging the full result set when only the total is needed — e.g. dashboard tiles or sizing a backfill before running it. The count walks the full filtered set, so latency scales with how many rows match; on teams with millions of runs, narrow the count with created_after/created_before (very broad counts may hit the server’s query timeout).
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Same filter set as SearchWorkflowRunsRequest, minus pagination and include_output — the two requests must stay filter-compatible so a caller can count a result set and then page exactly that set.
The ID of the team. Required.
Filter by workflow ID.
Filter by statuses (multiple allowed).
WORKFLOW_RUN_STATUS_UNSPECIFIED, WORKFLOW_RUN_STATUS_PENDING, WORKFLOW_RUN_STATUS_RUNNING, WORKFLOW_RUN_STATUS_COMPLETED, WORKFLOW_RUN_STATUS_FAILED, WORKFLOW_RUN_STATUS_DENIED, WORKFLOW_RUN_STATUS_CANCELED Filter by the target user for the workflow run.
Filter by the user who initiated the workflow run.
Filter by runs created after this timestamp (RFC3339 format).
Filter by runs created before this timestamp (RFC3339 format).
Filter by linked ticket ID.
Count only the direct child runs (sub-workflows) of this parent run.
Whether to include child runs (sub-workflows) in the count. Unset means true (matches include_output's unset-means-true convention). Set explicitly to false to count only top-level runs. include_child_runs=false is mutually exclusive with parent_workflow_run_id; combining them is a 400.
When true, count only runs that are linked to a ticket (linked_ticket_id set). Unset and explicit false are equivalent — no filter is applied.
Response
Success
The number of workflow runs matching the filters.

