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

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

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

## Categories

Path: `giphy.db.categories.search`

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

### Searchable filters

| Field         | Type     | Operators                                  |
| ------------- | -------- | ------------------------------------------ |
| `entity_id`   | `string` | equals, contains, startsWith, endsWith, in |
| `name`        | `string` | equals, contains, startsWith, endsWith, in |
| `nameEncoded` | `string` | equals, contains, startsWith, endsWith, in |
| `createdAt`   | `date`   | equals, before, after, between             |

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

***

## Gifs

Path: `giphy.db.gifs.search`

```ts theme={null}
const rows = await corsair.giphy.db.gifs.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 |
| `url`        | `string` | equals, contains, startsWith, endsWith, in |
| `slug`       | `string` | equals, contains, startsWith, endsWith, in |
| `embedUrl`   | `string` | equals, contains, startsWith, endsWith, in |
| `title`      | `string` | equals, contains, startsWith, endsWith, in |
| `rating`     | `string` | equals, contains, startsWith, endsWith, in |
| `username`   | `string` | equals, contains, startsWith, endsWith, in |
| `source`     | `string` | equals, contains, startsWith, endsWith, in |
| `importedAt` | `string` | equals, contains, startsWith, endsWith, in |
| `createdAt`  | `date`   | equals, before, after, between             |

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

***
