Guides

MCP Servers

Connect external tools, databases, and APIs through the Model Context Protocol.

What is MCP?

The Model Context Protocol (MCP) is an open standard that lets AI assistants connect to external tools and data sources. MCP servers expose tools, resources, and prompts that QCoder's AI can use during conversations.

Examples of what MCP servers can provide: - Database access -- Query PostgreSQL, MySQL, or SQLite databases directly from chat. - API integrations -- Interact with GitHub, Jira, Slack, or any REST API. - File system tools -- Access remote file systems or cloud storage. - Custom tools -- Any tool you build and expose through the MCP protocol.

Configuration

MCP servers can be configured in two ways:

Via Settings UI: 1. Open Settings > MCP Servers tab. 2. Click Add Server. 3. Enter the server name, transport type, and connection details. 4. Click Save.

Via configuration file: Create or edit .kiro/settings/mcp.json in your workspace root:

json{
  "mcpServers": {
    "postgres": {
      "transport": "stdio",
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-postgres"],
      "env": {
        "POSTGRES_CONNECTION_STRING": "postgresql://user:pass@localhost:5432/mydb"
      }
    },
    "github": {
      "transport": "stdio",
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-github"],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "ghp_..."
      }
    }
  }
}

Changes to the configuration file are picked up automatically -- no restart required.

Transport Types

MCP supports three transport types:

TransportHow it WorksWhen to Use
---------
stdioQCoder spawns a local process and communicates over stdin/stdout.Local tools, CLI wrappers, most common.
SSEQCoder connects to an HTTP server that streams events via Server-Sent Events.Remote servers, shared team tools.
streamableHttpQCoder connects to an HTTP endpoint that supports bidirectional streaming.Modern remote servers, high-throughput tools.

stdio is the most common transport and is used by the majority of MCP servers in the ecosystem. The command field specifies the executable, and args provides the arguments. Environment variables can be passed via the env field.

Server Management UI

The MCP Servers section in Settings provides a management interface for all configured servers:

  • Status dots -- Green means connected and healthy, yellow means connecting, red means disconnected or errored.
  • Transport badges -- Each server shows its transport type (stdio, SSE, or streamableHttp).
  • Enable/disable toggle -- Temporarily disable a server without removing its configuration.
  • Add/Remove -- Add new servers or remove existing ones.
  • Reconnect -- If a server disconnects, click the reconnect button to re-establish the connection.

When a server connects, its tools appear in the AI's tool list automatically. You can see which MCP tools are available by checking the tool list in Agent mode.