# Parallel

Query-based retrieval with excerpts, with separate native objectives, extraction, and task APIs.

Canonical: https://searchsdk.dev/docs/providers/parallel
Markdown: https://searchsdk.dev/docs/providers/parallel.md

<a id="overview"></a>

## Normalized search

> **TypeScript reference**
> The API names, code and policy behavior in this article describe the TypeScript SDK. See [your language guide](https://searchsdk.dev/docs/sdks) for its supported surface and limits.

The normalized adapter maps one query into `search_queries` and returns search source excerpts without treating an objective or Task response as an ordinary source list. Native excerpts remain native material rather than a generated answer.

**parallel-search.ts · server**

```typescript
import { createSearch } from '@belweave/search-sdk';
import { parallel } from '@belweave/search-sdk/parallel';

const apiKey = process.env.PARALLEL_API_KEY;
if (!apiKey) throw new Error('PARALLEL_API_KEY is required');

const client = createSearch({ provider: parallel({ apiKey }) });
const response = await client.web.search({
  query: 'SQLite write concurrency',
  limit: 5,
});
console.log(response.results, response.attempts);
```

Native Search can use an objective in addition to queries. Extract, Tasks, FindAll, and monitoring have different lifecycle models. The normalized client does not silently create or poll them.

200 include or 200 exclude under SDK policy; both lists cannot be combined.

<a id="native-client"></a>

## Provider-native client

**parallel-native.ts · server**

```typescript
import { createParallelClient } from '@belweave/search-sdk/native-parallel';

const apiKey = process.env.PARALLEL_API_KEY;
if (!apiKey) throw new Error('PARALLEL_API_KEY is required');

const client = createParallelClient({ apiKey, timeoutMs: 10_000 });
const response = await client.search({ body: { search_queries: ['SQLite write concurrency'], mode: 'basic' } });
console.log(response.data, response.metadata);
```

Read provider data from `response.data` and sanitized transport details from `response.metadata`. Native TypeScript response types are not runtime schema validation. Preserve the operation's native response and source identities.

<a id="operations"></a>

## Native operation inventory

Methods available on this native client. Paths are relative to each operation's fixed base; a provider may use more than one origin. Eligible operations retry only when you opt into a client retry policy.

| Method | HTTP / relative path | Response / retry eligibility |
| --- | --- | --- |
| `search` | `POST /v1/search` | json · no automatic retry |
| `imageSearch` | `POST /v1/images/search` | json · no automatic retry |
| `extract` | `POST /v1/extract` | json · no automatic retry |
| `createTaskGroup` | `POST /v1/tasks/groups` | json · no automatic retry |
| `retrieveTaskGroup` | `GET /v1/tasks/groups/{taskgroup_id}` | json · eligible |
| `streamTaskGroupEvents` | `GET /v1/tasks/groups/{taskgroup_id}/events` | SSE stream · eligible |
| `addRunsToTaskGroup` | `POST /v1/tasks/groups/{taskgroup_id}/runs` | json · no automatic retry |
| `fetchTaskGroupRuns` | `GET /v1/tasks/groups/{taskgroup_id}/runs` | SSE stream · eligible |
| `retrieveTaskGroupRun` | `GET /v1/tasks/groups/{taskgroup_id}/runs/{run_id}` | json · eligible |
| `createTaskRun` | `POST /v1/tasks/runs` | json · no automatic retry |
| `retrieveTaskRun` | `GET /v1/tasks/runs/{run_id}` | json · eligible |
| `streamTaskRunEvents` | `GET /v1/tasks/runs/{run_id}/events` | SSE stream · eligible |
| `retrieveTaskRunInput` | `GET /v1/tasks/runs/{run_id}/input` | json · eligible |
| `retrieveTaskRunResult` | `GET /v1/tasks/runs/{run_id}/result` | json · eligible |
| `fastEntitySearch` | `POST /v1beta/findall/entity-search` | json · no automatic retry |
| `ingestFindAllRun` | `POST /v1beta/findall/ingest` | json · no automatic retry |
| `createFindAllRun` | `POST /v1beta/findall/runs` | json · no automatic retry |
| `retrieveFindAllRunStatus` | `GET /v1beta/findall/runs/{findall_id}` | json · eligible |
| `cancelFindAllRun` | `POST /v1beta/findall/runs/{findall_id}/cancel` | json · no automatic retry |
| `addEnrichmentToFindAllRun` | `POST /v1beta/findall/runs/{findall_id}/enrich` | json · no automatic retry |
| `streamFindAllEvents` | `GET /v1beta/findall/runs/{findall_id}/events` | SSE stream · eligible |
| `extendFindAllRun` | `POST /v1beta/findall/runs/{findall_id}/extend` | json · no automatic retry |
| `findAllRunResult` | `GET /v1beta/findall/runs/{findall_id}/result` | json · eligible |
| `getFindAllRunSchema` | `GET /v1beta/findall/runs/{findall_id}/schema` | json · eligible |
| `createMonitor` | `POST /v1/monitors` | json · no automatic retry |
| `listMonitors` | `GET /v1/monitors` | json · eligible |
| `monitorStats` | `GET /v1/monitors/stats` | json · eligible |
| `retrieveMonitor` | `GET /v1/monitors/{monitor_id}` | json · eligible |
| `cancelMonitor` | `POST /v1/monitors/{monitor_id}/cancel` | json · no automatic retry |
| `listMonitorEvents` | `GET /v1/monitors/{monitor_id}/events` | json · eligible |
| `triggerMonitorRun` | `POST /v1/monitors/{monitor_id}/trigger` | json · no automatic retry |
| `updateMonitor` | `POST /v1/monitors/{monitor_id}/update` | json · no automatic retry |
| `clearMemory` | `POST /v1beta/memory/clear` | json · no automatic retry |
| `evictFromMemory` | `POST /v1beta/memory/evict` | json · no automatic retry |
| `retrieveMemory` | `POST /v1beta/memory/retrieve` | json · no automatic retry |
| `chatCompletions` | `POST /v1beta/chat/completions` | json · no automatic retry |
| `chatCompletionsStream` | `POST /v1beta/chat/completions` | SSE stream · no automatic retry |
| `createResponse` | `POST /v1/responses` | json · no automatic retry |
| `createResponseStream` | `POST /v1/responses` | SSE stream · no automatic retry |

<a id="lifecycle"></a>

## Limits and operation lifecycle

- Pass `signal` and per-call `timeoutMs` on native request input when needed.
- Persist a returned job identifier before explicitly reading or polling the same job. Native clients do not automatically poll.
- SSE data is incremental provider event text. Parse and validate terminal or error events according to the provider contract; there is no reconnect or replay.
- Native operations may create, delete, ingest, or incur charges. A successful HTTP response is not proof that a remote job completed.

<a id="sources"></a>

## Official sources

Use the official reference for current schemas, account access, and operation-specific requirements.

- [Search reference](https://docs.parallel.ai/api-reference/search/search)
- [Full documentation index](https://docs.parallel.ai/llms.txt)

- [Native request and response reference](https://searchsdk.dev/docs/api/native-transport)
- [All providers](https://searchsdk.dev/docs/providers)
