Count corrections by status
const url = 'https://example.com/v1/corrections/counts?scopeKind=project&scopeId=example';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://example.com/v1/corrections/counts?scopeKind=project&scopeId=example' \ --header 'Authorization: Bearer <token>'How many of a project’s corrections (or one agent’s in it) are in each status. Needs ?scopeKind=project&scopeId=<project> and read on the project. Only a project scope is taken: the list filters each row by what the caller reads, and a count can’t.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Only corrections of runs of this agent.
project, the only scope a count is taken in.
The project whose corrections are counted.
Responses
Section titled “Responses”Counts by status.
How many of a project’s (or an agent’s) live corrections are in each status.
object
Examplegenerated
{ "open": 1, "beingFixed": 1, "withOwner": 1, "fixed": 1, "wontFix": 1, "removed": 1}Malformed query parameter, or no project scope.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}Missing / malformed / expired / revoked bearer token.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}The database was too busy to answer in time (database-busy); Retry-After (whole seconds) says when to try again.
object
object
Stable machine-readable discriminant. Values match domain error codes (see docs/API-ROUTE-CONVENTIONS.md §4.3).
Optional, kind-specific.
object
Server-assigned request id; also echoed via X-Request-Id header.
Examplegenerated
{ "error": { "code": "example", "message": "example", "details": {}, "requestId": "example" }}