Datomic MCP server

Provides a JSON-RPC interface to Datomic databases, enabling schema exploration, Datalog query execution, and raw index access for data analysis without context switching.
Back to servers
Setup instructions
Provider
theronic
Release date
Mar 16, 2025
Stats
22 stars

This MCP server provides Datomic database functionality through a Model Context Protocol implementation, allowing Claude Desktop to interact with Datomic databases. It's built with Modex and supports various Datomic API functions.

Installation

To use the Datomic MCP server with Claude Desktop, follow these steps:

  1. Download the uberjar from the project repository
  2. Configure your Claude Desktop to use the MCP server

Configure Claude Desktop

Add the following configuration to your Claude Desktop settings:

{
  "mcpServers": {
    "modex-datomic-mcp": {
      "command": "java",
      "args": ["-jar", "/path/to/theronic-datomic-mcp-0.3.0.jar"],
      "env": {"DATOMIC_URI": "your-datomic-uri-here"}
    }
  },
  "globalShortcut": ""
}

Make sure to:

  • Replace /path/to/theronic-datomic-mcp-0.3.0.jar with the actual path to the jar file
  • Set your Datomic URI in the DATOMIC_URI environment variable

Supported Functionality

The MCP server currently supports the following Datomic API operations:

Queries and Data Access

  • Concurrent queries with async message handling
  • datomic.api/q - Datalog queries
  • datomic.api/datoms - Access to raw datoms
  • datomic.api/with (via q-with tool)
  • datomic.api/pull - Pull query API
  • datomic.api/pull-many - Multiple entity pull queries
  • datomic.api/entity - Entity API access
  • datomic.api/touch - Load entity attributes
  • datomic.api/entid - Entity ID resolution

Usage Examples

Once configured, you can interact with your Datomic database through Claude Desktop using the supported API functions. The exact usage will depend on your specific use case and database schema.

Limitations

Currently, the server does not support:

  • datomic.api/transact (transaction operations)
  • Progress messages for connection status
  • Advanced cursor-based pagination
  • Stable db basis (each query runs with a fresh (d/db conn))
  • d/as-of historical database views

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "modex-datomic-mcp" '{"command":"java","args":["-jar","/Users/petrus/code/datomic-mcp/target/theronic-datomic-mcp-0.3.0.jar"],"env":{"DATOMIC_URI":"<your datomic URI here>"}}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "modex-datomic-mcp": {
            "command": "java",
            "args": [
                "-jar",
                "/Users/petrus/code/datomic-mcp/target/theronic-datomic-mcp-0.3.0.jar"
            ],
            "env": {
                "DATOMIC_URI": "<your datomic URI here>"
            }
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "modex-datomic-mcp": {
            "command": "java",
            "args": [
                "-jar",
                "/Users/petrus/code/datomic-mcp/target/theronic-datomic-mcp-0.3.0.jar"
            ],
            "env": {
                "DATOMIC_URI": "<your datomic URI here>"
            }
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later