# Clicks Protocol MCP server

> Enables AI agents to perform commerce settlement routing, receipt verification, and transaction inspection on the Base network.

- Repository: https://github.com/clicks-protocol/clicks-protocol
- Page: https://hostedmcp.org/servers/clicks-protocol/mcp-server
- Transport: stdio
- Stars: 2
- License: MIT
- Latest version: 1.0.3

## Install

### Claude Code

```sh
claude mcp add --env 'CLICKS_PRIVATE_KEY=<YOUR_CLICKS_PRIVATE_KEY>' mcp-server -- npx -y @clicks-protocol/mcp-server
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@clicks-protocol/mcp-server"
      ],
      "env": {
        "CLICKS_PRIVATE_KEY": "<YOUR_CLICKS_PRIVATE_KEY>"
      }
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "mcp-server": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@clicks-protocol/mcp-server"
      ],
      "env": {
        "CLICKS_PRIVATE_KEY": "<YOUR_CLICKS_PRIVATE_KEY>"
      }
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"mcp-server","type":"stdio","command":"npx","args":["-y","@clicks-protocol/mcp-server"],"env":{"CLICKS_PRIVATE_KEY":"<YOUR_CLICKS_PRIVATE_KEY>"}}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@clicks-protocol/mcp-server"
      ],
      "env": {
        "CLICKS_PRIVATE_KEY": "<YOUR_CLICKS_PRIVATE_KEY>"
      }
    }
  }
}
```

### Codex

```sh
codex mcp add mcp-server --env 'CLICKS_PRIVATE_KEY=<YOUR_CLICKS_PRIVATE_KEY>' -- npx -y @clicks-protocol/mcp-server
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.mcp-server]
command = "npx"
args = ["-y", "@clicks-protocol/mcp-server"]

[mcp_servers.mcp-server.env]
CLICKS_PRIVATE_KEY = "<YOUR_CLICKS_PRIVATE_KEY>"
```

### Gemini CLI

```sh
gemini mcp add -s user -e 'CLICKS_PRIVATE_KEY=<YOUR_CLICKS_PRIVATE_KEY>' mcp-server npx -- -y @clicks-protocol/mcp-server
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@clicks-protocol/mcp-server"
      ],
      "env": {
        "CLICKS_PRIVATE_KEY": "<YOUR_CLICKS_PRIVATE_KEY>"
      }
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `CLICKS_PRIVATE_KEY` | no | yes | Private key for write operations (register, deposit, withdraw). Not needed for read-only tools. |
| `CLICKS_RPC_URL` | no | no | Base RPC URL. Defaults to https://mainnet.base.org |

## Tools (5)

- `clicks_verify_receipt`
- `clicks_get_settlement_status`
- `clicks_reconcile_settlement`
- `clicks_replay_policy`
- `clicks_get_receipt_trail`

## FAQ

### Do I need a private key for all tools?

No, the Receipt V2 tools accept a complete receipt JSON object directly and do not require a private key.

### How can I use receipt-trail inspection?

You can enable receipt-trail inspection by setting the CLICKS_RECEIPT_LEDGER_PATH environment variable.

### What is the safety boundary for receipt hashes?

A receipt hash only proves object integrity; it does not guarantee delivery or commercial intent.

### Do write tools require authentication?

Yes, write tools require a CLICKS_PRIVATE_KEY and should be kept isolated from untrusted clients.
