---
title: "Count delivery rates per bucket"
method: GET
path: "/delivery-rates/counts"
tags: ["Delivery Rates"]
---

# Count delivery rates per bucket

`GET /delivery-rates/counts`

## Request

- Base URL: `https://api.equipmentshare.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.equipmentshare.com/delivery-rates/counts`
- Auth: HTTP bearer

Counts of delivery rate documents grouped by count_by, with the same filters as search. Returns {name, total_count, counts: [{name, id, count}]}.

## Query parameters

- `below_default` boolean
- `stale_days` integer
- `count_by` 'scope' | 'region_id' | 'district_id' | 'branch_id', required
- `show_empty_districts_and_regions` boolean
- `scope` string[]
- `region_id` integer[]
- `show_non_public_rsp` boolean
- `district_id` integer[]
- `show_inactive_branches` boolean
- `branch_id` integer[]
- `has_override` boolean

## Response `200`

{name, total_count, counts: [{name, id, count}]}

## Other responses

- `400`: Invalid filter parameter.
- `401`: Unauthorized - an ES admin Bearer token is required.
- `403`: The delivery rates feature flag is off for this user.
- `422`: Missing or invalid count_by.

## Changes

- **2026-11-06** `5f4e7060b56a`: 2 info
  - added the new optional `query` request parameter `show_empty_districts_and_regions`
  - added the new optional `query` request parameter `show_inactive_branches`
- **2026-10-21** `c431bb5a8be6`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/equipmentshare/apis/es-api/changes/delivery-rates/counts/get.md)

---

[API](https://skmtc.dev/equipmentshare/apis/es-api.md) - [All operations](https://skmtc.dev/equipmentshare/apis/es-api/llms.txt) - [OpenAPI document](https://skmtc.dev/equipmentshare/apis/es-api/revisions/40651e1558ac?raw)
