npm package: @minns/openclaw-minns
Description: MCP stdio server integrating Minns EventGraphDB into OpenClaw
Latest version: 0.7.2

# @minns/openclaw-minns

MCP stdio server that connects [OpenClaw](https://github.com/anthropics/openclaw) to [Minns EventGraphDB](https://github.com/minns/minns-sdk) for persistent agent memory, strategy recall, and claim search.

## Install

```bash
npm i @minns/openclaw-minns
```

Or clone and build locally:

```bash
cd openclaw-minns
npm install
npm run build
```

## Configure OpenClaw

Add the MCP server entry to your OpenClaw config (typically `~/.config/openclaw/config.json` or the `mcpServers` section of your project settings):

```json
{
  "mcpServers": {
    "minns": {
      "command": "openclaw-minns-mcp",
      "env": {
        "MINNS_API_KEY": "your-secret-key",
        "MINNS_DEBUG": "false"
      }
    }
  }
}
```

## Environment variables

| Variable        | Default  | Description                                    |
| --------------- | -------- | ---------------------------------------------- |
| `MINNS_API_KEY` | *(none)* | Bearer token for authenticated access          |
| `MINNS_DEBUG`   | `false`  | Set to `true` for verbose stderr logging       |

> **Note:** The base URL (`https://minns.ai`) is fixed and cannot be overridden.

## Available tools

| Tool                           | Description                                          |
| ------------------------------ | ---------------------------------------------------- |
| `memory.search`                | Semantic search over memories                        |
| `memory.capture`               | Store a new memory (context event with embeddings)   |
| `memory.memories`              | List agent memories by strength                      |
| `memory.strategies`            | List agent strategies by quality                     |
| `strategy.similar`             | Find strategies matching a signature                 |
| `strategy.suggest_next_action` | Get next-action suggestions for a context            |
| `claims.search`                | Search extracted claims semantically                 |
| `stats.get`                    | System-wide EventGraphDB statistics                  |
| `health.check`                 | Verify EventGraphDB is reachable                     |

## Test locally

Start EventGraphDB, then run the binary directly. It speaks JSON-RPC 2.0 over stdio:

```bash
# Start the MCP server
MINNS_API_KEY=your-secret-key npx openclaw-minns-mcp
```

In another terminal, pipe a JSON-RPC request to test:

```bash
echo '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}' | npx openclaw-minns-mcp
```

To call a tool:

```bash
echo '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"health.check","arguments":{}}}' | npx openclaw-minns-mcp
```

Memory search example:

```bash
echo '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"memory.search","arguments":{"query":"user preferences","limit":5}}}' | npx openclaw-minns-mcp
```

## Fallback skill

If your agent runtime does not support MCP natively, copy `skills/minns-memory/SKILL.md` into your agent's skill/policy directory. It instructs the agent to call `memory.search` before answering and `memory.capture` after answering, with safety rules to avoid storing secrets.

## License

MIT