Skip to main content
POST
/
ai-agents
/
agent-builder
/
mcp-servers
Create MCP Server
curl --request POST \
  --url https://{appId}.api-{region}.cometchat.io/v3/ai-agents/agent-builder/mcp-servers \
  --header 'Content-Type: application/json' \
  --header 'apikey: <api-key>' \
  --data '
{
  "name": "Weather Server",
  "slug": "weather-server",
  "url": "http://localhost:3001",
  "description": "Provides weather data for cities",
  "icon": "http://localhost:3001/icon.png"
}
'
{
  "_id": "myapp_my-mcp-server",
  "appId": "my-app-id",
  "slug": "my-mcp-server",
  "name": "My MCP Server",
  "description": "A Model Context Protocol server",
  "url": "https://mcp.example.com/sse",
  "icon": "https://example.com/icon.png",
  "createdAt": 1700000000000,
  "updatedAt": 1700000000000
}

Documentation Index

Fetch the complete documentation index at: https://cometchat-22654f5b-docs-android-v6-beta2.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

For the complete error reference, see Error Guide.

Authorizations

apikey
string
header
required

API Key (i.e. Rest API Key from the Dashboard).

Body

application/json
name
string
required

Name of the MCP server (human readable)

Example:

"Weather Server"

slug
string
required

Slug of the MCP server (unique, URL-safe)

Example:

"weather-server"

url
string
required

URL of the MCP server

Example:

"http://localhost:3001"

description
string

Description of the MCP server

Example:

"Provides weather data for cities"

icon
string

Icon for the MCP server

Example:

"http://localhost:3001/icon.png"

Response

201 - application/json

MCP server created successfully

_id
string
Example:

"myapp_my-mcp-server"

appId
string
Example:

"my-app-id"

slug
string
Example:

"my-mcp-server"

name
string
Example:

"My MCP Server"

description
string
Example:

"A Model Context Protocol server"

url
string
Example:

"https://mcp.example.com/sse"

icon
string
Example:

"https://example.com/icon.png"

createdAt
number
Example:

1700000000000

updatedAt
number
Example:

1700000000000