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

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

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

## Bounces

Path: `sendgrid.db.bounces.search`

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

### Searchable filters

| Field | Type | Operators |
| - | - | - |
| `entity_id` | `string` | equals, contains, startsWith, endsWith, in |
| `created` | `number` | equals, gt, gte, lt, lte, in |
| `email` | `string` | equals, contains, startsWith, endsWith, in |
| `reason` | `string` | equals, contains, startsWith, endsWith, in |
| `status` | `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).*

***

## Contacts

Path: `sendgrid.db.contacts.search`

```ts theme={null}
const rows = await corsair.sendgrid.db.contacts.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 |
| `email` | `string` | equals, contains, startsWith, endsWith, in |
| `phone_number_id` | `string` | equals, contains, startsWith, endsWith, in |
| `external_id` | `string` | equals, contains, startsWith, endsWith, in |
| `anonymous_id` | `string` | equals, contains, startsWith, endsWith, in |
| `first_name` | `string` | equals, contains, startsWith, endsWith, in |
| `last_name` | `string` | equals, contains, startsWith, endsWith, in |
| `address_line_1` | `string` | equals, contains, startsWith, endsWith, in |
| `address_line_2` | `string` | equals, contains, startsWith, endsWith, in |
| `city` | `string` | equals, contains, startsWith, endsWith, in |
| `country` | `string` | equals, contains, startsWith, endsWith, in |
| `postal_code` | `string` | equals, contains, startsWith, endsWith, in |
| `state_province_region` | `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).*

***

## Lists

Path: `sendgrid.db.lists.search`

```ts theme={null}
const rows = await corsair.sendgrid.db.lists.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 |
| `contact_count` | `number` | equals, gt, gte, lt, lte, 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).*

***

## Senders

Path: `sendgrid.db.senders.search`

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

### Searchable filters

| Field | Type | Operators |
| - | - | - |
| `entity_id` | `string` | equals, contains, startsWith, endsWith, in |
| `id` | `number` | equals, gt, gte, lt, lte, in |
| `nickname` | `string` | equals, contains, startsWith, endsWith, in |
| `from_email` | `string` | equals, contains, startsWith, endsWith, in |
| `from_name` | `string` | equals, contains, startsWith, endsWith, in |
| `reply_to` | `string` | equals, contains, startsWith, endsWith, in |
| `reply_to_name` | `string` | equals, contains, startsWith, endsWith, in |
| `address` | `string` | equals, contains, startsWith, endsWith, in |
| `address2` | `string` | equals, contains, startsWith, endsWith, in |
| `state` | `string` | equals, contains, startsWith, endsWith, in |
| `city` | `string` | equals, contains, startsWith, endsWith, in |
| `zip` | `string` | equals, contains, startsWith, endsWith, in |
| `country` | `string` | equals, contains, startsWith, endsWith, in |
| `verified` | `boolean` | equals |
| `locked` | `boolean` | equals |

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

***


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.