---
docId: doc_e25c4dd54214434fac6db3bc33f03d8a
title: Test an MCP server
description: "Verify a connection and discover an MCP server's tools."
api:
  group: herramientas/servidores-mcp
  auth: bearer
  operations:
    - operationId: testMcpServer
      method: POST
      path: '/v1/tools/mcp/{mcpId}/test'
      postmanName: Test an MCP server
---

<script>
  import { Ways, Collapsible } from '$lib/components';
</script>

# Test an MCP server

Test the connection using its bound secrets and save the tool list in `discoveredTools`. A successful test sets `verified: true`. Use it:

- after binding a secret or completing OAuth,
- after [updating](/api-reference/mcp-servers/update) the connection,
- when the server changed its tools and you want to see them.

## Example

<Ways tabs="api,sdk">
<Ways.Way name="api">

```bash
curl -X POST https://api.platic.ai/v1/tools/mcp/$MCP_ID/test \
  -H "Authorization: Bearer $PLATIC_API_KEY"
```

</Ways.Way>
<Ways.Way name="sdk">

```ts
await platic.tools.mcp.test("mcp_123");
```

</Ways.Way>
</Ways>

## Path parameters

| Parameter | Type | Description | Required |
|-----------|------|-------------|----------|
| `mcpId` | string | Id of the MCP server | ✓ |

## Request body

It has no body.

## Response

`data` has the full server, with the fields in [get an MCP server](/api-reference/mcp-servers/get#response-fields), plus `verification`.

```json
{
  "status": "success",
  "message": "MCP server verified",
  "data": {
    "id": "QZPHpckDPC58JIVLQA3Z",
    "name": "Linear",
    "description": "Support team issues",
    "url": "https://mcp.linear.app/mcp",
    "transport": "streamable-http",
    "slug": "a1b2c3",
    "authType": "bearer",
    "auth": { "type": "bearer" },
    "status": "pending_config",
    "lastError": null,
    "serverInfo": { "name": "linear-mcp", "version": "1.4.0" },
    "customHeaderNames": [],
    "discoveredToolsCount": 2,
    "installedToolsCount": 0,
    "lastSyncAt": null,
    "createdAt": "2026-10-28T12:02:11.410Z",
    "updatedAt": "2026-10-28T12:05:02.000Z",
    "version": 1,
    "verified": true,
    "secrets": [
      {
        "slot": "auth.token",
        "state": "authorized",
        "secretId": "5d0c7a1e9b3f4a6c8e2d1f0b7a9c3e5d6f8a0b2c4d6e8f1a3b5c7d9e0f2a4b6c"
      }
    ],
    "discoveredTools": [
      {
        "name": "create_issue",
        "description": "Create a new issue in Linear",
        "inputSchema": {
          "type": "object",
          "properties": {
            "title": { "type": "string" },
            "teamId": { "type": "string" }
          },
          "required": ["title", "teamId"]
        },
        "installed": false
      },
      {
        "name": "search_issues",
        "description": "Search issues by text query",
        "inputSchema": {
          "type": "object",
          "properties": { "query": { "type": "string" } }
        },
        "installed": false
      }
    ],
    "installedTools": [],
    "verification": { "confirmed": true },
    "nextStep": "Verified. Choose which tools to install with POST /v1/tools/mcp/QZPHpckDPC58JIVLQA3Z/tools/sync: create_issue, search_issues."
  }
}
```

### Response fields

| Field | Type | Description |
|-------|------|-------------|
| `verified` | boolean | `true` if the connection passed the test |
| `verification.confirmed` | boolean | The result of this test |
| `discoveredTools` | array | The tools the server offers now |
| `serverInfo` | object \| null | What the server said about itself |
| The rest | — | See [get an MCP server](/api-reference/mcp-servers/get#response-fields) |

`message` is `MCP server verified` when it passed and `The connection did not pass the test` when it did not.

## Errors

<Collapsible summary="Show error codes and fixes">

| Status | `details.code` | When it happens |
|--------|----------------|-----------------|
| `403` | `FORBIDDEN` | The person behind the token does not have access to Integrations |
| `404` | `NOT_FOUND` | The server does not exist in this workspace |
| `409` | `AUTHORIZATION_REQUIRED` | A credential is missing: a slot without a secret, or an OAuth server that is not authorized |
| `409` | `MCP_REAUTH_REQUIRED` | The server needs to be authorized again from Platica |
| `409` | `MCP_CONNECTION_CHANGED` | The server changed during the test. Repeat the call |
| `409` | `RESOURCE_CHANGED` | The connection changed during the test. Repeat the call |
| `409` | `TOO_MANY_TOOLS` | The server offers more tools than allowed |
| `409` | `INVALID_CAPABILITY` | The server offers tools with repeated or invalid names |
| `409` | `CAPABILITY_TOO_LARGE` | The server's list of tools is too large |
| `503` | `OPERATION_UNCONFIRMED` | The test could not be completed, for example because the server did not respond. Get the server before retrying |

</Collapsible>

## Notes

- Testing installs nothing. New tools arrive with `installed: false` until you add them with [choose MCP tools](/api-reference/mcp-servers/select-tools).
- The test is valid for the connection and the secrets it was made with. If you change the connection, bind another secret, or rotate one, test again before choosing tools.
- The call waits for the server for up to 90 seconds.
