Skip to content

IDE Integration

AgentCTX integrates with code editors through the Model Context Protocol (MCP). This gives your AI coding assistants direct access to CTX operations — memory, knowledge search, tool routing, and trust verification.

Add AgentCTX as an MCP server in your editor’s MCP settings:

{
"mcpServers": {
"agentctx": {
"command": "actx",
"args": ["start", "--protocol", "stdio"],
"cwd": "${workspaceFolder}"
}
}
}

Once connected, AI assistants in your IDE can:

OperationCTXWhat It Does
Search tools?t githubDiscover available MCP tools
Call tools>t github.issues.create title="Fix"Execute tools through the gateway
Search knowledge?k "auth" #code ^3Find relevant documentation
Store decisions+m "choice" #arch "Rationale"Persist architectural decisions
Verify actionsactx verifyAudit agent operations

The --protocol stdio flag enables the structured extension protocol, which uses newline-delimited JSON messages:

  • ClientMessage — sent by the editor (CTX operations, configuration)
  • ServerMessage — sent by AgentCTX (results, events, diagnostics)

This is different from raw MCP stdio transport — it adds IDE-specific message types for editor integration.

Any editor or tool that supports MCP can connect to AgentCTX:

  1. Point the MCP server config to actx start
  2. Use stdio transport (default)
  3. The actx tool (~300 tokens) appears as a single callable

If your team runs AgentCTX via Docker Compose, configure the editor to connect to the SSE endpoint:

{
"mcpServers": {
"agentctx": {
"url": "http://localhost:3100",
"transport": "sse"
}
}
}