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

# Set up Parallel MCP Server

> Register Parallel's hosted Search and Task MCP servers on the TrueFoundry MCP Gateway so agents get governed web search, page fetch, and deep research.

[Parallel](https://parallel.ai) is a web research API built for agents. It publishes two hosted remote MCP servers: **Search MCP** for low-latency, LLM-ready web search and page fetch, and **Task MCP** for asynchronous deep research and bulk dataset enrichment. Both are remote endpoints, so they register on the [TrueFoundry MCP Gateway](/docs/ai-gateway/mcp/mcp-overview) as `mcp-server/remote` with no infrastructure to run on your side.

Registering them on the Gateway gives your agents one governed endpoint for web research, with inbound TrueFoundry auth, tool-level access control, tracing, and guardrails applied on every call.

| Server             | Endpoint                               | Purpose                              | Auth                                                                     |
| ------------------ | -------------------------------------- | ------------------------------------ | ------------------------------------------------------------------------ |
| Search MCP         | `https://search.parallel.ai/mcp`       | Web search and page fetch            | Anonymous (free, lower rate limits), or Bearer API key for higher limits |
| Search MCP (OAuth) | `https://search.parallel.ai/mcp-oauth` | Same tools, auth enforced            | OAuth2 or Bearer API key required - anonymous requests return `401`      |
| Task MCP           | `https://task-mcp.parallel.ai/mcp`     | Deep research and dataset enrichment | OAuth2 or Bearer API key **required**                                    |

All three use Streamable HTTP transport. API keys are created on the [Parallel platform](https://platform.parallel.ai) and passed as `Authorization: Bearer <PARALLEL_API_KEY>`.

<Tip>
  Start with the anonymous Search MCP endpoint - it needs no credentials and no Parallel account. Add an API key or OAuth later when you hit rate limits or need per-user attribution on Parallel's side.
</Tip>

## Using Parallel through the MCP Gateway

When you use Parallel's MCP servers through the AI Gateway, TrueFoundry provides:

* **Authentication** - Clients [authenticate inbound](/docs/ai-gateway/mcp/mcp-gateway-auth-security#inbound-authentication) to the AI Gateway with a Personal Access Token, Virtual Account, or IDE OAuth flow. For [outbound access](/docs/ai-gateway/mcp/mcp-gateway-auth-security#outbound-authentication), the Gateway either sends nothing (anonymous Search MCP), injects a shared or per-user Parallel API key as a header, or runs the OAuth2 Authorization Code flow against Parallel.
* **Tool-level access control** - Enable or disable individual tools from the server detail page, so agents only see the subset you want them calling.
* **Access control** - [Collaborators and role-based policies](/docs/ai-gateway/mcp/mcp-gateway-auth-security#access-control) define who can use the server and which tools they can invoke.
* **Observability** - Tool calls are traced with caller identity, tool name, inputs, and latency. Monitor server- and tool-level usage in [MCP Metrics](/docs/ai-gateway/analytics-mcp-metrics) and export traces to your observability stack via OpenTelemetry.
* **Guardrails** - Apply [pre-tool and post-tool guardrails](/docs/ai-gateway/guardrails-overview) on MCP tool calls. This matters for web research: pre-tool checks can block sensitive queries from leaving your environment, and post-tool checks scan fetched page content before it reaches the model.

## Prerequisites

* A TrueFoundry account with permission to add MCP servers.
* A [Parallel API key](https://platform.parallel.ai) - **optional** for the anonymous Search MCP endpoint, **required** for Task MCP.

## Adding Parallel Search MCP to TrueFoundry

This is the fastest path: an anonymous server with no credentials to manage.

<Steps>
  <Step title="Open the Add MCP Server picker">
    Navigate to **MCP Servers** in the TrueFoundry sidebar and click **Add new MCP Server**. On the next screen, select **Connect Official Remote MCP Servers** - this lists official, vetted remote MCP servers that you connect with your own auth.
  </Step>

  <Step title="Select parallel-search">
    Find the **parallel-search** card in the catalog (described as "Low-latency, LLM-ready web search from Parallel") and click **+ Add**. The catalog is long, so use the search box at the top right.

    <Frame>
      <img src="https://mintcdn.com/truefoundry/8zR2kTsMwrOiDq_l/images/docs/ai-gateway/parallel-catalog-add.jpg?fit=max&auto=format&n=8zR2kTsMwrOiDq_l&q=85&s=fde09772d4603aca5ee8db8e519426a6" alt="Add new MCP Server catalog with the parallel-search card highlighted, described as Low-latency, LLM-ready web search from Parallel" width="1278" height="1402" data-path="images/docs/ai-gateway/parallel-catalog-add.jpg" />
    </Frame>
  </Step>

  <Step title="Confirm the server details">
    TrueFoundry pre-fills the server details for Parallel:

    | Field           | Value                                           |
    | --------------- | ----------------------------------------------- |
    | **Name**        | `parallel-search`                               |
    | **Description** | Low-latency, LLM-ready web search from Parallel |
    | **URL**         | `https://search.parallel.ai/mcp`                |

    Leave **Auth Data** toggled off - the endpoint accepts anonymous requests, so there is nothing to configure to get started.

    Add **Collaborators** - the users and teams that can use or manage this server - and assign each an **MCP Server Manager** or **MCP Server User** role. Then save.
  </Step>

  <Step title="Verify tools">
    Open the **Tools** tab. Parallel's web search and page fetch tools load, each with its description and a **Try** button. Click **Try** on one, fill in the inputs, and inspect the JSON output before wiring it into an agent.
  </Step>
</Steps>

## Using a Parallel API key

Anonymous access is rate limited. Supply a Parallel API key to lift those limits, choosing one of two credential modes:

<Tabs>
  <Tab title="Shared key">
    One team key serves every user - the Gateway injects it on every request regardless of who is calling.

    | Field              | Value                            |
    | ------------------ | -------------------------------- |
    | **Authentication** | `API Key`                        |
    | **Credentials**    | `Shared`                         |
    | **Header name**    | `Authorization`                  |
    | **Header value**   | `Bearer <your-parallel-api-key>` |

    <Warning>
      Never commit a real key to source control. Set the shared key in the UI, or keep the manifest's key value out of git - see [Managing Secrets](/docs/manage-secrets). Where per-user attribution matters, prefer the **Individual keys** mode instead.
    </Warning>
  </Tab>

  <Tab title="Individual keys">
    Each user brings their own key, so Parallel usage and billing attribute per person. Configure the header with the `{{API_KEY}}` placeholder - users supply the real value through [Auth Overrides](/docs/ai-gateway/mcp/mcp-server-auth-overrides).

    | Field              | Value                |
    | ------------------ | -------------------- |
    | **Authentication** | `API Key`            |
    | **Credentials**    | `Individual`         |
    | **Header name**    | `Authorization`      |
    | **Header value**   | `Bearer {{API_KEY}}` |

    Until a user adds their key, their tool calls fail with an authentication error rather than falling back to anonymous access.
  </Tab>
</Tabs>

## Using OAuth instead of a key

Both servers delegate OAuth2 to `https://platform.parallel.ai` and support Dynamic Client Registration, so each user authorizes with their own Parallel account and the Gateway stores and refreshes tokens per user.

Point the server at `https://search.parallel.ai/mcp-oauth` (Search) or `https://task-mcp.parallel.ai/mcp` (Task), set **Authentication** to `OAuth2`, and click **Refetch OAuth2 details** to populate the endpoints. If you need to enter them by hand, these are the values Parallel publishes:

| Field                                | Value                                            |
| ------------------------------------ | ------------------------------------------------ |
| **Grant Type**                       | `Authorization Code`                             |
| **Authorization URL**                | `https://platform.parallel.ai/getKeys/authorize` |
| **Token URL**                        | `https://platform.parallel.ai/getKeys/token`     |
| **Registration URL**                 | `https://platform.parallel.ai/getKeys/register`  |
| **Scopes**                           | `key:read`                                       |
| **Code Challenge Methods Supported** | `S256`                                           |
| **JWT Source**                       | `Access Token`                                   |
| **Client ID** / **Client Secret**    | Leave blank - DCR issues them at connection time |

Parallel registers public clients (`token_endpoint_auth_methods_supported` is `none`) and requires PKCE, which is why there is no client secret to configure.

Users then click **Connect Now** on the **Tools** tab, sign in to Parallel, and land back on the server detail page. Each user connects once with their own identity.

## Adding Parallel Task MCP to TrueFoundry

Task MCP runs long-lived research jobs asynchronously - an agent starts a task, keeps working, and polls for the result. It **requires** authentication; anonymous requests are rejected before the MCP handshake completes.

Task MCP is not in the official catalog, so register it yourself: click **Add new MCP Server**, select **Connect any Remote MCP Server**, and fill in the details with an API key or the OAuth settings above.

| Field              | Value                                                     |
| ------------------ | --------------------------------------------------------- |
| **Name**           | `parallel-task`                                           |
| **Description**    | Parallel Task MCP - deep research and dataset enrichment  |
| **URL**            | `https://task-mcp.parallel.ai/mcp`                        |
| **Authentication** | `API Key` (or `OAuth2`)                                   |
| **Credentials**    | `Individual` for per-user keys, `Shared` for one team key |
| **Header name**    | `Authorization`                                           |
| **Header value**   | `Bearer {{API_KEY}}`                                      |

The endpoint also accepts the key in an `x-api-key` header if you prefer that over `Authorization`.

Once connected, the **Tools** tab lists Task MCP's tools: starting a deep research run, starting a task group that enriches many items at once, checking the status of an in-flight task, and retrieving the finished result as markdown.

<Note>
  The status check is deliberately cheap so polling loops don't burn context. Have agents poll for status and fetch the full result only once the task reports complete.
</Note>

## Connecting to an MCP Client

Open the **How To Use** tab on the server detail page for your tenant-specific Gateway URL and ready-to-paste client snippets - don't build the endpoint manually.

The tab includes snippets for Claude Code, VS Code, Claude Web, Claude Desktop, Cursor, Windsurf, Codex, and the Python and TypeScript MCP SDKs. Use **Show API Key** if your client requires a Gateway token in a header.

## Tool Metrics

The **Tool Metrics** tab tracks invocation count, latency, and error rates per tool. Latency is worth watching here: search is low-latency while deep research is intentionally long-running, so treat them as separate baselines. See [MCP Metrics](/docs/ai-gateway/analytics-mcp-metrics) for server- and tool-level dashboards across your Gateway.

## Disabling Individual Tools

On the **Tools** tab, toggle off any tools your agents don't need. Disabled tools are hidden from MCP clients and cannot be invoked. Turning off page fetch keeps agents on search excerpts only, and turning off bulk enrichment on Task MCP limits agents to single-question research. See [MCP Tool Management](/docs/ai-gateway/mcp/mcp-tool-management) for denylist and allowlist modes.
