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

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

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

> [!NOTE]
>
> **New to Corsair?** See [database operations](https://docs.corsair.dev/concepts/database.md), [data synchronization](https://docs.corsair.dev/concepts/integrations.md), and [multi-tenancy](https://docs.corsair.dev/concepts/multi-tenancy.md).

## Actor

Path: `turbotpipes.db.actor.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.actor.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 |
| `handle` | `string` | equals, contains, startsWith, endsWith, in |
| `display_name` | `string` | equals, contains, startsWith, endsWith, in |
| `email` | `string` | equals, contains, startsWith, endsWith, in |
| `type` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## Connection

Path: `turbotpipes.db.connection.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.connection.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 |
| `handle` | `string` | equals, contains, startsWith, endsWith, in |
| `plugin` | `string` | equals, contains, startsWith, endsWith, in |
| `state` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## Datatank

Path: `turbotpipes.db.datatank.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.datatank.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 |
| `handle` | `string` | equals, contains, startsWith, endsWith, in |
| `title` | `string` | equals, contains, startsWith, endsWith, in |
| `state` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## Org

Path: `turbotpipes.db.org.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.org.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 |
| `handle` | `string` | equals, contains, startsWith, endsWith, in |
| `display_name` | `string` | equals, contains, startsWith, endsWith, in |
| `avatar_url` | `string` | equals, contains, startsWith, endsWith, in |
| `role` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## Process

Path: `turbotpipes.db.process.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.process.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 |
| `state` | `string` | equals, contains, startsWith, endsWith, in |
| `type` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## Query

Path: `turbotpipes.db.query.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.query.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 |
| `sql` | `string` | equals, contains, startsWith, endsWith, in |
| `state` | `string` | equals, contains, startsWith, endsWith, in |
| `rows_returned` | `number` | equals, gt, gte, lt, lte, in |
| `execution_time_ms` | `number` | equals, gt, gte, lt, lte, in |
| `created_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## User

Path: `turbotpipes.db.user.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.user.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 |
| `handle` | `string` | equals, contains, startsWith, endsWith, in |
| `display_name` | `string` | equals, contains, startsWith, endsWith, in |
| `email` | `string` | equals, contains, startsWith, endsWith, in |
| `avatar_url` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***

## Workspace

Path: `turbotpipes.db.workspace.search`

```ts theme={null}
const rows = await corsair.turbotpipes.db.workspace.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 |
| `handle` | `string` | equals, contains, startsWith, endsWith, in |
| `title` | `string` | equals, contains, startsWith, endsWith, in |
| `state` | `string` | equals, contains, startsWith, endsWith, in |
| `instance_type` | `string` | equals, contains, startsWith, endsWith, in |
| `created_at` | `string` | equals, contains, startsWith, endsWith, in |
| `updated_at` | `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](https://docs.corsair.dev/concepts/database.md).*

***


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