MCP Server
Connect AI agents (Claude, Cursor) to Savannah Cloud via JSON-RPC 2.0 and SSE.
Savannah Cloud exposes a Model Context Protocol server for AI agent integration. Agents can manage deployments, set env vars, fetch logs, and more — all through tool calls.
Endpoints
| Method | Path | Description |
|---|---|---|
POST | /mcp | JSON-RPC 2.0 tool call |
GET | /mcp/sse | Server-Sent Events stream for real-time results |
Authentication: X-API-Key: sc_... or Authorization: Bearer sc_...
Connect from Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"savannah": {
"url": "https://api.savannahcloud.com/mcp",
"headers": {
"X-API-Key": "sc_your_key_here"
}
}
}
}Available Tools
| Tool | Description |
|---|---|
list_deployments | List all deployments for the authenticated org |
create_deployment | Create a new deployment from a GitHub repo |
delete_deployment | Stop and remove a deployment |
get_logs | Fetch build/runtime logs for a deployment |
set_env_vars | Set environment variables on a deployment |
redeploy | Trigger a redeploy on a deployment |
Tool Call Format
POST /mcp
X-API-Key: sc_your_key
Content-Type: application/json{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "list_deployments",
"arguments": {}
}
}Response
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"content": [
{
"type": "text",
"text": "[{\"id\":\"dep_abc\",\"name\":\"my-app\",\"status\":\"running\"}]"
}
]
}
}List Tools
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list",
"params": {}
}SSE Stream
For streaming results (e.g., log tailing):
GET /mcp/sse
X-API-Key: sc_your_keyEvents are pushed as data: {...} in SSE format.
Quick Reference
# List deployments via MCP
curl -X POST https://api.savannahcloud.com/mcp \
-H "X-API-Key: sc_your_key" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"list_deployments","arguments":{}}}'
# Create deployment via MCP
curl -X POST https://api.savannahcloud.com/mcp \
-H "X-API-Key: sc_your_key" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"create_deployment","arguments":{"repo":"https://github.com/org/app","branch":"main"}}}'
# Get logs via MCP
curl -X POST https://api.savannahcloud.com/mcp \
-H "X-API-Key: sc_your_key" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"get_logs","arguments":{"deployment_id":"dep_abc"}}}'