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

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

The Humanitix plugin syncs data locally. Use `corsair.humanitix.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>

## Events

Path: `humanitix.db.events.search`

```ts theme={null}
const rows = await corsair.humanitix.db.events.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 |
| `userId`             | `string`  | equals, contains, startsWith, endsWith, in |
| `organiserId`        | `string`  | equals, contains, startsWith, endsWith, in |
| `currency`           | `string`  | equals, contains, startsWith, endsWith, in |
| `name`               | `string`  | equals, contains, startsWith, endsWith, in |
| `description`        | `string`  | equals, contains, startsWith, endsWith, in |
| `sharingDescription` | `string`  | equals, contains, startsWith, endsWith, in |
| `slug`               | `string`  | equals, contains, startsWith, endsWith, in |
| `url`                | `string`  | equals, contains, startsWith, endsWith, in |
| `category`           | `string`  | equals, contains, startsWith, endsWith, in |
| `public`             | `boolean` | equals                                     |
| `published`          | `boolean` | equals                                     |
| `suspendSales`       | `boolean` | equals                                     |
| `markedAsSoldOut`    | `boolean` | equals                                     |
| `startDate`          | `string`  | equals, contains, startsWith, endsWith, in |
| `endDate`            | `string`  | equals, contains, startsWith, endsWith, in |
| `timezone`           | `string`  | equals, contains, startsWith, endsWith, in |
| `totalCapacity`      | `number`  | equals, gt, gte, lt, lte, in               |
| `publishedAt`        | `string`  | equals, contains, startsWith, endsWith, in |
| `location`           | `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).*

***

## Tags

Path: `humanitix.db.tags.search`

```ts theme={null}
const rows = await corsair.humanitix.db.tags.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 |
| `userId`    | `string` | equals, contains, startsWith, endsWith, in |
| `location`  | `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).*

***
