Skip to navigation

Create

Creates an MCP server in the authenticated workspace and project. Phonic connects to the server, lists its tools and saves them alongside the server, so the server must be reachable from Phonic’s network. The supplied headers are sent on every request Phonic makes to the server; their values are stored encrypted and never returned. Creating the server does not attach it to an agent; add its ID to an agent’s mcp_server_ids to make its tools available.

Authentication

AuthorizationBearer

Bearer authentication header of the form Bearer <PHONIC_API_KEY>. Manage your API keys here.

Query parameters

projectstringOptionalDefaults to main
The name of the project to create the MCP server in.

Request

This endpoint expects an object.
namestringRequired

The name of the MCP server. Must be snake_case, start with a lowercase letter and be unique within the project.

urlstringRequired
The URL of the MCP server. Must be a publicly routable HTTPS URL without embedded credentials. Cannot be changed after creation.
headersmap from strings to stringsOptionalDefaults to {}

Headers sent on every request to the MCP server (e.g. for authentication). Header names must be unique (case-insensitive) and values cannot contain line breaks. Values are stored encrypted and never returned.

Response

Success response
idstring
The ID of the created MCP server.
namestring
The name of the created MCP server.

Errors

400
Bad Request Error
401
Unauthorized Error
404
Not Found Error
409
Conflict Error
500
Internal Server Error