What is MCP?

The Model Context Protocol (MCP) is an open standard for connecting AI models to external tools and data sources. OpenAnalyst CLI includes a full MCP client that can connect to any MCP-compliant server.

MCP tools appear alongside the 19 built-in tools and are invoked the same way by the agent.

Supported Transports

TransportDescriptionUse Case
stdioStandard input/outputLocal processes, npm packages
sseServer-Sent Events over HTTPRemote servers, cloud services
websocketWebSocket connectionBidirectional real-time
httpHTTP request/responseREST API wrappers
sdkDirect SDK integrationIn-process tools
managed-proxyManaged proxy connectionEnterprise environments

Configuring MCP Servers

Via Settings File

.openanalyst/settings.json
{
  "mcp": {
    "servers": {
      "filesystem": {
        "transport": "stdio",
        "command": "npx",
        "args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/dir"]
      },
      "github": {
        "transport": "stdio",
        "command": "npx",
        "args": ["-y", "@modelcontextprotocol/server-github"],
        "env": {
          "GITHUB_TOKEN": "ghp_..."
        }
      },
      "remote-api": {
        "transport": "sse",
        "url": "https://mcp.example.com/sse"
      }
    }
  }
}

Via Slash Command

# List connected MCP servers
/mcp

# Add a new MCP server
/mcp add my-server stdio npx -y @my/mcp-server

# Remove a server
/mcp remove my-server

How It Works

Bootstrap

At startup, OpenAnalyst reads MCP server configs from settings and connects to each server. For stdio servers, it spawns the process. For network servers, it establishes the connection.

Tool Discovery

The MCP client sends a tools/list request via JSON-RPC. The server responds with its available tools, including names, descriptions, and parameter schemas.

Tool Registration

Discovered tools are registered alongside the 19 built-in tools. They appear in the agent's tool list and can be invoked like any other tool.

Invocation

When the agent calls an MCP tool, the request is routed through the MCP client to the appropriate server. Results are streamed back to the agent.

Popular MCP Servers

Filesystem

Read, write, and search files with controlled access to specific directories.

@modelcontextprotocol/server-filesystem

GitHub

Create issues, PRs, search repos, manage branches via GitHub API.

@modelcontextprotocol/server-github

PostgreSQL

Query databases, inspect schemas, run migrations.

@modelcontextprotocol/server-postgres

Slack

Read channels, post messages, search conversations.

@modelcontextprotocol/server-slack

MCP Resources

In addition to tools, MCP servers can expose resources — contextual data that the agent can read. Resources might include database schemas, API documentation, or project metadata.

Protocol
MCP uses JSON-RPC 2.0 over the configured transport. See the MCP specification for full protocol details.