Skip to main content

StdioTransportConfig

Configuration for the STDIO (Standard Input/Output) transport. Accepts either a boolean or an object.

Boolean Mode

stdio
boolean
default:"undefined"
  • true - Enable STDIO transport with defaults
  • false - Disable STDIO transport
  • undefined - Transport is disabled

Object Mode

debug
boolean
default:"false"
Enable debug logging for the STDIO transport. When enabled, debug messages will be written to stderr.

Examples

Minimal Configuration

export default {
  stdio: true, // Enable with defaults
};

With Debug Logging

export default {
  stdio: {
    debug: true,
  },
};

Disable STDIO

export default {
  stdio: false,
};

Combined Transports

export default {
  stdio: true,
  http: {
    port: 3001,
  },
};

Usage

The STDIO transport is commonly used when running your MCP server as a subprocess. It communicates via standard input and output streams, making it ideal for:
  • CLI tools that integrate with MCP
  • Process-based MCP server execution
  • Development and testing workflows
  • Integration with tools that spawn processes
When debug mode is enabled, debug messages are written to stderr to avoid interfering with the STDIO communication protocol on stdout.

Build docs developers (and LLMs) love