Skip to content

Connect via Gateway

Every workspace has a gateway URL that speaks the MCP protocol. Connect any MCP-compatible client — Claude Desktop, Cursor, your own applications — using this single endpoint and a bearer token.


https://mcp.aerostack.dev/ws/<workspace-slug>

Authenticate every request with a workspace token in the Authorization header:

Authorization: Bearer mwt_7a3f9c1e8b4d2f6a...

See Tokens for how to create tokens.


When you create a token in the dashboard, the response includes a ready-to-use mcp_json configuration block. Copy it directly into your client.

Add the following to your claude_desktop_config.json:

{
"mcpServers": {
"my-workspace": {
"url": "https://mcp.aerostack.dev/ws/my-workspace",
"headers": {
"Authorization": "Bearer mwt_7a3f9c1e8b4d2f6a..."
}
}
}
}

On macOS, this file is at ~/Library/Application Support/Claude/claude_desktop_config.json. On Windows, it is at %APPDATA%\Claude\claude_desktop_config.json.

Restart Claude Desktop after editing the config. Your workspace tools will appear in the tools panel.


The gateway supports four JSON-RPC methods:

Handshake method. Returns gateway capabilities and protocol version.

{
"jsonrpc": "2.0",
"id": 1,
"method": "initialize",
"params": {
"protocolVersion": "2024-11-05",
"capabilities": {},
"clientInfo": { "name": "my-app", "version": "1.0.0" }
}
}

Response:

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"protocolVersion": "2024-11-05",
"capabilities": { "tools": { "listChanged": false } },
"serverInfo": { "name": "aerostack-mcp-gateway", "version": "1.0.0" }
}
}

Health check. Returns an empty result.

Returns all tools from all enabled servers in the workspace. The gateway fans out to each server in parallel and merges the results.

{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}

Response:

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"tools": [
{
"name": "github__create_issue",
"description": "Create a new GitHub issue",
"inputSchema": {
"type": "object",
"properties": {
"title": { "type": "string" },
"body": { "type": "string" },
"repo": { "type": "string" }
},
"required": ["title", "repo"]
}
}
]
}
}

Call a specific tool. Use the namespaced tool name (for example, github__create_issue). The gateway parses the prefix, routes to the correct upstream server, and returns the result.

{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "github__create_issue",
"arguments": {
"title": "Fix login bug",
"repo": "my-org/my-repo"
}
}
}

Response:

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"content": [
{
"type": "text",
"text": "Created issue #42: Fix login bug"
}
]
}
}

If you are building with a non-MCP LLM provider, the gateway provides adapter endpoints that translate MCP tools into provider-specific schemas.

GET https://mcp.aerostack.dev/ws/:slug/openai-tools
Authorization: Bearer mwt_...

Returns tools formatted for OpenAI’s function calling API:

{
"tools": [
{
"type": "function",
"function": {
"name": "github__create_issue",
"description": "Create a new GitHub issue",
"parameters": { "type": "object", "properties": { ... } }
}
}
]
}
GET https://mcp.aerostack.dev/ws/:slug/gemini-tools
Authorization: Bearer mwt_...

Returns tools formatted for Gemini’s function declaration API.


ParameterValue
Requests per minute per token120
Max request body size1 MB
Tool call upstream timeout15 seconds
Tool list fan-out timeout per server10 seconds

When rate-limited, the gateway returns HTTP 429.


HTTP StatusJSON-RPC CodeMeaning
401N/AInvalid or missing token
404N/AWorkspace not found
413N/ARequest body exceeds 1 MB
429-32000Rate limit exceeded
200-32600Invalid JSON-RPC request
200-32601Method not found
200-32000Upstream server error or timeout

The gateway caches workspace configuration for performance. Any write operation to the workspace (add server, revoke token, update secret) invalidates the cache immediately. Changes take effect within seconds.