---
title: "Count records per value"
description: "How many records sit under each value of one column, for the same set a list would return."
canonical: "https://gtable.app/docs/app-api/records/groups"
updated: "2026-10-05"
---

# Count records per value

`GET https://your-suite.gtable.app/your-app/v1/tables/{tableId}/records/groups`

How many records sit under each value of one column, for the same set a list would return.

> **Note: Generic contract**
>
> Your own version of this operation, with your tables and the fields you can read, is in
> your app's document: `https://{suite}.gtable.app/{app}/v1/openapi.json`, behind your credential.
> [Why each person gets their own](/docs/start/studio-and-runtime#why-an-app-has-an-api-of-its-own).

Keys are raw stored values, ordered the way that column sorts. `fieldId` takes the field's id or exact name; a field you cannot read is refused, listing the fields you can.

Requires the `records:read` scope. Operation `records.groups`. MCP tool `records_groups`. CLI, once published: `gtable records groups`.

## Path parameters

| Name      | Type   | Required | Description |
| --------- | ------ | -------- | ----------- |
| `tableId` | string | yes      |             |

## Query parameters

| Name      | Type    | Required | Description            |
| --------- | ------- | -------- | ---------------------- |
| `viewId`  | string  | no       | Up to 64 characters.   |
| `search`  | string  | no       | Up to 200 characters.  |
| `filter`  | string  | no       | Up to 4000 characters. |
| `sorts`   | string  | no       | Up to 1000 characters. |
| `where`   | string  | no       | Up to 4000 characters. |
| `fieldId` | string  | yes      | Up to 200 characters.  |
| `limit`   | integer | no       |                        |
