---
title: "Get error distribution by tool"
method: POST
path: "/dashboard/api/tool-error-distribution"
tags: ["Dashboard"]
---

# Get error distribution by tool

`POST /dashboard/api/tool-error-distribution`

## Request

- Base URL: `https://api.agnost.ai`
- URL: `https://api.agnost.ai/dashboard/api/tool-error-distribution`
- Auth: one of:
  - HTTP bearer and API key in header `x-org-id`
  - API key in header `x-api-key`

## Request body

- QueryFilters
  - `time_range` '1min' | '1h' | '1d' | '1w' | '1m' | 'all'
  - `connection_type` union
    - string
    - string[]
  - `agent_name` union
    - string
    - string[]
  - `metadata_filters` object[]
    - `key` string
    - `value` string
  - `page` integer
  - `page_size` integer

## Response `200`

Error distribution for the newest 1,000 critical error events matching the tool

- object
  - `error_messages` object[], nullable, required
    - `message` string, required
    - `count` integer, required
  - `total_errors_in_range` integer, required: Number of errors represented by this newest-error sample
  - `sample_size` integer, required
  - `is_truncated` boolean, required: True when additional matching errors exist beyond the returned sample

## Changes

- **2026-11-03** `a61431b48f36`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/agnost/apis/agnost-ai-api/changes/dashboard/api/tool-error-distribution/post.md)

---

[API](https://skmtc.dev/agnost/apis/agnost-ai-api.md) - [All operations](https://skmtc.dev/agnost/apis/agnost-ai-api/llms.txt) - [OpenAPI document](https://skmtc.dev/agnost/apis/agnost-ai-api/revisions/a61431b48f36?raw)
