Quickstart
Create your first MCP server and connect to it in under 5 minutes.
Step 1: Get Your API Key
All requests to the Agent Dojo API require authentication via the X-API-Key header. Sign up at Agent Dojo and generate an API key from your dashboard. Include it in every request:
X-API-Key: your-api-keyStep 2: Create Your First Server
Create an MCP server by sending a POST request with a name. The server will be assigned a unique slug and URL automatically.
curl -X POST https://api.agentdojo.dev/mcp/servers \
-H "Content-Type: application/json" \
-H "X-API-Key: your-api-key" \
-d '{"name": "My First Server"}'Response:
{
"success": true,
"data": {
"id": 1,
"slug": "my-first-server",
"name": "My First Server",
"url": "https://api.agentdojo.dev/my-first-server"
}
}Step 3: List Available Toolkits
Browse the available toolkits to find tools you want to add to your server. Toolkits are pre-built collections of tools for common services.
curl https://api.agentdojo.dev/mcp/toolkits \
-H "X-API-Key: your-api-key"Step 4: Connect via MCP Protocol
Connect to your server using the standard MCP protocol. Start by sending an initialize request to establish a session:
curl -X POST https://api.agentdojo.dev/mcp/my-first-server \
-H "Content-Type: application/json" \
-H "X-API-Key: your-api-key" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "initialize",
"params": {
"protocolVersion": "2025-11-25",
"clientInfo": {
"name": "my-app",
"version": "1.0.0"
},
"capabilities": {}
}
}'Step 5: List and Call Tools
Once connected, list all available tools on your server using the tools/list method:
curl -X POST https://api.agentdojo.dev/mcp/my-first-server \
-H "Content-Type: application/json" \
-H "X-API-Key: your-api-key" \
-d '{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/list",
"params": {}
}'To call a specific tool, use the tools/call method with the tool name and arguments:
curl -X POST https://api.agentdojo.dev/mcp/my-first-server \
-H "Content-Type: application/json" \
-H "X-API-Key: your-api-key" \
-d '{
"jsonrpc": "2.0",
"id": 3,
"method": "tools/call",
"params": {
"name": "tool-name",
"arguments": {
"param1": "value1"
}
}
}'