Docs — Clients

One URL, every agent.

Exorails speaks MCP Streamable HTTP (revisions 2025-03-26 through 2026-07-28) and negotiates the version each client supports.

Claude Code

claude mcp add --transport http acme-api https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af
# then, inside Claude Code: /mcp → acme-api → Authenticate

# project-wide, shared through .mcp.json
claude mcp add --transport http acme-api --scope project https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af

# older Claude Code, where --transport is not a known option:
claude mcp add-json acme-api '{"type":"http","url":"https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af"}'

To skip the browser sign-in, send the token in a header instead: --header "Authorization: Bearer k_7f3a9c2e".

Tools appear as mcp__acme-api__<server>__<tool>. Claude Code negotiates MCP 2026-07-28 with the gateway; older runtimes fall back to 2025-11-25 automatically.

Cursor

// .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)
{
  "mcpServers": {
    "acme-api": { "url": "https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af" }
  }
}

// with the token in a header instead of signing in
{
  "mcpServers": {
    "acme-api": {
      "url": "https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af",
      "headers": { "Authorization": "Bearer k_7f3a9c2e" }
    }
  }
}

Codex

# ~/.codex/config.toml
[mcp_servers.acme-api]
url = "https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af"
# then: codex mcp login acme-api

# or with the token in a header
[mcp_servers.acme-api]
url = "https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af"
http_headers = { Authorization = "Bearer k_7f3a9c2e" }

Windsurf, VS Code, Gemini CLI, others

Add a remote server of type Streamable HTTP with the environment URL. If the client supports MCP authorization, it will sign you in on first use; otherwise give it the header Authorization: Bearer <token>.

How the token reaches the gateway

An environment accepts the token in a request header, or no token at all when the client signs in with OAuth. Both use the same address, the environment URL without a token: https://mcp.exorails.net/e/7c1f0a2e-9d84-4b6c-a0f1-2b5c8e4d31af. Signing in gives each client its own access token (24 hours, refreshed automatically for 90 days), revocable one client at a time from the access review; the header form is the same environment token for everyone, and is what CI runners and clients without MCP authorization use.

A third form exists, the token inside the URL, and new environments refuse it: it turns the address itself into a password that leaks through shell history, proxy logs and screenshots. An admin can allow it per environment under Settings → Access, and should turn it off again afterwards. Securing the environment URL →

CI and headless agents

Give the runner the environment URL and the token as two separate secrets, and send the token in the Authorization header. Rotate it from the dashboard if it ever ends up in a log.

Tool names

With one server in the environment, tools keep their upstream names. With several, each tool is prefixed with the server's short name and two underscores: github__search_issues, linear__create_issue. You can force the prefix on or off per environment, rename a server, and hide tools you do not want the agent to see.

Errors an agent can see

HTTPMeaning
401Unknown, rotated or expired URL, or a token presented in a way this environment refuses. The message says which.
403The environment is paused (downgrade, abuse) or the organization is suspended.
429Monthly allowance or spend cap reached, or too many requests per second on this URL. Retry-After says when.

Upstream failures come back as tool errors the model can read: “the github server could not be reached”, “linear needs authorization”. Upstream addresses are never included.