---
title: "Count objects"
method: GET
path: "/api/v1/cdp/custom-objects/count"
tags: ["CDP Custom Objects"]
---

# Count objects

`GET /api/v1/cdp/custom-objects/count`

## Request

- Base URL: `https://www.useboom.ai`
- URL: `https://www.useboom.ai/api/v1/cdp/custom-objects/count`
- Auth: HTTP bearer

Exact count of custom objects of one type matching a filter, in ONE call — optionally broken down by the values of one attribute. Use this instead of listing rows and counting them yourself: a page of results is capped and tells you nothing about how many exist beyond it, so counting a page produces a number that looks right and is wrong. Pair it with a listing when you need both ("showing 10 of 19"). Objects missing the group_by attribute group under value: null. `total` is always the complete count, but the buckets are capped: when `groups_truncated` is true the buckets shown do NOT add up to `total` and there are more values than listed — say so rather than presenting the breakdown as the whole picture. Over MCP, a filter or group_by on an attribute the organization hid is refused with sensitive_field.

## Query parameters

- `type` string, required: The custom object type name to count.
- `filter` object: JSONB containment filter as a plain object (NOT a JSON string), e.g. {"status":"paid"}. Omit to count every object of the type.
- `group_by` string: Attribute name to break the count down by, e.g. "status". Must exist in the type catalog.

## Response `200`

Success

- object
  - `total` number, required
  - `groups` object[]
    - `value` string, nullable, required
    - `count` number, required
  - `groups_truncated` boolean

## Other responses

- `400`: Validation failed or the request cannot proceed.
- `401`: Missing, malformed, or revoked API key.
- `404`: The resource does not exist in this organization.
- `409`: Conflicts with the current state (duplicates, wrong lifecycle state).
- `422`: The request is well-formed but semantically invalid.
- `429`: Rate limit exceeded — retry after `Retry-After`.
- `500`: Internal server error.
- `503`: Transient error — retry with a narrower request.

## Changes

- **2026-11-03** `7c7a773b12ce`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/useboom/apis/boom-api/changes/api/v1/cdp/custom-objects/count/get.md)

---

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