lawmatics-mcp

v1.0.0
io.github.oktopeak/lawmatics-mcp Checked 3 days ago Published 3 months ago

Connect Claude to Lawmatics: matters, contacts, pipelines, tasks, forms, custom fields, invoices.

Values you need

VariableWhat it is
LAWMATICS_ACCESS_TOKENrequired secret Lawmatics OAuth access token (never expires). Obtain once with `npx @oktopeak/lawmatics-mcp auth`.
LAWMATICS_READ_ONLYoptional Set to '1' to disable all write tools (create/update/tag/submit). Read-only mode for cautious firms.
LAWMATICS_EXPERIMENTAL_TOOLSoptional Set to '1' to enable experimental tools (set-matter-custom-fields) whose API request shape is not fully documented by Lawmatics.
LAWMATICS_RATE_LIMIT_PER_MINoptional Client-side request throttle per minute (default: 50, the conservative documented per-firm limit; newer docs say 150).
LAWMATICS_AUDIT_LOGoptional Set to '0' to disable the local JSONL audit log (default path: ~/.lawmatics-mcp/audit.log).
LAWMATICS_AUDIT_LOG_PATHoptional Override the audit log file location (default: ~/.lawmatics-mcp/audit.log). The log contains tool arguments, which can include client data.
LAWMATICS_CLIENT_IDoptional Only needed for the one-time `auth` command: your Lawmatics developer app client ID.
LAWMATICS_CLIENT_SECREToptional secret Only needed for the one-time `auth` command: your Lawmatics developer app client secret.
LAWMATICS_REDIRECT_PORToptional Local port for the one-time OAuth callback (default: 5678). Must match the app's Callback URL.
LAWMATICS_API_BASEoptional Override the Lawmatics API base URL (default: https://api.lawmatics.com/v1).

npm (npx) discovery passed

Requires Node.js 18+

Run in a terminal
claude mcp add lawmatics-mcp -e 'LAWMATICS_ACCESS_TOKEN=<LAWMATICS_ACCESS_TOKEN>' -- npx -y @oktopeak/lawmatics-mcp@1.0.0
Add to claude_desktop_config.json
{
  "mcpServers": {
    "lawmatics-mcp": {
      "args": [
        "-y",
        "@oktopeak/lawmatics-mcp@1.0.0"
      ],
      "command": "npx",
      "env": {
        "LAWMATICS_ACCESS_TOKEN": "<LAWMATICS_ACCESS_TOKEN>"
      }
    }
  }
}
Add to ~/.cursor/mcp.json
{
  "mcpServers": {
    "lawmatics-mcp": {
      "args": [
        "-y",
        "@oktopeak/lawmatics-mcp@1.0.0"
      ],
      "command": "npx",
      "env": {
        "LAWMATICS_ACCESS_TOKEN": "<LAWMATICS_ACCESS_TOKEN>"
      }
    }
  }
}
Add to .vscode/mcp.json
{
  "inputs": [
    {
      "description": "LAWMATICS_ACCESS_TOKEN",
      "id": "lawmatics-access-token",
      "password": true,
      "type": "promptString"
    }
  ],
  "servers": {
    "lawmatics-mcp": {
      "args": [
        "-y",
        "@oktopeak/lawmatics-mcp@1.0.0"
      ],
      "command": "npx",
      "env": {
        "LAWMATICS_ACCESS_TOKEN": "${input:lawmatics-access-token}"
      },
      "type": "stdio"
    }
  }
}
Add to ~/.codex/config.toml
[mcp_servers.lawmatics-mcp]
command = "npx"
args = ["-y", "@oktopeak/lawmatics-mcp@1.0.0"]
env = { "LAWMATICS_ACCESS_TOKEN" = "<LAWMATICS_ACCESS_TOKEN>" }

For AI agents

  1. Ask the user for: LAWMATICS_ACCESS_TOKEN. Never invent or guess these values; secrets go into the client config, not into chat logs.
  2. Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
  3. Restart or reload the client so it starts the server.
  4. Verify: the server should expose these tools: list-matters, get-matter, find-matter, create-matter, update-matter, list-contacts, get-contact, find-contact, ….
  5. If it fails, check that the required runtime is installed (Node.js 18+) and that the values above are set.

Machine-readable: install.md · manifest.json