MCP client integration
Twin Browser + Windsurf
Windsurf is Codeium’s AI-native editor, whose Cascade agent supports MCP servers. Servers are registered in `~/.codeium/windsurf/mcp_config.json` in the same `mcpServers` shape most clients use.
How Twin plugs into Windsurf
Register the Twin server and Cascade can act on the web as part of an editing session — verify a deployed change, pull a fixture from behind a login, or reproduce a reported bug on a real page. The config is byte-identical to Cursor’s and Claude Desktop’s, because the server is the same stdio process in all three.
Twin is the browser execution layer your stack calls. The first run cold-compiles a skill via skill compilation; every similar request after that is matched from the cache and replayed deterministically, so your marginal cost per run trends toward zero rather than climbing with usage.
- Receive goal from Windsurfdone
- Compile DOM → token-efficient indexed statedone
- Match the semantic dispatch cacherunning
- Replay compiled skill — 0 LLM callsqueued
What you get through Windsurf
Every integration is a thin wrapper over the same execution layer, so the cache, the replay, and the corpus apply no matter how you call in.
Semantic dispatch cache
A re-phrased goal fuzzy-matches an already-compiled skill, so most calls never touch the LLM.
Deterministic replay
A compiled skill replays the exact action path with zero LLM calls — fast, repeatable, cheap.
Cross-tenant skill corpus
A skill compiled once can be safely reused across tenants, so the hit rate climbs as the network runs.
One Bearer key
Auth, usage-based billing, and an audit log run on every call — the same key works from every integration.
Wire it up
Drop Twin into Windsurf.
Copy, paste, and swap in your Bearer key. The first run compiles a skill; repeats match the semantic dispatch cache and replay deterministically.
{
"mcpServers": {
"twin-browser": {
"command": "npx",
"args": ["-y", "twin-browser-mcp"],
"env": { "TWIN_API_KEY": "ab_live_…" }
}
}
}
// In Cascade:
// "Use twin-browser to open the preview URL and screenshot the pricing page."Base URL https://twin-browser.com/api/v1 · auth Authorization: Bearer ab_live_… · over MCP the same engine is run_goal, compile_skill and run_skill — the full tool table.
Get an API key
Create an ab_live_ key in the Twin dashboard under Keys & Secrets.
Open the MCP config
Edit ~/.codeium/windsurf/mcp_config.json (Windsurf’s MCP settings panel opens it for you).
Add the server
Add a twin-browser entry under mcpServers with the npx command and TWIN_API_KEY in env.
Refresh and use it
Refresh the server list; Cascade picks up the tools.
FAQ
Windsurf on Twin — common questions
Is the Windsurf config different from Cursor’s?
Does Windsurf need Node?
Related
More ways to connect Twin
Cursor
Cursor is an AI-native code editor with a built-in agent that can call MCP tools. Servers are registered in `.cursor/mcp.json` for a project or `~/.cursor/mcp.json` globally, and their tools become available to the agent while you work.
Visual Studio Code
VS Code’s Copilot agent mode supports MCP servers, configured in `.vscode/mcp.json` for a workspace or in your user profile. Note the shape difference: VS Code uses a top-level `servers` key where most other clients use `mcpServers`.
MCP (Model Context Protocol)
MCP is an open protocol that lets an LLM application discover and call external tools over a standard interface. An MCP client — Claude Desktop, Claude Code, Cursor, Windsurf, VS Code, Cline — launches or connects to an MCP server, lists its tools, and invokes them on the model’s behalf, with no bespoke glue per app.
Wire up Windsurf in minutes.
Free to start. Usage-based credits from $29/mo — each call billed the higher of its flat action price or its metered cost.