Skip to content
Gateway docs Free to start

Put an agent behind Gateway.

Connect a coding agent in a few minutes, or route your own agent's calls through SecureSpace Gateway. Sign up free; agents and keys are created in the console.

Quickstart · cURL
curl -X POST https://gateway.securespace.club/v1/proxy/crm/contacts \
  -H "x-securespace-api-key: $SECURESPACE_API_KEY" \
  -H "content-type: application/json" \
  -d '{"name": "Ada", "email": "ada@example.com"}'
Quickstart

Four ways in.

All start with a free account, and the same rules apply to each. Your organisation begins with starter rules: force-pushes, wiping the disk, and system files are blocked, fake links are stopped, and secrets need a person's approval.

A coding agent

Claude Code, Codex, Grok Build, GitHub Copilot, Gemini CLI, or Cursor. Install the plugin or hooks, sign the machine in, and approve the code in the console.

Claude Code
/plugin marketplace add securespace-dev/securespace-plugin
/plugin install securespace@securespace
Copilot, Gemini CLI, Cursor
npx @securespace-club/cli install-hooks --platform copilot
# or: --platform gemini-cli, --platform cursor
Then sign this machine in
npx @securespace-club/cli login

Your own agent

  1. 1. Register a destination on the console's Upstreams page, for example crm.
  2. 2. Create an agent on the Agents page, and a key for it. The key is shown once.
  3. 3. Send its calls through Gateway with the key, by plain HTTP or an SDK.
Install an SDK
npm install @securespace-club/sdk-node
pip install securespace
Or plain HTTP
curl -X POST https://gateway.securespace.club/v1/proxy/crm/contacts \
  -H "x-securespace-api-key: $SECURESPACE_API_KEY" \
  -H "content-type: application/json" \
  -d '{"name": "Ada", "email": "ada@example.com"}'

Claude, ChatGPT and Grok

Add SecureSpace as a custom connector, sign in, and choose Allow. There is no key to copy. The assistant can then check links, fetch pages safely, ask a person for approval, and read your rules.

Connector address
https://api.securespace.club/mcp
  • Claude: Settings, Connectors, Add custom connector.
  • ChatGPT: Settings, Apps and Connectors, developer mode, create a connector.
  • Grok: grok.com/connectors, add a custom connector.

The browser

Coming to Chrome and Edge

The SecureSpace extension checks every page a person, or an AI agent browsing for them, opens: lookalike sites are stopped before anything is typed, and a secret pasted into ChatGPT, Claude, Gemini or Grok is caught first, on the device.

  • Works without an account; signed in, your organisation's rules apply.
  • Admins can install it on every browser by policy and stop it being paused.
  • Pasted text is never sent anywhere.
Concepts

Four ideas to understand first.

01

Gateway is a service you call

Your agent sends requests to Gateway's URL. Nothing is injected into your process, so there is no in-process enforcement to bypass.

02

Destinations are names, not URLs

Your organisation registers each destination once (for example crm). Agents then address it by name. A request cannot name a host you did not register.

03

Gateway classifies the action

The recorded verb reflects what the request does. You may declare a verb with x-securespace-verb; it can raise the classification, never lower it.

04

A block is a result

A refused request returns a structured response your code can branch on. The SDKs return it as a value rather than throwing.

SDKs

Node and Python.

Both SDKs are thin clients over the HTTP contract below and depend on nothing outside the standard library. Any language can call Gateway directly.

Node · send calls through Gateway
import { SecureSpaceClient } from "@securespace-club/sdk-node";

const ss = new SecureSpaceClient({
  baseUrl: "https://gateway.securespace.club",
  apiKey: process.env.SECURESPACE_API_KEY!,
});

// "crm" is a destination your organisation registered.
const res = await ss.post("crm", "/contacts", { name: "Ada" });

if (res.blocked) {
  console.error(`blocked: ${res.errorCode} (${res.decision.action})`);
} else {
  console.log(res.body);
}
Python · send calls through Gateway
import os
from securespace import SecureSpaceClient

ss = SecureSpaceClient(
    "https://gateway.securespace.club",
    os.environ["SECURESPACE_API_KEY"],
)

res = ss.post("crm", "/contacts", {"name": "Ada"})

if res.blocked:
    print(f"blocked: {res.error_code} ({res.decision.action})")
else:
    print(res.body)

Guard your agent's own tools.

Wrap a tool and SecureSpace decides before it runs. A refused call throws instead of running, and frameworks hand that to the model as a tool error. Only a hash of the arguments is sent; once a person approves, the identical call runs once.

Node · guardTool
import { guardTool } from "@securespace-club/sdk-node";

// SecureSpace decides before the tool runs. Use refund as the tool's body in
// the OpenAI Agents SDK, LangGraph.js or the Vercel AI SDK.
const refund = guardTool(
  {
    gatewayUrl: "https://gateway.securespace.club",
    apiKey: process.env.SECURESPACE_API_KEY!,
    namespace: "billing",
  },
  { name: "refund", declaredVerb: "transfer" },
  async (orderId: string, amount: number) => payments.refund(orderId, amount),
);
Python · Guard (securespace 0.2.0)
import os
from agents import function_tool  # or LangChain's @tool, CrewAI's @tool
from securespace import Guard

guard = Guard(
    "https://gateway.securespace.club",
    os.environ["SECURESPACE_API_KEY"],
    namespace="billing",
)

@function_tool
@guard.tool(declared_verb="transfer")
def refund(order_id: str, amount: int) -> str:
    """Refund an order."""
    return payments.refund(order_id, amount)
Wire contract

The request.

Endpoint
ANY /v1/proxy/:upstream/<path>?<query>
HeaderRequiredMeaning
x-securespace-api-keyRequiredThe agent's API key.
x-securespace-verbOptionalYour claim about the action. Raises the classification only.
content-typeWith a bodyRequired when sending a request body.

:upstream is a destination name your organisation registered: lower-case letters, digits, dots, underscores, and hyphens, up to 63 characters. The path segment is authoritative and cannot be overridden by a header.

Wire contract

The response.

The destination's status, body, and most headers are returned as-is. Gateway adds the headers below. Set-Cookie from the destination is not relayed.

HeaderMeaning
x-securespace-action-idThe recorded action. Quote it when asking about a decision.
x-securespace-decision-idThe decision that was enforced.
x-securespace-actionThe verb Gateway classified.
x-securespace-upstream-calledfalse when Gateway refused before contacting the destination.
x-securespace-redirect-not-followedtrue when a redirect was returned rather than followed.
Errors

One error shape, nine codes.

Errors are always JSON. Retrying control_plane_unavailable is reasonable, and rate_limited after its Retry-After. Retrying policy_denied is not: it is a decision.

Error body
{ "error": { "code": "policy_denied", "message": "..." } }
StatusCodeMeaning
401unauthenticatedMissing, wrong, revoked, or expired key.
400invalid_requestMissing destination name or unreadable body.
404upstream_not_registeredThat name is not configured for your organisation.
403policy_deniedYour policy refused the request. The destination was not contacted.
403approval_requiredA rule asks a person first. The x-securespace-approval-id header names the request; once it is approved in the console, the identical retry runs once.
429rate_limitedA limit or budget rule is used up. Retry-After says when to try again.
403upstream_blockedA network-safety control refused the destination.
502control_plane_unavailableNo decision could be obtained, so the request was refused.
502upstream_unreachableThe request was allowed; the destination then failed.
Good to know

Behaviour that may surprise you.

  • Redirects are returned to you, not followed. A redirect target has not been checked.
  • Neither Gateway nor the SDKs retry. A refusal is a decision, not a transient error.
  • Your API key never reaches the destination. It is removed before forwarding.
  • Request and response bodies are buffered, so Gateway is not suited to large file transfers.
  • Remote MCP servers are reached through a separate endpoint over Streamable HTTP. Local servers a coding agent launches go through the CLI's bridge (securespace mcp-bridge).
Free to start

Ready to route your first agent?

Sign up, then connect a coding agent or create a key for your own. Running agents in production across a team? We can help you set it up.