Skip to main content
POST
Create a new MCP server

Authorizations

Authorization
string
header
required

Use either an Alloy API key or JWT token

Headers

x-alloy-userid
string

User ID for server ownership (optional with API key)

Body

application/json
name
string
required

Server name (1-100 characters)

Required string length: 1 - 100
description
string

Server description

customInstructions
string

Custom instructions for AI assistants (beta)

tokenExpiresInDays
integer

Token expiration in days (1-365)

Required range: 1 <= x <= 365
restrictions
object

Response

Server created successfully

serverId
string

Unique server identifier

name
string

Server name

description
string

Server description

url
string

Base URL for API-authenticated access

accessUrl
string

Self-sufficient URL with embedded token

restrictions
object
hasRestrictions
boolean

Whether server has active restrictions

createdAt
string<date-time>
updatedAt
string<date-time>
accessToken
string

Access token (only returned on creation)