---
title: "Query account event metrics over a date range"
method: GET
path: "/accounts/{account_id}/reports/eventMetrics"
tags: ["Report"]
---

# Query account event metrics over a date range

`GET /accounts/{account_id}/reports/eventMetrics`

Retrieve daily counts of registered account-level event metrics (e.g. auto_heal_insights) across workspaces in an account. Backed by the precomputed workspace_event_metric_daily fact table. Only accessible by company admins.

## Path parameters

- `account_id` string, required

## Query parameters

- `metric_names` string
- `start_date` string
- `end_date` string
- `workspace_ids` string

## Response `200`

Event metric series for the account over the date range

- AccountEventMetricsResult — Daily counts of registered event metrics across workspaces in an account
  - `account_id` string — The account ID
  - `start_date` string, date — Inclusive start of the date range (YYYY-MM-DD)
  - `end_date` string, date — Inclusive end of the date range (YYYY-MM-DD)
  - `series` EventMetricSeries[] — One entry per metric name, ordered by metric_name
    - `metric_name` string — Stable identifier for the metric (e.g. auto_heal_insights)
    - `buckets` EventMetricBucket[] — One bucket per calendar day in the range. Days with zero events across all in-scope workspaces are omitted (sparse encoding).
      - `date` string, date — Calendar day for this bucket (YYYY-MM-DD)
      - `count` integer — Sum of the metric across all in-scope workspaces for the day
      - `by_workspace` WorkspaceEventMetricCount[] — Per-workspace contribution to count for this day. Workspaces with zero events for the day are omitted.
        - `workspace_id` string — The workspace ID
        - `workspace_name` string — The workspace name
        - `count` integer — Count of events for this metric in this workspace on this day

## Other responses

- `400` — Invalid or missing parameter
- `401` — User not authenticated
- `403` — User not authorized (not a company admin)
- `default` — Unexpected error

---

[API](https://skmtc.net/mabl/apis/mabl-api.md) · [All operations](https://skmtc.net/mabl/apis/mabl-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/mabl/mabl-api/revisions/d0fc0114da66/schema)
