Connecting an AI assistant over MCP
The hosted MCP server lets your AI assistant work in a Guard.ch cloud browser. Add it to your client and sign in, then see which tools and sessions it gets.
Connect in three steps
Connect Claude Code
Install Claude Code and sign in. Use Bash or Zsh (macOS, Linux or WSL) for the command below.
1. Add the connection
Run the command in your terminal. It adds Guard.ch to your personal Claude Code settings for all projects.
Terminal
Run in your terminal
claude mcp add --scope user --transport http guardch https://api.guard.ch/mcp2. Sign in and allow access
In Claude Code, type /mcp, choose guardch and sign in on the Guard.ch page that opens.
/mcp > guardch > Authenticate
3. Try it in a new chat
Check in /mcp that guardch is connected. Then send the task below and approve the browser tools when asked.
/mcp
Open example.com in a Guard.ch browser and tell me what the page says.
0 of 3 steps marked done
Need help?
If guardch is missing, run claude mcp list in your terminal. If it asks for sign-in again, open /mcp in Claude Code, choose guardch and sign in.
Client configuration examples
MCP (Model Context Protocol) gives your assistant extra tools. With Guard.ch it works a cloud browser like a person: real mouse and keyboard input with human timing, so the site sees a visitor, not automation. It opens and reads pages, clicks, fills in forms, uploads files and takes screenshots, and it chooses the location and the apps of its sessions.
You need no local browser service or driver. Guard.ch provides the browser, runs the session and gives you a live view you can take over at any time. The model stays with your client; there is no model key to set up here.
What you need
- Endpoint
- https://api.guard.ch/mcp
- Transport
- Streamable HTTP, stateless per request
- Authentication
- Sign-in with your Guard.ch account (OAuth), or an API key in a request header
- Plan
- Business, Enterprise or the trial; API keys come with Enterprise
- Browsers
- Any Chromium-family image your plan allows, Chrome by default
- Sessions at once
- 3 per seat, agents included, shared across the workspace
Connected apps and API keys
- Sign-in is the default. Almost every client signs in by itself through OAuth. Only the Guard.ch page asks for your account; the client never sees your password. The few that cannot sign in, and your own code, use an API key instead.
- Check before you allow. The page names the app, who published it and where it returns to. An app that registered itself is marked as unverified; allow it only if you just started connecting it.
- Disconnect at any time. Connected apps are listed on the Agents tab. Disconnecting one revokes all of its access at once, even in the middle of a conversation.
- API keys for automation. Scripts, pipelines and clients that cannot sign in use an API key from the Agents tab, under Advanced. Create a separate key per client so you can revoke one without interrupting the others. API keys come with Enterprise.
- Keys expire and are shown once. A key works until you revoke it, or until a fixed date of your choice. It is shown only at creation; a lost key is revoked and replaced, not recovered.
Endpoint and authentication
The server speaks the Model Context Protocol over Streamable HTTP. Each request stands on its own, so your client can restart without the server keeping conversation state.
https://api.guard.ch/mcpClients that support MCP authorization connect with the URL alone: the server answers the first request with a sign-in challenge, and the client opens the Guard.ch sign-in page. For automation, send an API key in one of these headers instead. A key never belongs in the URL, and the server does not accept it there:
Authorization: Bearer YOUR_API_KEYas a Bearer token.x-api-key: YOUR_API_KEYfor clients that cannot set Authorization.
Client configuration examples
Show configuration examples for all clients
Claude
Setup guide for ClaudeChatGPT
Setup guide for ChatGPTVibe Work
Setup guide for Vibe WorkPerplexity
Setup guide for PerplexityLM Studio
Use the one-click install link, or open the Program tab in the right sidebar, choose Install › Edit mcp.json and add this. If the file already lists MCP servers, add only the guardch entry.
{
"mcpServers": {
"guardch": {
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for LM StudioRaycast
Setup guide for RaycastMsty Studio
Setup guide for Msty StudioClaude Code
Run the command in your terminal. It adds Guard.ch to your personal Claude Code settings for all projects.
claude mcp add --scope user --transport http guardch https://api.guard.ch/mcpSetup guide for Claude CodeCodex
Run this command in your terminal. It registers Guard.ch in your Codex configuration.
codex mcp add guardch --url https://api.guard.ch/mcp
codex mcp login guardchSetup guide for CodexGemini CLI
Run this command in your terminal. It registers Guard.ch in your personal Gemini CLI settings.
gemini mcp add --scope user --transport http guardch https://api.guard.ch/mcpSetup guide for Gemini CLIGitHub Copilot CLI
Run this command in your terminal. It saves guardch in ~/.copilot/mcp-config.json.
copilot mcp add --transport http guardch https://api.guard.ch/mcpSetup guide for GitHub Copilot CLIOpenCode
Add this to opencode.json in your project or to ~/.config/opencode/opencode.json. If the file already has an mcp section, add only the guardch entry.
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"guardch": {
"type": "remote",
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for OpenCodeGoose
Add this to ~/.config/goose/config.yaml; if the file already has an extensions section, add only the guardch entry. Alternatively, run goose configure and choose Add Extension › Remote Extension (Streamable HTTP).
extensions:
guardch:
name: guardch
type: streamable_http
uri: https://api.guard.ch/mcp
enabled: true
timeout: 300Setup guide for GooseAmp
Run this command in your terminal. It adds guardch to your Amp settings.
amp mcp add guardch https://api.guard.ch/mcpSetup guide for AmpQwen Code
Run this command in your terminal. It adds guardch to your user settings in ~/.qwen/settings.json.
qwen mcp add --scope user --transport http guardch https://api.guard.ch/mcpSetup guide for Qwen CodeFactory Droid
Run this command in your terminal. It adds guardch to your user config in ~/.factory/mcp.json.
droid mcp add guardch https://api.guard.ch/mcp --type httpSetup guide for Factory DroidCrush
Add this to crush.json or .crush.json in your project, or to ~/.config/crush/crush.json. If the file already lists MCP servers, add only the guardch entry.
{
"mcp": {
"guardch": {
"type": "http",
"url": "https://api.guard.ch/mcp",
"oauth": true
}
}
}Setup guide for CrushJunie
Add this to ~/.junie/mcp/mcp.json to use it in all projects, or to .junie/mcp/mcp.json in one project. If the file already lists MCP servers, add only the guardch entry.
{
"mcpServers": {
"guardch": {
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for JunieWarp
Open Settings › Agents › MCP servers, click + Add and paste this.
{
"guardch": {
"url": "https://api.guard.ch/mcp"
}
}Setup guide for WarpCursor
Put this configuration in ~/.cursor/mcp.json and save the file. If it already lists MCP servers, add only the guardch entry.
{
"mcpServers": {
"guardch": {
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for CursorVS Code
Install it with the one-click VS Code link, or run MCP: Open User Configuration in the Command Palette and add this. If the file already lists servers, add only the guardch entry.
{
"servers": {
"guardch": {
"type": "http",
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for VS CodeDevin Desktop
For Devin Local, run the command below in your terminal. It adds guardch to your user settings. If you use existing Cascade chats, select Cascade above instead.
devin mcp add --scope user guardch https://api.guard.ch/mcp
devin mcp login guardchSetup guide for Devin DesktopZed
Run zed: open settings file from the command palette and add this to settings.json. If it already has a context_servers section, add only the guardch entry.
{
"context_servers": {
"guardch": {
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for ZedVisual Studio
Add this to .mcp.json in your user folder (%USERPROFILE%\.mcp.json) and save. If the file already lists servers, add only the guardch entry.
{
"servers": {
"guardch": {
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for Visual StudioCline
In the Cline panel, click the MCP Servers icon, open the Configure tab and click Configure MCP Servers, then add this. If the file already lists MCP servers, add only the guardch entry.
{
"mcpServers": {
"guardch": {
"type": "streamableHttp",
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for ClineKilo Code
Add this to ~/.config/kilo/kilo.jsonc for all projects, or to kilo.jsonc in your project. If the file already has an mcp section, add only the guardch entry.
{
"mcp": {
"guardch": {
"type": "remote",
"url": "https://api.guard.ch/mcp"
}
}
}Setup guide for Kilo CodeContinue
Create a YAML file in .continue/mcpServers in your project and add the complete configuration below. The Authorization header belongs under requestOptions.headers. Switch the chat to Agent mode.
name: guardch
version: 1.0.0
schema: v1
mcpServers:
- name: guardch
type: streamable-http
url: https://api.guard.ch/mcp
requestOptions:
headers:
Authorization: "Bearer YOUR_API_KEY"Setup guide for ContinueKiro
Run Kiro: Open user MCP config (JSON) from the Command Palette, which opens ~/.kiro/settings/mcp.json, and add this. If it already lists MCP servers, add only the guardch entry.
{
"mcpServers": {
"guardch": {
"url": "https://api.guard.ch/mcp",
"oauthScopes": [
"mcp"
]
}
}
}Setup guide for KiroJetBrains AI Assistant
Open Settings › Tools › AI Assistant › Model Context Protocol (MCP) › Add. Paste the JSON below into New MCP Server, save with OK and Apply.
{
"mcpServers": {
"guardch": {
"url": "https://api.guard.ch/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}Setup guide for JetBrains AI AssistantRoo Code
In Roo Code's settings, open MCP, turn on Enable MCP Servers and click Edit Global MCP, or Edit Project MCP for .roo/mcp.json. Add this with your API key in place of YOUR_API_KEY; if the file already lists MCP servers, add only the guardch entry.
{
"mcpServers": {
"guardch": {
"type": "streamable-http",
"url": "https://api.guard.ch/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}Setup guide for Roo CodeTrae
Open Settings › MCP › Add › Add Manually. Paste the JSON below into Configure Manually and click Confirm. For an existing server, use Raw Config (JSON).
{
"mcpServers": {
"guardch": {
"url": "https://api.guard.ch/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}Setup guide for Traen8n
Setup guide for n8nCopilot Studio
Setup guide for Copilot StudioOpen WebUI
Setup guide for Open WebUILibreChat
Setup guide for LibreChatOpenAI API
Add this tool to a Responses API request and put your API key in place of YOUR_API_KEY. OpenAI does not store the key, so send it with every request.
{
"tools": [
{
"type": "mcp",
"server_label": "guardch",
"server_url": "https://api.guard.ch/mcp",
"authorization": "YOUR_API_KEY",
"require_approval": "never"
}
]
}Setup guide for OpenAI APIClaude API
Add this to a Messages API request, put your API key in place of YOUR_API_KEY and send the header anthropic-beta: mcp-client-2025-11-20.
{
"mcp_servers": [
{
"type": "url",
"url": "https://api.guard.ch/mcp",
"name": "guardch",
"authorization_token": "YOUR_API_KEY"
}
],
"tools": [
{
"type": "mcp_toolset",
"mcp_server_name": "guardch"
}
]
}Setup guide for Claude APIOpenAI Agents SDK
Create the server in your code with your API key in place of YOUR_API_KEY. Open it with async with guardch: and pass mcp_servers=[guardch] to your Agent.
from agents.mcp import MCPServerStreamableHttp
guardch = MCPServerStreamableHttp(
name="guardch",
params={"url": "https://api.guard.ch/mcp", "headers": {"Authorization": "Bearer YOUR_API_KEY"}},
)Setup guide for OpenAI Agents SDKAI SDK
Create the client in your server code with your API key in place of YOUR_API_KEY. Pass await guardch.tools() as tools to generateText or streamText and close the client with guardch.close() when you are done.
import { createMCPClient } from "@ai-sdk/mcp";
const guardch = await createMCPClient({
transport: {
type: "http",
url: "https://api.guard.ch/mcp",
headers: { Authorization: "Bearer YOUR_API_KEY" },
},
});Setup guide for AI SDKLangChain
Create the client in your code with your API key in place of YOUR_API_KEY, load the tools with await client.get_tools() and pass them to your agent, for example with create_agent.
from langchain_mcp_adapters.client import MultiServerMCPClient
client = MultiServerMCPClient({
"guardch": {
"transport": "http",
"url": "https://api.guard.ch/mcp",
"headers": {"Authorization": "Bearer YOUR_API_KEY"},
}
})Setup guide for LangChainOther client
Add guardch as a Streamable HTTP server with this URL and the Authorization header, with your API key in place of YOUR_API_KEY. The field names differ between clients, so follow your client's format.
{
"mcpServers": {
"guardch": {
"type": "http",
"url": "https://api.guard.ch/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_KEY"
}
}
}
}Setup guide for any MCP clientChoosing a browser, a location and apps
image selects an available Chromium browser when you create a session. Chrome is the default. Firefox and Tor cannot be driven programmatically; a request for either returns the supported browser IDs. screen, language and keyboard_layout set the screen size, browser language and keyboard layout when the session starts.
extensions lists the apps the session starts with, for example mail or security.reputation; without it the session starts with the apps you set to always activate. Agent Bridge is always on in agent sessions. country chooses an exit country or city (us, de, us-dal), residential a residential address there, and proxy your own proxy. browser_session_update changes the location and switches apps while the session runs.
Watching a session, and taking it over
Every session comes with a live view URL, and the sessions your agents run are listed on the Agents tab of your dashboard. Open one in the same viewer you use for your own sessions: the page streams live, and you can end the session from there.
Control is automatic: the assistant's actions drive the browser. To step in, take over with the button in the live view. The assistant then stops and tells you: its actions report user_in_control, and reading still works. When you are done, hand control back and ask it to continue in the same browser. For a sign-in or a captcha, it asks you with browser_ask_user.
Security apps
On a Chromium browser, the security apps check the page while the assistant uses it: Reputation Check, Domain Inspector, Tracker Scan, Page Guard and AI Verdict, or all of them as the Security Suite. The browser_security_* tools read what they found and run look-ups, and answer only while a security app is active in the session.
Switch them with browser_session_update, for example extensions with security.reputation set to true, or start the session with them in extensions. You can also switch them in the App Store of the live view, in a session the assistant started or in one of your own. A browser that cannot run them answers analysis_unavailable.
How the sessions behave
- Sessions can start automatically. The first page tool opens a session when none is running for that connection. If several sessions are running, Guard.ch refuses a call without a session_id instead of guessing which browser you mean.
- Retries are safe. An idempotency key returns the successful creation response on a retry instead of opening a second browser. This helps with queues and retried jobs.
- People and agents share one account. Your assistant can list, drive and close the sessions you started by hand, and you can do the same with its own. Closing one of yours closes the window you are watching, which is a good reason to name sessions.
- Access stays within your account. Every tool works on your own sessions only. No other member's sessions are visible or reachable through the server.
- Sessions end automatically. You do not set a lifetime. A session ends a few minutes after the last tool call or CDP disconnect, at the latest 18 hours after the start. Closing it yourself frees the slot immediately.
Limits and refusals
- 3 sessions at once per seat. Agent sessions count against the same limit as your own. The whole team shares the sessions of all its seats, and a workspace manager can limit individual members. When none is free, new sessions are refused rather than queued.
- MCP is a plan feature. Without it every call answers with an upgrade notice instead of a tool result. Business and Enterprise include it, and so does the trial; API keys come with Enterprise.
- Tools follow the apps. A tool of an app that is off answers with how to switch it on, or why it is locked: browser_mail needs Anonymous Mail, the browser_security_* tools a security app.
- No charge per tool. Individual tool calls cost nothing extra. Residential traffic counts against your workspace allowance, and AI Verdict runs within your plan's AI budget.
- Starting sessions is rate-limited. Limits per minute, hour and day protect the platform from too many new sessions. Check the response and wait before trying again when you reach one.
- Nothing is stored. A closed session is gone with everything it saw. The session list keeps 30 days of entries (what ran, when and for how long), never the pages themselves.
The tools your assistant gets
The server provides 32 browser_ tools that work the browser like a person: every click, keystroke and scroll is real mouse and keyboard input with human timing, so sites see a visitor, not automation. An assistant can start with browser_navigate: Guard.ch opens a session if needed and returns an accessibility snapshot with references for later actions, and browser_screenshot's pixels are the x/y coordinates browser_click, browser_hover, browser_drag and browser_scroll take.
Show all 32 tools
Sessions and account
Choose a browser, screen, location and apps, read sessions and the account, end sessions and hand the browser to a person.
| Tool | Description |
|---|---|
browser_session_create | Start a session and get its handle: browser image, name, apps, exit country, residential or own proxy, screen size, language, keyboard layout, saved profile, an initial URL and a retry key. |
browser_session_list | List every session on the account, newest first; each row says whether an agent or a person started it. With a session_id it reads that one session: status, image, current URL, whether a security app is on, and its live view URL. |
browser_session_update | Change a running session without restarting it: its name, its exit location (country or residential) or its apps, each switched on or off. |
browser_session_close | Stop a session and free its slot at once, instead of waiting for it to end on its own. |
browser_account | Read the account in one call: profile and feature access, the browser images available for sessions, saved profiles, the session quota and 30 days of usage. |
browser_ask_user | Hand the browser to the person in the live view with a message, for a sign-in, a captcha or anything only they can do. Each call waits a while for them; the assistant calls again until they hand control back. |
Navigation
Open websites, move through the history and manage tabs.
| Tool | Description |
|---|---|
browser_navigate | Open a site through the address bar, search in the search field of the page in the foreground as a person does (a site's own search, or the web from a page without one), do both in one call, or go back, forward or reload with action; the page comes back as an accessibility snapshot. This is the entry point: it opens a session when there is none. |
browser_tabs | List, open, switch and close tabs; every page tool takes a tab id. |
Reading the page
Read the page as a compact structure or a screenshot, wait for it, and read the developer data behind it.
| Tool | Description |
|---|---|
browser_snapshot | The accessibility snapshot of the page, with the ref ids the interaction tools act on. |
browser_find | Search the page for text or a regular expression and get the matching refs back. |
browser_screenshot | Capture the whole screen, including the browser toolbar, menus and native dialogs; its pixels are exactly the x/y coordinates that browser_click, browser_hover, browser_drag and browser_scroll take. |
browser_wait_for | Wait until text appears or disappears, the URL matches, or a fixed time passes. |
browser_devtools | Read developer data that browsing does not need: the console, the recorded requests, one request in full with headers and body, the cookies (including HttpOnly) or localStorage and sessionStorage. |
Interaction
Real mouse and keyboard input, by element reference or by the screen coordinates from browser_screenshot.
| Tool | Description |
|---|---|
browser_click | Click an element by ref, or a screen point x/y from browser_screenshot, with modifiers and double-click. The mouse moves there like a hand, scrolling first if needed. |
browser_type | Type into a field by ref: it is clicked and its value replaced, key by key like a person. Without a ref it types wherever the keyboard focus is, including the address bar. |
browser_fill_form | Fill several fields in one call, one after another like a person. |
browser_select_option | Open a native dropdown and choose an option with the keyboard. |
browser_press_key | Press a key or combination, such as Enter or Control+A, on an element or wherever the keyboard focus is. Also answers a JavaScript dialog (alert, confirm, prompt) with Enter or Escape. |
browser_scroll | Turn the mouse wheel by pixels, over the page or a screen point x/y; with a ref it scrolls until that element is in view. |
browser_hover | Move the mouse over an element by ref, or a screen point x/y, to reveal a hover menu or tooltip. |
browser_drag | Press the mouse on one element or point and drag it onto another, like a hand would. |
Files and mail
Hand files to a page, collect what the session downloaded and read the anonymous mail inbox.
| Tool | Description |
|---|---|
browser_file_upload | Click a file input, or a button that opens a file chooser, and answer it with your files. |
browser_downloads | List what this session downloaded, with a signed link per completed file that opens it for 15 minutes. |
browser_mail | The anonymous mail inbox: its address for sign-ups, incoming mail, and each message's text and links, such as a verification link or code. Answers while Anonymous Mail is on in a running session. |
Agent DevTools
With the Agent DevTools app on in the session: what DevTools shows, and, with read and write access, scripts and raw protocol commands.
| Tool | Description |
|---|---|
browser_inspect | Read what DevTools shows without changing the page: DOM, styles, event listeners, every request with headers, bodies, timing and TLS certificate, WebSockets, cookies, storage, IndexedDB, Cache Storage, workers, console, performance, the accessibility tree and the page's sources. |
browser_evaluate | Run JavaScript in the page like the DevTools console and get its value or exception. Needs read and write access. |
browser_cdp | Send a Chrome DevTools Protocol command to the tab, a frame, a worker or the browser and read its events. Read-only access allows only read methods. |
Security apps
Read what the security apps found on the current page and run look-ups. They answer while a security app is active.
| Tool | Description |
|---|---|
browser_security_overview | A compact overview of the current page: mood, assessment, indicators and findings. Repeat the call while it is still working. |
browser_security_inspect | Read the live evidence for the current page without navigating: overview, security, network, storage, activity or site. |
browser_security_lookup | Look up the current host or a given hostname: WHOIS, IP, certificate or site information. |
browser_security_mood | What people on the internet say about the site, researched on the web; repeat the call while it is pending. |
browser_security_verdict | The overall assessment of the current page with its findings and indicators; repeat the call while it is pending. |
Security
- Allow only apps you connected yourself. A connected app acts for your account until you disconnect it on the Agents tab.
- An API key is a credential: keep it in your client's secret store or an environment variable, never in a shared config file or a link. Send it only in a header; the server refuses keys in a URL. If one is exposed, revoke it on the Agents tab.
- Pages load in our infrastructure, never on the machine running the assistant and never in a browser profile of yours: every session runs in its own container.
- The MCP server uses no model of its own. It returns the requested results to your client, where you decide which model processes them.
- An agent's session is as visible as a person's. It is listed in the dashboard, watchable live, and can be ended by hand at any moment.
- Everything runs over TLS, and the sessions are covered by the same DPA as the rest of the product.
Troubleshooting
If something goes wrong, check these common causes first:
The client lists no tools. It has not reloaded its configuration. Restart it after adding the server, and check the URL is the /mcp endpoint above rather than the REST base.
Every call answers with an upgrade notice. The signed-in account has no plan with MCP. Start the trial, or ask a workspace manager for a seat.
A call is refused because the session is ambiguous. Two or more sessions are running on that connection, so Guard.ch will not guess which one you mean. List them and pass the session_id explicitly from then on.
Creating a session is refused. Either all of the account's session slots are in use, the image asked for cannot be driven programmatically, or an app asked for is not available. The refusal says which, and names what you may use.
A security tool answers that no security app is on. Switch one on with browser_session_update or in the App Store of the live view, then call again.
Access stopped working mid-conversation. The app was disconnected, or its API key was revoked or reached its expiry date. Sign in again from the client, or create a new key.
The sign-in page cannot continue. A sign-in request expires after a few minutes and can be answered only once. Start connecting again from your client.
The same browsers without MCP
A client that does not speak MCP can start the same sessions over REST and attach Playwright or Puppeteer to the CDP endpoint each one returns. The API guide covers that route.
Next steps
Add the endpoint to your client, sign in and ask the assistant to open a page. You can watch or end its sessions, disconnect apps and create API keys for scripts on the Agents tab. If your client is missing from this guide, get in touch.