Skip to content

MCP Configuration

The ContextKit MCP server can be configured for any MCP-compatible client. Below are setup instructions for the most common tools.

Claude Code uses a .claude/mcp.json file in your project root for MCP server configuration. The stdio transport runs the server as a child process.

.claude/mcp.json
{
"mcpServers": {
"contextkit": {
"command": "npx",
"args": ["@runcontext/cli", "serve"],
"cwd": "/path/to/your/project"
}
}
}

For shared or remote setups, start the server in HTTP mode and point clients at the SSE endpoint.

Start the server:

Terminal window
npx @runcontext/cli serve --http --port 3000

Client configuration (generic):

{
"mcpServers": {
"contextkit": {
"url": "http://localhost:3000/mcp"
}
}
}

Cursor reads MCP configuration from its settings. Add the ContextKit server under the MCP section.

.cursor/mcp.json
{
"mcpServers": {
"contextkit": {
"command": "npx",
"args": ["@runcontext/cli", "serve"],
"cwd": "/path/to/your/project"
}
}
}

Once configured, your AI tool should discover the ContextKit resources and tools automatically. You can verify by asking the agent:

“What MCP resources are available?”

It should list the context:// resources. You can also test a tool call:

“Search my semantic layer for revenue metrics.”

The agent should call context_search and return results from your context directory.

The serve command accepts the following flags:

FlagDescriptionDefault
--httpUse HTTP transport (default is stdio)Off
--port <number>Port for HTTP server3000
--host <address>Host address to bind0.0.0.0
--context-dir <path>Path to context files./context