---
title: "Count records"
description: "How many records match, for the same view, filter and search a list would use, among the rows your roles see (`meta.rowsLimited` says when that is only some)."
canonical: "https://grid82.com/docs/app-api/records/count"
updated: "2026-11-13"
---

# Count records

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

How many records match, for the same view, filter and search a list would use, among the rows your roles see (`meta.rowsLimited` says when that is only some).

> **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}.grid82.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).

Ask this rather than paging to the end when you only need the number.

Requires the `records:read` scope. Operation `records.count`. MCP tool `records_count`. CLI: `grid82 records count` (`npx grid82`).

## 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. |

**Authorizations**

- `Authorization` (bearer, in header, required)

## Response

**200**: Success

- `data` (`object`, required)
- `data.count` (`number`, required)
- `meta` (`object`, required)
- `meta.rowsLimited` (`boolean`, required): True when your roles see only some of the table's rows: this answer is about those rows, not the whole table.

```json
{
  "data": {
    "count": 123.45
  },
  "meta": {
    "rowsLimited": true
  }
}
```

**4XX**: Refused

- `error` (`object`, required)
- `error.code` (`enum<string>`, required, one of: `not_found, forbidden, unauthenticated, validation_failed, conflict, rate_limited, payment_required, not_implemented, internal`)
- `error.message` (`string`, required)
- `error.details` (`Record<string, unknown>`)

```json
{
  "error": {
    "code": "not_found",
    "message": "<string>",
    "details": {}
  }
}
```

**Example request**

```bash
curl --request GET \
  --url 'https://your-suite.grid82.app/your-app/v1/tables/<tableId>/records/count' \
  --header 'Authorization: Bearer <token>'
```
