Connect an MCP server
SDK platic.tools.mcp.create()
Save an MCP server connection. Platica also tests it to discover its tools when all credentials are ready:
- The server is public (
auth.type: "none"), or - you sent in
secretsthe secret for each slot.
If a credential is missing, the connection is saved and nextStep says what comes next.
Example
curl https://api.platic.ai/v1/tools/mcp \
-H "Authorization: Bearer $PLATIC_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "name": "Docs", "url": "https://mcp.example.com/mcp" }' await platic.tools.mcp.create({ name: "Docs", url: "https://mcp.example.com/mcp" }); Request body
| Field | Type | Description | Required |
|---|---|---|---|
name | string | Name of the server inside Platica, 1 to 120 characters | ✓ |
url | string | URL of the MCP server | ✓ |
description | string | Up to 500 characters | — |
auth | object | How it authenticates, without the credential. See authentication. Defaults to { "type": "none" } | — |
headers | object | Fixed headers, as name: value pairs. A header that carries a credential goes with an empty value and is bound as header:<name> | — |
secrets | object | Map of slot to secret id, to bind in this same call | — |
tools | string[] | Original names of the tools to install as soon as the connection is verified. Up to 100. If you omit it, none is installed | — |
{
"name": "Linear",
"description": "Support team issues",
"url": "https://mcp.linear.app/mcp",
"auth": { "type": "bearer" },
"secrets": {
"auth.token": "5d0c7a1e9b3f4a6c8e2d1f0b7a9c3e5d6f8a0b2c4d6e8f1a3b5c7d9e0f2a4b6c"
}
} Authentication
auth | Slot it exposes |
|---|---|
{ "type": "none" } | None |
{ "type": "bearer" } | auth.token: the server's token |
{ "type": "apikey-header", "headerName": "X-Api-Key", "headerPrefix": "" } | auth.token: the key, sent in the headerName header after the headerPrefix text. headerName is required |
{ "type": "oauth2", "scope": "read write", "clientId": "…" } | None you have to bind: a person authorizes it. scope and clientId are optional |
Response
201 Created. data has the full server, with the fields in get an MCP server.
{
"status": "success",
"message": "MCP server saved — see nextStep",
"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:02:14.900Z",
"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."
}
} message is MCP server connected successfully when the call left tools installed, and MCP server saved — see nextStep in every other case.
What happens depending on what you send
| You sent | Result |
|---|---|
A public server, or a complete secrets | It is saved and tested. discoveredTools has what it offers |
The above, plus tools | It also installs those tools and the server ends up connected |
bearer or apikey-header without secrets | It is saved without testing. The auth.token slot stays missing |
oauth2 | It is saved as pending_auth. Continue with start OAuth |
Important
The connection is saved even if the first test fails or a secret cannot be bound. The response is still 201 and carries the reason in data.testError or data.secretsError, both as { code, message }. Do not connect it again: fix the problem and use test an MCP server.
Errors
| Status | details.code | When it happens |
|---|---|---|
400 | INVALID_REQUEST | name or url is missing, or a field fails validation. details.issues has the list of problems |
400 | SECRET_REFERENCE_REQUIRED | You sent a credential inside the connection: auth.token, auth.clientSecret, or a header with a credential name and a value. When it applies, details.slot names the slot |
400 | INVALID_CONFIG | The name, URL, or authentication is not valid, or the headers have repeated or disallowed names |
403 | FORBIDDEN | The person behind the token does not have access to Integrations |
Notes
- Follow what
nextStepsays: bind a secret, start OAuth, test, or choose tools. - The names in
toolsare the ones indiscoveredTools[].name. If you do not know them yet, connect withouttoolsand choose them later. - After installing a tool, use connect a tool to assign it to an agent.
- The call can take a while: the test waits for the server for up to 90 seconds.