Stats
Team
Per group and per user: what each carried, how fast they answered, how often the promise
was kept, plus the highlighted AI row.
GET
/api/{tenant:minlength(2)}/v{version:apiVersion}/stats/team
- Authorisation
- Minimum role: USER
Request arguments
| Name |
Type |
Source |
| group_ids | Int32[] | Query |
| timeframe | ENUM dashboard_kpi_timeframe | |
| from | DateTime | |
| to | DateTime | |
| compare | Boolean | |
Request body example
Response
- Status
- 200 (OK)
- Type
- DTO_stats_team
- Wrapper
- DTO_response_wrap
- Other statuses
- 400 (BadRequest), 403 (Forbidden)
Response body example
DTO_stats_team
| Name | Type | ReadOnly | Description |
| groups | DTO_stats_team_group[] | | Groups |
| users | DTO_stats_team_user[] | | Users |
| ai_row | DTO_stats_team_user | | The highlighted "Deskhero AI" row: auto-replies plus the chat-bot. |
| period | DTO_stats_period | | Period |
| active_users | Int32 | | Users who sent at least one reply in the window. |
| replies_sent | DTO_stats_metric | | Outbound replies sent by people. |
| resolved_by_users | DTO_stats_metric | | Tickets resolved in the window that are assigned to a person. |
| resolved_by_ai | DTO_stats_metric | | Tickets resolved in the window that never needed a person. |
| resolved_total | Int32 | | Total resolved in the window, so the two figures above can be shown as shares. |
| sla_available | Boolean | | True when SLA columns should be rendered at all. |
DTO_stats_team_group
| Name | Type | ReadOnly | Description |
| id | Int32 | | Id |
| name | String | | Name |
| created | Int32 | | Created |
| resolved | Int32 | | Resolved |
| average_first_reply_sec | Double (nullable) | | Average first reply sec |
| first_reply_sla_pct | Double (nullable) | | First reply sla pct |
| resolution_sla_pct | Double (nullable) | | Resolution sla pct |
| auto_answered_pct | Double (nullable) | | Share of the group's tickets that were auto-answered, as a percentage. |
DTO_stats_team_user
| Name | Type | ReadOnly | Description |
| id | Int32 | | 0 on the AI row. |
| name | String | | Name |
| resolved | Int32 | | Tickets resolved in the window that are assigned to this user RIGHT NOW - Deskhero does
not record who resolved a ticket, so reassignment moves the credit. The card's footnote
says so. |
| replies_sent | Int32 | | Outbound replies the user sent in the window. |
| average_first_reply_sec | Double (nullable) | | Average first reply sec |
| first_reply_sla_pct | Double (nullable) | | First reply sla pct |
| first_reply_sla_measured | Int32 | | Measured first-reply clocks behind first_reply_sla_pct, so a thin sample is visible. |
| is_ai | Boolean | | True for the highlighted AI row. |
DTO_stats_period
| Name | Type | ReadOnly | Description |
| from | DateTime | | First day of the window, workspace-local. |
| to | DateTime | | Last day of the window, workspace-local. |
| previous_from | DateTime (nullable) | | First day of the comparison window. Null when not comparing. |
| previous_to | DateTime (nullable) | | Last day of the comparison window. Null when not comparing. |
| time_zone | String | | IANA id of the zone every bucket and boundary was cut in. |
| granularity | String | | "hour", "day" or "month" - the width of one point in every series below. |
| timeframe | ENUM dashboard_kpi_timeframe | | Which preset produced this window (CUSTOM when from/to were supplied). |
| compare | Boolean | | True when the previous-period figures are populated. |
DTO_stats_metric
| Name | Type | ReadOnly | Description |
| current | Double (nullable) | | Current |
| previous | Double (nullable) | | The same figure over the previous window. Null when not comparing, or when there is no history. |
ENUM dashboard_kpi_timeframe
| Value | Name | Description |
| 0 | UNKNOWN | UNKNOWN |
| 1 | TODAY | TODAY |
| 2 | YESTERDAY | YESTERDAY |
| 3 | THIS_WEEK | THIS_WEEK |
| 4 | LAST_4_WEEKS | LAST_4_WEEKS |
| 5 | LAST_12_WEEKS | LAST_12_WEEKS |
| 6 | ALL_TIME | ALL_TIME |
| 7 | CUSTOM | Stats only: the caller supplies from and to instead. Resolving this without dates is
an error, so the shared GetTimeFrame() extension deliberately refuses it. |
| 8 | LAST_12_MONTHS | LAST_12_MONTHS |
Generated Aug 4, 2026 18:37