---
title: "Search Records"
method: POST
path: "/databases/{databaseId}/tables/{tableId}/records/search"
tags: ["Records"]
---

# Search Records

`POST /databases/{databaseId}/tables/{tableId}/records/search`

Search for records in the specified table based on filter, sort, and pagination criteria.

## Query parameters

- `fieldNames` boolean

## Request body

- object
  - `filter` object
    - `condition` FilterCondition — A condition for filtering records. Text-related conditions are case-insensitive.
      - `operator` 'AND' | 'OR' | 'IS_EMPTY' | 'IS_NOT_EMPTY' | 'IS_BETWEEN' | 'IS_NOT_BETWEEN' | 'IS_WITHIN' | 'IS_NOT_WITHIN' | 'IS' | 'IS_NOT' | 'GREATER_THAN' | 'GREATER_THAN_OR_EQUALS' | 'LESS_THAN' | 'LESS_THAN_OR_EQUALS' | 'CONTAINS' | 'DOES_NOT_CONTAIN' | 'STARTS_WITH' | 'DOES_NOT_START_WITH' | 'ENDS_WITH' | 'DOES_NOT_END_WITH' | 'IS_ONE_OF' | 'IS_NOT_ONE_OF' | 'HAS_ANY_OF' | 'HAS_ALL_OF' | 'HAS_NONE_OF'
      - `leftSide` string — The Field ID to apply the operator on.
      - `rightSide` union — The value to compare against. Can be a string, number, or an array for operators like IS_ONE_OF.
        - string
        - number
        - boolean
        - string[]
      - `lowerBound` string — Lower bound for IS_BETWEEN operator.
      - `upperBound` string — Upper bound for IS_BETWEEN operator.
      - `conditions` FilterCondition[] — Used for AND/OR operators to nest conditions.
  - `sorting` object[]
    - `sortingField` string — The Field ID to apply the sorting on
    - `sortType` 'ASC' | 'DESC'
  - `paging` object
    - `offset` integer
    - `limit` integer

## Response `200`

A paginated list of matching records.

- object
  - `data` Record[]
    - `id` string
    - `tableId` string
    - `fields` object — A map of Field IDs to their values for this record.
    - `createdAt` string, date-time
    - `updatedAt` string, date-time
  - `metadata` RecordListMetadata
    - `offset` integer
    - `limit` integer
    - `total` integer

## Other responses

- `429` — Rate limit exceeded.

---

[API](https://skmtc.dev/softr/apis/softr-database-api.md) · [All operations](https://skmtc.dev/softr/apis/softr-database-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/softr/softr-database-api/revisions/0ce045eb468a/schema)
