Failure clusters API
List and read the failure clusters Qualflare groups from your uploaded results over the REST API, with severity and status filters and sample failures.
Last updated
The Failure clusters API lets you list and read the failure clusters of a Qualflare project over REST at https://api.qualflare.com/api/v1/clusters, authenticated with a project access token.
| Base path | /api/v1/clusters and /api/v1/cluster/{clusterId}. A cluster is addressed by its id, not a seq |
| Reads | Any token. Token creator: Viewer+ · project (requires the Viewer role or higher in the project). The API has no cluster writes |
| Pages | limit 1 to 100 clusters per page, 10 by default, as items and paging |
| Limits | Rate limits and request sizes |
| Errors | Errors and status codes |
| CLI | qf <identifier> clusters list, qf <identifier> cluster get <id> (Clusters commands) |
| MCP | list_failure_clusters, get_failure_cluster (MCP server reference) |
| Plans | Which plans create clusters: Failure Clusters |
The two endpoints, each with its own section below:
| Endpoint | What it does |
|---|---|
GET /api/v1/clusters | List failure clusters |
GET /api/v1/cluster/{clusterId} | Get a failure cluster |
List failure clusters
List failure clusters returns one page of the project's failure clusters, most failures first by default.
GET /api/v1/clusters
Needs a project access token whose creator has the Viewer role or higher in the project.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
limit | query, integer | 10 | No | Clusters per page, 1 to 100 |
page | query, integer | 1 | No | Page number, 1 to 1,000 |
severity[] | query, string | No | low, medium, high or critical. Repeat it for more, up to 10 | |
status[] | query, string | No | pending or analysed. Repeat it for both | |
q | query, string | No | Text to look for in cluster labels, up to 255 characters | |
sortBy | query, string | failureCount | No | failureCount, firstSeenAt, lastSeenAt, severity or label |
sortDir | query, boolean | true | No | false sorts in ascending order |
curl -sS -g "https://api.qualflare.com/api/v1/clusters?severity[]=high" \
-H "Authorization: Bearer $QF_TOKEN"Returns 200: A page of clusters: items and paging, most failures first by default.
- Filter by
severity[],status[](pendingoranalysed) andq, a search in the label. The bracketed names can repeat, and the curl example passes-gso curl sends the brackets as they are.
Get a failure cluster
Get a failure cluster returns one cluster by its id and adds up to 10 of the cluster's failures in sampleFailures.
GET /api/v1/cluster/{clusterId}
Needs a project access token whose creator has the Viewer role or higher in the project.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
clusterId | path, integer | Yes | The cluster id |
curl -sS "https://api.qualflare.com/api/v1/cluster/15" \
-H "Authorization: Bearer $QF_TOKEN"Returns 200: The cluster, with up to 10 of its failures in sampleFailures.
{
"id": 15,
"label": "Refund requests time out in the payment service",
"summary": "Refund tests fail after 30 seconds waiting for the payment service to answer.",
"failureCount": 38,
"severity": "critical",
"status": "analysed",
"firstSeenAt": "2026-10-19T07:55:10Z",
"lastSeenAt": "2026-10-28T09:12:33Z",
"rootCause": "The refund call waits on a lock the nightly settlement job holds.",
"fixSuggestion": "Run the settlement job outside test hours, or give refunds their own lock.",
"createdAt": "2026-10-19T08:01:47Z",
"updatedAt": "2026-10-28T09:20:15Z",
"sampleFailures": [
{
"caseRunId": 90412,
"caseName": "Refund a paid order",
"suiteName": "Payments",
"errorText": "TimeoutError: waiting for /refunds to answer exceeded 30000 ms",
"similarity": 0.94,
"launchSeq": 88,
"caseRunSeq": 1204,
"suiteRunSeq": 310
}
]
}- An
idthat isn't a cluster of the project answers404withcluster not found.
Cluster fields
Every cluster the Failure clusters API returns has these fields:
| Field | Type | Notes |
|---|---|---|
id | integer | The cluster id, which Get a failure cluster takes |
label | string | The cluster's name |
summary | string | A short description of the cluster |
failureCount | integer | The failures in the cluster |
severity | string | low, medium, high or critical |
status | string | pending until the AI analysis has run, then analysed |
firstSeenAt, lastSeenAt | string | When its first and its latest failure were seen |
rootCause, fixSuggestion | string | The analysis's root cause and suggested fix, or null |
createdAt, updatedAt | string | RFC 3339 timestamps |
sampleFailures | array | On get only: up to 10 failures, with the fields below. Left out of list items |
Sample failure fields
Each item of sampleFailures is one failed case result:
| Field | Type | Notes |
|---|---|---|
caseRunId | integer | The case result's ID |
caseName, suiteName | string | The test case and its suite |
errorText | string | The error the test reported |
similarity | number | How close the failure is to the cluster |
launchSeq | integer | The launch number |
caseRunSeq, suiteRunSeq | integer | The numbers of the case result and of its suite run |
CLI and MCP equivalents
The qf CLI and the MCP server run the same reads, so they return the same JSON:
| REST | qf command and MCP tool |
|---|---|
GET /api/v1/clusters | qf <identifier> clusters list; list_failure_clusters |
GET /api/v1/cluster/{clusterId} | qf <identifier> cluster get <id>; get_failure_cluster |
Related
- Guides: Failure Clusters
- Reference: Defects API
- CLI/API: Qualflare API
Milestones API
List and read the milestones of a Qualflare project over the REST API, with their result counts, a completion filter, sorting and every field.
Public reports and badges
Embed the badge, banner and social images of a published Qualflare report, and read its launches as JSON with no token: every URL, state and cache time.