# Set Up StringLane in Any MCP Host

> The host-neutral way to wire stringlane mcp into a coding agent: what the server is, what configuration it needs, how to scope it to a project or a machine, and how to check it connected.

Source: https://stringlane.app/docs/cli/mcp-setup
Last updated: 2026-09-14

`stringlane mcp` is a server, not a command you run by hand:

```sh
stringlane mcp /path/to/your/project
```

It speaks the Model Context Protocol over stdin and stdout and stays running until the agent disconnects. Your host starts it for you, using the configuration below.

**Eight hosts are known by name**, and each has its own install shape: see [Agent hosts](/docs/cli/agent-hosts) for the table, or hand [the setup page](/docs/cli/agent-setup) to your agent and let it do this. This page is the host-neutral mechanics underneath both.

## Get the configuration

```sh
stringlane setup mcp --host cursor
```

`--host` takes `claude-code`, `codex`, `vscode`, `gemini-cli`, `cursor`, `windsurf`, `zed` or `opencode`. It prints the entry and the exact file it would go in, and writes nothing. Add `--scope project` for the committed, per-repository entry where the host has one.

`--apply` turns the print into a write, and today it does that for `claude-code` only. On the other seven it prints and exits non-zero: StringLane will not merge into a config file for a host nobody has recorded, and the exit code is the command telling you it changed nothing.

Underneath, the entry is a command and its arguments:

```json
{
  "command": "stringlane",
  "args": ["mcp", "."]
}
```

**What differs between hosts is the container key, and it matters more than it looks.** These eight hosts want that entry under four different keys — `mcpServers`, `servers`, `context_servers`, and a TOML `[mcp_servers.stringlane]` table — and one under the wrong key is not an error on any of them. The host starts, lists no StringLane tools, and says nothing about why. That is the failure `setup mcp --host` exists to prevent, so prefer it to hand-writing the entry even when you are going to paste it yourself.

VS Code is the exception to the whole shape: it stores user-profile MCP servers where it does not document, so `setup mcp --host vscode` prints `code --add-mcp '…'` instead of a file.

## Why the arguments are `mcp .`

The `.` means "the project this host has open", so **one entry covers every StringLane project on the machine**. You configure it once rather than per repository.

The consequence is worth knowing: the project is fixed when the server starts. No tool takes a file path, so there is nothing an agent can point at a directory you did not open, and switching projects means the host starts a fresh server.

## Requirements

`stringlane` has to be on the `PATH` of whatever process starts the server. If your host launches from a GUI rather than your shell, it may not inherit the `PATH` you see in a terminal. Two ways through:

- install the CLI globally (`npm install -g @stringlane/cli`) so it lands in a location the system search path already covers;
- or give the absolute path as `command`, which you can find with `which stringlane` (`where stringlane` on Windows).

## Project scope, for a team

If your host reads a configuration file from the repository, commit the entry there instead of putting it in your user settings. Everyone who clones the repository is then offered the server, and each of them needs `stringlane` on their own `PATH` for it to start.

## Check it connected

Restart the agent. The tools appear as ten, named `inspect_project`, `read_translations`, `prepare_translation_plan`, `validate_translations`, `read_key_usage`, `describe_keys`, `apply_translations`, `add_locale`, `add_key` and `set_project_context`. If your host has a way to list a server's tools, that count is the quickest confirmation.

Then ask the agent something only the server can answer, such as which locales the project has and what is missing. If it answers from reading files itself rather than from `inspect_project`, the server is not connected.

Full arguments and behaviour per tool: the [MCP tool reference](/docs/reference/mcp-tools). Troubleshooting a server that will not start: [Troubleshooting](/docs/cli/troubleshooting).

## What this does not give you

**The MCP entry is not the write guard.** The guard is a *hook*, not an MCP capability, and the distinction is structural rather than a packaging choice: no MCP server can see an edit that did not go through its own tools. An agent that decides to hand-edit `de.arb` with its file-writing tool is, as far as this server is concerned, not there.

So the tools configured on this page are safe, and the surrounding session is as safe as your host's own interception makes it. Seven of the eight hosts have some form of it, and it is a separate command:

```sh
stringlane setup hooks --host <host>      # or setup guard, on Zed and OpenCode
```

What each host can actually run differs, including one where the answer is none: [Agent hosts](/docs/cli/agent-hosts).

## Frequently asked questions

### How do I add StringLane to an MCP host other than Claude Code?

Run stringlane setup mcp --host <host> without --apply. It prints the entry in that host's own shape and names the exact file it belongs in. Eight hosts are known by name: claude-code, codex, vscode, gemini-cli, cursor, windsurf, zed and opencode. For anything else, take the nearest entry and put it where that host keeps its MCP servers.

### Does the MCP server send my strings anywhere?

No. It runs on your machine and talks over stdin and stdout to the agent that started it. Your strings reach that agent and nothing else, and the server itself contacts no network service.
