STDIO Mode
7 min
stdio mode runs the litmus mcp server as a local child process of an mcp client it is the only way to use claude desktop (which does not speak sse) and is convenient for local development stdio mode is not available from the published docker image you need to clone the repository and run the python process directly 1\ clone git clone https //github com/litmusautomation/litmus mcp server git cd litmus mcp server 2\ enable stdio edit src/config py so that enable stdio = os getenv("enable stdio", "true") lower() in ("true", "1", "yes") defaulting to true means the server runs in stdio mode unless enable stdio=false is passed at launch 3\ install dependencies using uv uv sync using pip in a venv python m venv venv venv/bin/activate pip install e 4\ run the server \# uv uv run python3 src/server py \# plain python python3 src/server py you should see starting litmus mcp server in stdio mode in the log the process now waits for an mcp client on stdin / stdout 5\ wire it into an mcp client for claude desktop, see claude desktop # for any other stdio capable mcp client, the pattern is { "mcpservers" { "litmus mcp server" { "command" "/path/to/ venv/bin/python3", "args" \[ "/absolute/path/to/litmus mcp server/src/server py" ], "env" { "pythonpath" "/absolute/path/to/litmus mcp server/src", "edge url" "https //\<litmusedge ip>", "edge api client id" "\<oauth2 client id>", "edge api client secret" "\<oauth2 client secret>", "nats source" "\<litmusedge ip>", "nats port" "4222", "nats user" "\<access token username>", "nats password" "\<access token from litmusedge>", "influx host" "\<litmusedge ip>", "influx port" "8086", "influx db name" "tsdata", "influx username" "\<datahub username>", "influx password" "\<datahub password>" } } } } stdio mode reads the same credentials as sse mode, but from process environment variables instead of http headers see headers reference # for what each one does notes for dev work that bridges differing mcp library versions (e g , npx @modelcontextprotocol/inspector vs litmus mcp server ), point command at the project's venv python so you don't pick up system wide mcp installs see claude desktop config venv example json in the repo for a ready to edit template only one mcp client can attach to a given stdio server process at a time for shared or multi user setups, use docker sse mode instead see docker #