---
title: "Retrieve system-wide analytics"
method: GET
path: "/usage"
tags: ["Usage"]
---

# Retrieve system-wide analytics

`GET /usage`

Get comprehensive analytics for all user's flows including usage, toolcalls, and structural stats

## Response `200`

analytics received successful

- object
  - `data` object
    - `flows_stats_total` ModelsFlowsStats, required
      - `total_assistants_count` integer
      - `total_flows_count` integer
      - `total_subtasks_count` integer
      - `total_tasks_count` integer
    - `toolcalls_stats_by_function` ModelsFunctionToolcallsStats[]
      - `avg_duration_seconds` number
      - `function_name` string, required
      - `is_agent` boolean
      - `total_count` integer
      - `total_duration_seconds` number
    - `toolcalls_stats_total` ModelsToolcallsStats, required
      - `total_count` integer
      - `total_duration_seconds` number
    - `usage_stats_by_agent_type` ModelsAgentTypeUsageStats[]
      - `agent_type` string, required
      - `stats` ModelsUsageStats, required
        - `total_usage_cache_in` integer
        - `total_usage_cache_out` integer
        - `total_usage_cost_in` number
        - `total_usage_cost_out` number
        - `total_usage_in` integer
        - `total_usage_out` integer
    - `usage_stats_by_model` ModelsModelUsageStats[]
      - `model` string, required
      - `provider` string, required
      - `stats` ModelsUsageStats, required
        - `total_usage_cache_in` integer
        - `total_usage_cache_out` integer
        - `total_usage_cost_in` number
        - `total_usage_cost_out` number
        - `total_usage_in` integer
        - `total_usage_out` integer
    - `usage_stats_by_provider` ModelsProviderUsageStats[]
      - `provider` string, required
      - `stats` ModelsUsageStats, required
        - `total_usage_cache_in` integer
        - `total_usage_cache_out` integer
        - `total_usage_cost_in` number
        - `total_usage_cost_out` number
        - `total_usage_in` integer
        - `total_usage_out` integer
    - `usage_stats_total` ModelsUsageStats, required
      - `total_usage_cache_in` integer
      - `total_usage_cache_out` integer
      - `total_usage_cost_in` number
      - `total_usage_cost_out` number
      - `total_usage_in` integer
      - `total_usage_out` integer
  - `status` string

## Other responses

- `403` — getting analytics not permitted
- `500` — internal error on getting analytics

---

[API](https://skmtc.dev/vxcontrol/apis/pentagi-swagger-api.md) · [All operations](https://skmtc.dev/vxcontrol/apis/pentagi-swagger-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/vxcontrol/pentagi-swagger-api/revisions/7c1cbf7abaa1/schema)
