BizKitHub
DocsAPI ReferenceIssue/bff/issue/statistics
getIssueAdmin BFF

/bff/issue/statistics

Returns issue counts grouped by status category, total non-spam count, spam count, and the "resolution speed" block (median active time to close + median SLA ratio over the last 90 days, per priority + aggregate). Backlog / waiting time and re-open gaps are subtracted from the wall-clock total so the number reflects team-controlled work only. Useful for dashboard widgets and overview panels.

IssuegetBffIssueStatistics

Parameters

1 query

Query parameters

· 1
projectCodestringOptional

Filter by project key.

ExamplePROJ

Response schema

1 status code documented

200Success
byCategoryobjectRequired

Issue count per status category code (e.g. { "new": 5, "progress": 3 }).

spamCountnumberRequired

Total spam issues.

totalCountnumberRequired

Total non-spam issues.

byAssigneeobject[]Required

Per-assignee issue counts across all statuses (spam excluded). Sorted by count DESC, then by last-name / first-name ASC. Used by the admin grid to render the Assignee filter with counts.

Each array item:
contactExternalIdstringRequired

16-char shop__contact.external_id of the assignee.

namestringRequired

Display name (company name, resolved full name, e-mail, or external id fallback).

countnumberRequired

Total non-spam issues assigned to this contact across all statuses.

unassignedCountnumberRequired

Total non-spam issues with no primary assignee. Used by the "Nepřiřazené" option in the Assignee filter.

resolutionSpeedobjectRequired

Rolling 90-day resolution-speed metric. Active time subtracts backlog (waiting) and re-open gaps (done → other → done). Priority-aware SLA ratio uses per-org configuration.

windowDaysnumberRequired

Rolling window used for the calculation (currently 90).

sampleSizenumberRequired

Number of closed tickets that contributed to the aggregate median.

medianActiveSecondsnumber | nullRequired
One of 2:
Variant 1
number

Aggregate median of the wall-clock time from creation to final close, minus time spent in waiting (backlog) and any done re-open gaps. Null when the sample is empty.

Variant 2
null
medianSlaRationumber | nullRequired
One of 2:
Variant 1
number

Aggregate median of active_time / sla_target(priority). Values < 1 mean the team beats its SLA on typical tickets. Null when the sample is empty. Priority-normalised so the mix of closed priorities does not skew the number.

Variant 2
null
perPriorityobject[]Required

Per-priority breakdown, ordered blocker → low, for a tooltip / drilldown.

Each array item:
priority"blocker" | "critical" | "high" | "normal" | "low"Required
sampleSizenumberRequired
medianActiveSecondsnumber | nullRequired
One of 2:
Variant 1
number
Variant 2
null
medianSlaRationumber | nullRequired
One of 2:
Variant 1
number
Variant 2
null
slaTargetSecondsnumberRequired

Per-org SLA target for this priority in seconds (from cas__organisation_configuration.issue_sla_target_seconds with platform defaults).

Response example

application/json
{
  "byCategory": {},
  "spamCount": 0,
  "totalCount": 0,
  "byAssignee": [
    {
      "contactExternalId": "example_contactExternalId",
      "name": "example_name",
      "count": 0
    }
  ],
  "unassignedCount": 0,
  "resolutionSpeed": {
    "windowDays": 0,
    "sampleSize": 0,
    "perPriority": [
      {
        "sampleSize": 0,
        "slaTargetSeconds": 0
      }
    ]
  }
}

Request example

GET /bff/issue/statistics

get
curl -X GET "https://api.bizkithub.com/bff/issue/statistics?projectCode=PROJ" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY"

Need an API key?

All BizKitHub public API endpoints require authentication via API key.

Get API Key