JohanCodinha_nrepl-mcp-server

MCP-Mirror/JohanCodinha_nrepl-mcp-server

3.2

If you are the rightful owner of JohanCodinha_nrepl-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

A Model Context Protocol (MCP) server designed for MCP clients, such as Claude Desktop or CLine in VSCode, enabling interaction with a running Clojure nREPL instance.

Tools

Functions exposed to the LLM to take actions

connect

Connect to an nREPL server. Example: (connect {:host "localhost" :port 1234})

eval_form

Evaluate Clojure code in a specific namespace or the current one. Examples:

  • Get current namespace: (eval_form {:code "(str ns)"})
  • Change namespace: (eval_form {:code "(+ 1 2)" :ns "my.namespace"})
  • Load a file: (eval_form {:code "(load-file "src/my_file.clj")"})
  • Define and call functions: (eval_form {:code "(defn add [a b] (+ a b))" :ns "math"} then (eval_form {:code "(add 1 2)" :ns "math"})

get_ns_vars

Get all public vars (functions, values) in a namespace with their metadata and current values. Example:

  • List main namespace vars: (get_ns_vars {:ns "main"}) Returns a map where keys are var names and values contain:
  • :meta - Metadata including :doc string, :line number, :file path
  • :value - Current value of the var

Prompts

Interactive templates invoked by user choice

No prompts

Resources

Contextual data attached and managed by the client

nREPL Connection Status

URI: nrepl://status

MIME: application/json

Returns the current nREPL connection status including port and session information

Project Namespaces

URI: nrepl://namespaces

MIME: application/json

Returns a list of all namespaces in the current project