Connect an MCP client
Same endpoint for all clients. JSON shape differs slightly for VS Code.
Keep onlinesim mcp running while the client is connected.
Auto-wire (recommended)
Write the HTTP endpoint into IDE config files. Does not start the MCP server.
Bash
onlinesim mcp install
onlinesim mcp install --client cursor --global
onlinesim mcp install --client vscode --project
onlinesim mcp install --client claude --project
onlinesim mcp install --client all --project
onlinesim mcp install --client codex --globalFlags: --dir <project>, --url <endpoint>, --force (overwrite existing onlinesim entry).
Cursor
Put this JSON in a Cursor mcp.json file:
~/.cursor/mcp.json— global (all projects).cursor/mcp.json— this project
JSON
{
"mcpServers": {
"onlinesim": {
"type": "http",
"url": "http://127.0.0.1:8787/mcp"
}
}
}Claude Code
Claude Code CLI scopes:
Bash
claude mcp add --scope user --transport http onlinesim http://127.0.0.1:8787/mcp
claude mcp add --scope project --transport http onlinesim http://127.0.0.1:8787/mcpOr use a project file (same JSON as Cursor): .mcp.json
VS Code
Project file .vscode/mcp.json — key is servers (not mcpServers):
JSON
{
"servers": {
"onlinesim": {
"type": "http",
"url": "http://127.0.0.1:8787/mcp"
}
}
}Codex
Bash
codex mcp add onlinesim --url http://127.0.0.1:8787/mcpOr set url under [mcp_servers.onlinesim] in ~/.codex/config.toml.
Claude Desktop
Local HTTP needs a bridge:
Bash
npx -y mcp-remote http://127.0.0.1:8787/mcp --transport http-only