DOCS // SPATIAL.COMPILER

Install via MCP

Point your MCP client at the hosted server, https://mcp.spatialcompiler.dev, which signs you in with an OAuth 2.1 browser login, or run the local server with npx -y @spatial-compiler/mcp and your API key in SPATIAL_API_KEY.

Hosted MCP server

Add the server URL to your MCP client. The hosted server uses an OAuth 2.1 browser login to your Applied Manifold account, with PKCE (S256), so the config holds no key:

mcp.json
{
  "mcpServers": {
    "spatial-compiler": {
      "type": "http",
      "url": "https://mcp.spatialcompiler.dev"
    }
  }
}

In Claude Code you can register it from the command line:

terminal
claude mcp add --transport http spatial-compiler https://mcp.spatialcompiler.dev

Local MCP server

The local server, the npm package @spatial-compiler/mcp, runs over stdio through npx. It reads your API key from the SPATIAL_API_KEY environment variable and runs no login flow:

terminal
SPATIAL_API_KEY=spck_test_example npx -y @spatial-compiler/mcp

Most MCP clients (Claude Desktop, Cursor and others) accept the same JSON config block:

mcp.json
{
  "//": "Local MCP server config (stdio via npx, credential in SPATIAL_API_KEY). Rendered at <!-- @mcp-json --> on /docs/mcp/ and returned by the WebMCP get_mcp_config tool. The hosted config is derived from site.config.json MCP_URL (build/site.mjs hostedMcpConfig).",
  "mcpServers": {
    "spatial-compiler": {
      "command": "npx",
      "args": [
        "-y",
        "@spatial-compiler/mcp"
      ],
      "env": {
        "SPATIAL_API_KEY": "spck_test_example"
      }
    }
  }
}

In Claude Code you can register it from the command line:

terminal
claude mcp add spatial-compiler -e SPATIAL_API_KEY=spck_test_example -- npx -y @spatial-compiler/mcp

Replace the example key spck_test_example with your own API key. New accounts start with $5 of usage. See API keys.

Then

Restart the client and confirm the tools are listed: see MCP tools.