> ## Documentation Index
> Fetch the complete documentation index at: https://docs.corsair.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Database

> Formbricks local sync: searchable entities, `.search()` filters, and operators.

The Formbricks plugin syncs data locally. Use `corsair.formbricks.db.<entity>.search({ data, limit?, offset? })` with the filters listed per entity.

<Info>
  **New to Corsair?** See [database operations](/concepts/database), [data synchronization](/concepts/integrations), and [multi-tenancy](/concepts/multi-tenancy).
</Info>

## Action Classes

Path: `formbricks.db.actionClasses.search`

```ts theme={null}
const rows = await corsair.formbricks.db.actionClasses.search({
    data: { /* filters below */ },
    limit: 100,
    offset: 0,
});
```

### Searchable filters

| Field         | Type     | Operators                                  |
| ------------- | -------- | ------------------------------------------ |
| `entity_id`   | `string` | equals, contains, startsWith, endsWith, in |
| `id`          | `string` | equals, contains, startsWith, endsWith, in |
| `name`        | `string` | equals, contains, startsWith, endsWith, in |
| `description` | `string` | equals, contains, startsWith, endsWith, in |
| `type`        | `string` | equals, contains, startsWith, endsWith, in |
| `key`         | `string` | equals, contains, startsWith, endsWith, in |
| `workspaceId` | `string` | equals, contains, startsWith, endsWith, in |
| `createdAt`   | `string` | equals, contains, startsWith, endsWith, in |
| `updatedAt`   | `string` | equals, contains, startsWith, endsWith, in |

*Every `.search()` also accepts `limit` and `offset` for pagination. `.list()` is available on the same path without the `.search` suffix in code — see [database operations](/concepts/database).*

***

## Contact Attribute Keys

Path: `formbricks.db.contactAttributeKeys.search`

```ts theme={null}
const rows = await corsair.formbricks.db.contactAttributeKeys.search({
    data: { /* filters below */ },
    limit: 100,
    offset: 0,
});
```

### Searchable filters

| Field         | Type      | Operators                                  |
| ------------- | --------- | ------------------------------------------ |
| `entity_id`   | `string`  | equals, contains, startsWith, endsWith, in |
| `id`          | `string`  | equals, contains, startsWith, endsWith, in |
| `key`         | `string`  | equals, contains, startsWith, endsWith, in |
| `name`        | `string`  | equals, contains, startsWith, endsWith, in |
| `description` | `string`  | equals, contains, startsWith, endsWith, in |
| `type`        | `string`  | equals, contains, startsWith, endsWith, in |
| `dataType`    | `string`  | equals, contains, startsWith, endsWith, in |
| `isUnique`    | `boolean` | equals                                     |
| `workspaceId` | `string`  | equals, contains, startsWith, endsWith, in |
| `createdAt`   | `string`  | equals, contains, startsWith, endsWith, in |
| `updatedAt`   | `string`  | equals, contains, startsWith, endsWith, in |

*Every `.search()` also accepts `limit` and `offset` for pagination. `.list()` is available on the same path without the `.search` suffix in code — see [database operations](/concepts/database).*

***

## Surveys

Path: `formbricks.db.surveys.search`

```ts theme={null}
const rows = await corsair.formbricks.db.surveys.search({
    data: { /* filters below */ },
    limit: 100,
    offset: 0,
});
```

### Searchable filters

| Field                             | Type      | Operators                                  |
| --------------------------------- | --------- | ------------------------------------------ |
| `entity_id`                       | `string`  | equals, contains, startsWith, endsWith, in |
| `id`                              | `string`  | equals, contains, startsWith, endsWith, in |
| `name`                            | `string`  | equals, contains, startsWith, endsWith, in |
| `type`                            | `string`  | equals, contains, startsWith, endsWith, in |
| `status`                          | `string`  | equals, contains, startsWith, endsWith, in |
| `workspaceId`                     | `string`  | equals, contains, startsWith, endsWith, in |
| `createdBy`                       | `string`  | equals, contains, startsWith, endsWith, in |
| `slug`                            | `string`  | equals, contains, startsWith, endsWith, in |
| `createdAt`                       | `string`  | equals, contains, startsWith, endsWith, in |
| `updatedAt`                       | `string`  | equals, contains, startsWith, endsWith, in |
| `publishOn`                       | `string`  | equals, contains, startsWith, endsWith, in |
| `closeOn`                         | `string`  | equals, contains, startsWith, endsWith, in |
| `archivedAt`                      | `string`  | equals, contains, startsWith, endsWith, in |
| `displayOption`                   | `string`  | equals, contains, startsWith, endsWith, in |
| `recontactDays`                   | `number`  | equals, gt, gte, lt, lte, in               |
| `displayLimit`                    | `number`  | equals, gt, gte, lt, lte, in               |
| `displayPercentage`               | `number`  | equals, gt, gte, lt, lte, in               |
| `autoClose`                       | `number`  | equals, gt, gte, lt, lte, in               |
| `delay`                           | `number`  | equals, gt, gte, lt, lte, in               |
| `autoComplete`                    | `number`  | equals, gt, gte, lt, lte, in               |
| `isVerifyEmailEnabled`            | `boolean` | equals                                     |
| `isSingleResponsePerEmailEnabled` | `boolean` | equals                                     |
| `isBackButtonHidden`              | `boolean` | equals                                     |
| `isAutoProgressingEnabled`        | `boolean` | equals                                     |
| `isCaptureIpEnabled`              | `boolean` | equals                                     |
| `showLanguageSwitch`              | `boolean` | equals                                     |
| `redirectUrl`                     | `string`  | equals, contains, startsWith, endsWith, in |
| `pin`                             | `string`  | equals, contains, startsWith, endsWith, in |
| `customHeadScripts`               | `string`  | equals, contains, startsWith, endsWith, in |
| `customHeadScriptsMode`           | `string`  | equals, contains, startsWith, endsWith, in |

*Every `.search()` also accepts `limit` and `offset` for pagination. `.list()` is available on the same path without the `.search` suffix in code — see [database operations](/concepts/database).*

***

## Teams

Path: `formbricks.db.teams.search`

```ts theme={null}
const rows = await corsair.formbricks.db.teams.search({
    data: { /* filters below */ },
    limit: 100,
    offset: 0,
});
```

### Searchable filters

| Field            | Type     | Operators                                  |
| ---------------- | -------- | ------------------------------------------ |
| `entity_id`      | `string` | equals, contains, startsWith, endsWith, in |
| `id`             | `string` | equals, contains, startsWith, endsWith, in |
| `name`           | `string` | equals, contains, startsWith, endsWith, in |
| `organizationId` | `string` | equals, contains, startsWith, endsWith, in |
| `createdAt`      | `string` | equals, contains, startsWith, endsWith, in |
| `updatedAt`      | `string` | equals, contains, startsWith, endsWith, in |

*Every `.search()` also accepts `limit` and `offset` for pagination. `.list()` is available on the same path without the `.search` suffix in code — see [database operations](/concepts/database).*

***

## Webhooks

Path: `formbricks.db.webhooks.search`

```ts theme={null}
const rows = await corsair.formbricks.db.webhooks.search({
    data: { /* filters below */ },
    limit: 100,
    offset: 0,
});
```

### Searchable filters

| Field         | Type     | Operators                                  |
| ------------- | -------- | ------------------------------------------ |
| `entity_id`   | `string` | equals, contains, startsWith, endsWith, in |
| `id`          | `string` | equals, contains, startsWith, endsWith, in |
| `name`        | `string` | equals, contains, startsWith, endsWith, in |
| `url`         | `string` | equals, contains, startsWith, endsWith, in |
| `source`      | `string` | equals, contains, startsWith, endsWith, in |
| `workspaceId` | `string` | equals, contains, startsWith, endsWith, in |
| `secret`      | `string` | equals, contains, startsWith, endsWith, in |
| `createdAt`   | `string` | equals, contains, startsWith, endsWith, in |
| `updatedAt`   | `string` | equals, contains, startsWith, endsWith, in |

*Every `.search()` also accepts `limit` and `offset` for pagination. `.list()` is available on the same path without the `.search` suffix in code — see [database operations](/concepts/database).*

***
