> ## Documentation Index
> Fetch the complete documentation index at: https://docs.playapi.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Alpha Search integration boundary

> Validate deployment-specific requests and response boundaries.

`POST /v1/alpha/search` is a specialized upstream endpoint, not a uniform provider search API or the Responses `web_search` tool. This path is restricted to specific channel types; ask your administrator to confirm channel support and configure an available upstream and model.

The gateway requires a nonempty `model`, preserves other raw JSON fields, rewrites `model` for model mapping, and may apply channel parameter overrides. The source defines no stable `query`, `results`, or citation schema. This documentation does not invent one or claim compatibility with an official public OpenAI API.

Set up the [REST runtime](/en/guides/http-runtime), then obtain a request file matching the deployed upstream version:

```bash theme={null}
export API_SEARCH_REQUEST_FILE="./search-request.json"
node examples/alpha-search.mjs
```

The file needs `model` and the upstream's search fields. The example rejects `stream: true`, makes no automatic retries, and checks only JSON object HTTP responses and common error envelopes. Its receipt does not prove semantic search success: validate results, citations, and business error codes against the provider schema. The gateway returns successful upstream bodies and Content-Type without a Chat / Responses wrapper; non-JSON responses are outside this example. This does not promise SSE, uniform usage, or free searches. See the [API reference](/en/api-reference/alpha-search).

```javascript theme={null}
import { readFile } from 'node:fs/promises';
import { requestJSON } from './http-client.mjs';

try {
  // Use a request supplied for your deployment's upstream schema, not a guessed query field.
  const raw = await readFile(process.env.API_SEARCH_REQUEST_FILE);
  if (!raw.length || raw.length > 1024 * 1024) throw new Error('Invalid request size.');
  const body = JSON.parse(raw);
  if (!body || typeof body !== 'object' || Array.isArray(body)
    || typeof body.model !== 'string' || !body.model.trim() || body.stream === true) throw new Error('Invalid request.');
  await requestJSON('/v1/alpha/search', body);
  // A JSON receipt is not proof that the upstream search succeeded semantically.
  console.log('JSON response received. Validate results against the deployed upstream schema.');
} catch {
  console.error('Search request failed or returned a non-JSON/error response. No automatic retry.');
  process.exitCode = 1;
}
```

[阅读中文版](/zh/guides/alpha-search)


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