Fire in da houseTop Tip:Paying $100+ per month for Perplexity, MidJourney, Runway, ChatGPT and other tools is crazy - get all your AI tools in one site starting at $15 per month with Galaxy AI Fire in da houseCheck it out free

mcp-clj

MCP.Pizza Chef: hugoduncan

mcp-clj is a Clojure-based MCP server implementation that exposes Clojure REPL functionality via Server-Sent Events (SSE). It supports Anthropic's MCP specification, providing a reliable and simple way to integrate Clojure environments with LLMs through real-time protocol communication. This server enables developers to interact with Clojure REPLs programmatically within AI workflows.

Use This MCP server To

Expose Clojure REPL for real-time interaction with LLMs Integrate Clojure environments into AI-driven workflows Enable remote REPL access over SSE for Clojure applications Facilitate protocol-compliant MCP communication in Clojure projects Support multi-step reasoning by feeding REPL context to models

README

mcp-clj

An implementation of the Model-Channel Protocol (MCP) in Clojure, designed to expose Clojure REPL functionality over an SSE transport.

Project Description

mcp-clj is a Clojure implementation of the Model-Channel Protocol (MCP) defined by Anthropic. It provides both client and server components for MCP communication, with a specific focus on exposing Clojure REPL functionality. The project aims to maintain compatibility with Anthropic's MCP specification while providing a simple and reliable implementation.

Usage

Add mcp-clj as a dependency to your project.

  1. Add the mcp-project as a dependency:
:deps {org.hugoduncan/mcp-clj
        {:git/url   "https://github.com/hugoduncan/mcp-clj"
         :git/sha   "replace with latest git sha"
         :deps/root "projects/server"}}
  1. In the project, start the server:
(require 'mcp-clj.mcp-server.core)
(def server (mcp-clj.mcp-server.core/create-server {:port 3001}))

This will start the server on port 3001. You can then connect to the server using an MCP client.

Configuration

Configuring Claude Desktop

To configure Claude Desktop to use mcp-clj, you need to use mcp-proxy.

In claude_desktop_config.json, add:

    "mcp-proxy": {
      "command": "mcp-proxy",
      "args": [
        "http://localhost:3001/sse"
      ],
      "env": {
        "API_ACCESS_TOKEN": "ABC"
      }
    }

Contributing

Contributions to mcp-clj are welcome! Please follow these steps to contribute:

  1. Fork the repository.
  2. Create a new branch for your feature or bugfix.
  3. Make your changes and ensure all tests pass.
  4. Submit a pull request with a detailed description of your changes.

License

mcp-clj is licensed under the MIT License. See the LICENSE file for more details.

mcp-clj FAQ

How do I start the mcp-clj server?
Add mcp-clj as a dependency and call create-server with a port, e.g., 3001.
What transport protocol does mcp-clj use?
It uses Server-Sent Events (SSE) to expose the Clojure REPL functionality.
Is mcp-clj compatible with Anthropic's MCP specification?
Yes, it maintains compatibility with Anthropic's MCP protocol.
Can mcp-clj be used to expose other Clojure functionality besides REPL?
Primarily designed for REPL exposure, but can be extended for other Clojure interactions.
How do I add mcp-clj to my Clojure project?
Add it as a dependency via your deps.edn or project.clj with the provided GitHub URL.
Does mcp-clj support secure communication?
Security depends on your deployment environment; mcp-clj itself focuses on protocol implementation.
Can mcp-clj work with LLM providers like OpenAI, Claude, or Gemini?
Yes, it can integrate with any LLM supporting MCP, including OpenAI, Claude, and Gemini.