drio
Open app

Basilisp nREPL MCP Bridge

Source

simple MCP server for nREPL

Catalog onlyCatalog onlySTDIO

Overview

Basilisp nREPL MCP Bridge is a project that provides a bridge between Anthropic's Model Control Protocol (MCP) and Basilisp's nREPL server, enabling Claude Code to interact directly with a Basilisp REPL.

To use the bridge, start a Basilisp nREPL server, add the MCP bridge to Claude Code, and then connect to use the available tools for code evaluation and documentation retrieval.

  • Execute code with pretty-printed, syntax-highlighted results - Retrieve documentation for symbols - List all available namespaces - Find all variables in a namespace - Check nREPL server connectivity - Enhanced error reporting and formatting
  1. Interacting with Basilisp REPL for code execution
  2. Accessing documentation for programming symbols
  3. Managing namespaces and variables in a coding environment

Add to your AI client

Use these steps to connect Basilisp nREPL MCP Bridge in Cursor, Claude, VS Code, and other MCP-compatible apps. The same JSON appears in the Use with menu above for one-click copy.

Cursor

Add this to your .cursor/mcp.json file in your project root, then restart Cursor.

.cursor/mcp.json

{
  "mcpServers": {
    "nrepl-mcp-cat-state": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-nrepl-mcp-cat-state"
      ]
    }
  }
}

Claude Desktop

Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.

~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows)

{
  "mcpServers": {
    "nrepl-mcp-cat-state": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-nrepl-mcp-cat-state"
      ]
    }
  }
}

Claude Code

Add this to your project's .mcp.json file. Claude Code will detect it automatically.

.mcp.json (project root)

{
  "mcpServers": {
    "nrepl-mcp-cat-state": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-nrepl-mcp-cat-state"
      ]
    }
  }
}

VS Code (Copilot)

Add this to your .vscode/mcp.json file. Requires the GitHub Copilot extension with MCP support enabled.

.vscode/mcp.json

{
  "servers": {
    "nrepl-mcp-cat-state": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-nrepl-mcp-cat-state"
      ]
    }
  }
}

Windsurf

Add this to your Windsurf MCP config file, then restart Windsurf.

~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "nrepl-mcp-cat-state": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-nrepl-mcp-cat-state"
      ]
    }
  }
}

Cline

Open Cline settings, navigate to MCP Servers, and add this server configuration.

Cline MCP Settings (via UI)

{
  "mcpServers": {
    "nrepl-mcp-cat-state": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-nrepl-mcp-cat-state"
      ]
    }
  }
}

FAQ

What is required to run the bridge?

You need to have the `uv` library and Basilisp installed.

Can it work with any nREPL?

Yes, while it is currently focused on Basilisp, it should work with any nREPL.

What are the future improvements planned?

Future improvements include implementing a proper bencode parser, session management for multiple REPLs, and auto-completion support.7:["$","div",null,{"className":"container mx-auto flex flex-col gap-4","children":["$L26","$L27",["$","$L28",null,{"currentProject":{"id":2188,"uuid":"ca7e1963-61f1-4878-ad55-99a957a461cc","name":"nrepl-mcp","title":"Basilisp nREPL MCP Bridge","description":"simple MCP server for nREPL","avatar_url":"https://avatars.githubusercontent.com/u/98283595?v=4","created_at":"2025-03-09T04:00:00.579Z","updated_at":"2025-03-12T10:19:30.842Z","status":"created","author_name":"cat-state","author_avatar_url":"https://avatars.githubusercontent.com/u/98283595?v=4","tags":"[]","category":"developer-tools","is_featured":false,"sort":1,"url":"https://github.com/cat-state/nrepl-mcp","target":"_self","content":"$29","summary":"$2a","img_url":null,"type":null,"metadata":"{\"star\":\"0\",\"license\":\"\",\"language\":\"Python\",\"is_official\":false,\"latest_commit_time\":\"2025-03-07 21:53:06\"}","user_uuid":null,"tools":null,"sse_url":null,"sse_provider":null,"sse_params":null,"is_official":false,"server_command":null,"server_params":null,"server_config":null,"allow_call":false,"is_innovation":false,"is_dxt":false,"dxt_manifest":null,"dxt_file_url":null,"is_audit":false},"randomProjects":[],"currentServerKey":"$undefined"}]]}]