M

Mandatia

by JC7333 · io.github.JC7333/mandatia

Enables AI agents and their deployers to register, verify, enforce, and audit legal mandates, with scoped permissions, delegation controls, signed action tokens, revocation, and a hash-chained journal for human oversight and record-keeping.

pypi Local · stdio GlamaOfficial MCP Registry High confidence

Install

Add to ~/Library/Application Support/Claude/claude_desktop_config.json

Windows / Linux path
Windows: %APPDATA%\Claude\claude_desktop_config.json
Linux: ~/.config/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "io-github-jc7333-mandatia": {
      "command": "uvx",
      "args": [
        "mandatia"
      ],
      "env": {
        "AMR_DB_PATH": "amr_mandates.db",
        "AMR_SIGNING_KEY_PATH": "<VALUE>",
        "AMR_PUBLIC_KEY_PATH": "amr_signing_key.pub",
        "AMR_LOG_LEVEL": "INFO",
        "AMR_ISSUE_TOKEN": "<VALUE>",
        "AMR_SERVER_NAME": "Agent Mandate Registry",
        "AMR_DID_WEB_RESOLVE": "<VALUE>",
        "AMR_ISSUE_REPOSITORY": "JC7333/amr",
        "AMR_PUBLIC_EXPORT_PATH": "amr_public_registry.jws",
        "AMR_TOKEN_LIFETIME_SECONDS": "300",
        "AMR_REQUIRE_PRINCIPAL_SIGNATURE": "false",
        "AMR_ATTESTATION_LIFETIME_SECONDS": "900",
        "AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS": "<VALUE>",
        "AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS": "900"
      }
    }
  }
}

Restart Claude Desktop to activate the new server.

Add to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)

Windows / Linux path
Windows: .cursor\mcp.json (project) or %USERPROFILE%\.cursor\mcp.json (global)
Linux: .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)
{
  "mcpServers": {
    "io-github-jc7333-mandatia": {
      "command": "uvx",
      "args": [
        "mandatia"
      ],
      "env": {
        "AMR_DB_PATH": "amr_mandates.db",
        "AMR_SIGNING_KEY_PATH": "<VALUE>",
        "AMR_PUBLIC_KEY_PATH": "amr_signing_key.pub",
        "AMR_LOG_LEVEL": "INFO",
        "AMR_ISSUE_TOKEN": "<VALUE>",
        "AMR_SERVER_NAME": "Agent Mandate Registry",
        "AMR_DID_WEB_RESOLVE": "<VALUE>",
        "AMR_ISSUE_REPOSITORY": "JC7333/amr",
        "AMR_PUBLIC_EXPORT_PATH": "amr_public_registry.jws",
        "AMR_TOKEN_LIFETIME_SECONDS": "300",
        "AMR_REQUIRE_PRINCIPAL_SIGNATURE": "false",
        "AMR_ATTESTATION_LIFETIME_SECONDS": "900",
        "AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS": "<VALUE>",
        "AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS": "900"
      }
    }
  }
}

Cursor usually picks up config changes automatically; if the server does not appear, reload the window.

Add to .mcp.json (project) or ~/.claude.json (global)

Windows / Linux path
Windows: .mcp.json (project) or %USERPROFILE%\.claude.json (global)
Linux: .mcp.json (project) or ~/.claude.json (global)
{
  "mcpServers": {
    "io-github-jc7333-mandatia": {
      "command": "uvx",
      "args": [
        "mandatia"
      ],
      "env": {
        "AMR_DB_PATH": "amr_mandates.db",
        "AMR_SIGNING_KEY_PATH": "<VALUE>",
        "AMR_PUBLIC_KEY_PATH": "amr_signing_key.pub",
        "AMR_LOG_LEVEL": "INFO",
        "AMR_ISSUE_TOKEN": "<VALUE>",
        "AMR_SERVER_NAME": "Agent Mandate Registry",
        "AMR_DID_WEB_RESOLVE": "<VALUE>",
        "AMR_ISSUE_REPOSITORY": "JC7333/amr",
        "AMR_PUBLIC_EXPORT_PATH": "amr_public_registry.jws",
        "AMR_TOKEN_LIFETIME_SECONDS": "300",
        "AMR_REQUIRE_PRINCIPAL_SIGNATURE": "false",
        "AMR_ATTESTATION_LIFETIME_SECONDS": "900",
        "AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS": "<VALUE>",
        "AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS": "900"
      }
    }
  }
}

The server will be available in the next Claude Code session.

Add to .vscode/mcp.json

Windows / Linux path
Windows: .vscode\mcp.json
Linux: .vscode/mcp.json
{
  "servers": {
    "io-github-jc7333-mandatia": {
      "command": "uvx",
      "args": [
        "mandatia"
      ],
      "env": {
        "AMR_DB_PATH": "amr_mandates.db",
        "AMR_SIGNING_KEY_PATH": "<VALUE>",
        "AMR_PUBLIC_KEY_PATH": "amr_signing_key.pub",
        "AMR_LOG_LEVEL": "INFO",
        "AMR_ISSUE_TOKEN": "<VALUE>",
        "AMR_SERVER_NAME": "Agent Mandate Registry",
        "AMR_DID_WEB_RESOLVE": "<VALUE>",
        "AMR_ISSUE_REPOSITORY": "JC7333/amr",
        "AMR_PUBLIC_EXPORT_PATH": "amr_public_registry.jws",
        "AMR_TOKEN_LIFETIME_SECONDS": "300",
        "AMR_REQUIRE_PRINCIPAL_SIGNATURE": "false",
        "AMR_ATTESTATION_LIFETIME_SECONDS": "900",
        "AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS": "<VALUE>",
        "AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS": "900"
      }
    }
  }
}

Reload the VS Code window to activate.

Add to ~/.codeium/windsurf/mcp_config.json

Windows / Linux path
Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
Linux: ~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "io-github-jc7333-mandatia": {
      "command": "uvx",
      "args": [
        "mandatia"
      ],
      "env": {
        "AMR_DB_PATH": "amr_mandates.db",
        "AMR_SIGNING_KEY_PATH": "<VALUE>",
        "AMR_PUBLIC_KEY_PATH": "amr_signing_key.pub",
        "AMR_LOG_LEVEL": "INFO",
        "AMR_ISSUE_TOKEN": "<VALUE>",
        "AMR_SERVER_NAME": "Agent Mandate Registry",
        "AMR_DID_WEB_RESOLVE": "<VALUE>",
        "AMR_ISSUE_REPOSITORY": "JC7333/amr",
        "AMR_PUBLIC_EXPORT_PATH": "amr_public_registry.jws",
        "AMR_TOKEN_LIFETIME_SECONDS": "300",
        "AMR_REQUIRE_PRINCIPAL_SIGNATURE": "false",
        "AMR_ATTESTATION_LIFETIME_SECONDS": "900",
        "AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS": "<VALUE>",
        "AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS": "900"
      }
    }
  }
}

Restart Windsurf (or refresh its MCP servers panel) to activate the new server.

Windsurf Next uses ~/.codeium/windsurf-next/mcp_config.json. Devin Desktop (the Windsurf rebrand) uses ~/.config/devin/mcp_config.json and imports the Windsurf file.

Add to ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json

Windows / Linux path
Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
Linux: ~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
{
  "mcpServers": {
    "io-github-jc7333-mandatia": {
      "command": "uvx",
      "args": [
        "mandatia"
      ],
      "env": {
        "AMR_DB_PATH": "amr_mandates.db",
        "AMR_SIGNING_KEY_PATH": "<VALUE>",
        "AMR_PUBLIC_KEY_PATH": "amr_signing_key.pub",
        "AMR_LOG_LEVEL": "INFO",
        "AMR_ISSUE_TOKEN": "<VALUE>",
        "AMR_SERVER_NAME": "Agent Mandate Registry",
        "AMR_DID_WEB_RESOLVE": "<VALUE>",
        "AMR_ISSUE_REPOSITORY": "JC7333/amr",
        "AMR_PUBLIC_EXPORT_PATH": "amr_public_registry.jws",
        "AMR_TOKEN_LIFETIME_SECONDS": "300",
        "AMR_REQUIRE_PRINCIPAL_SIGNATURE": "false",
        "AMR_ATTESTATION_LIFETIME_SECONDS": "900",
        "AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS": "<VALUE>",
        "AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS": "900"
      }
    }
  }
}

Cline reloads cline_mcp_settings.json automatically; if the server does not appear, reload the VS Code window.

Open it from Cline's MCP Servers panel → Configure. Roo Code uses a different file and format.

Configuration

Environment variables this server reads. Secrets stay on your machine.

NameRequiredDescription
AMR_DB_PATH No Path to the SQLite database file. Default: amr_mandates.db
AMR_SIGNING_KEY_PATH No Path to the signing private key PEM file. By default AMR writes its signing key in the current directory of the client. Keep the .pem private key out of version control.
AMR_PUBLIC_KEY_PATH No Path to the registry public key; the public registry app pins it to verify the snapshot. Default: amr_signing_key.pub
AMR_LOG_LEVEL No Logging verbosity. Default: INFO
AMR_ISSUE_TOKEN No GitHub token that lets report_issue file issues itself (fine-grained, Issues: write, one repository). Read from the process environment only, never from .env. Unset: no network call.
AMR_SERVER_NAME No MCP server display name. Default: Agent Mandate Registry
AMR_DID_WEB_RESOLVE No Set to 1 to let register_principal_key read the DID document of a did:web principal (one HTTPS GET to that domain). Read from the process environment only, never from .env. Unset: did:web keys are refused.
AMR_ISSUE_REPOSITORY No Repository report_issue files issues on (owner/name). Default: JC7333/amr
AMR_PUBLIC_EXPORT_PATH No Signed snapshot written by python -m amr.public_registry export and served by its app. Default: amr_public_registry.jws
AMR_TOKEN_LIFETIME_SECONDS No Maximum lifetime of an action token. A token lives at most this long and never past the expiry of its mandate or any parent mandate in the delegation chain, nor beyond the shortest matching risk class. Default: 300
AMR_REQUIRE_PRINCIPAL_SIGNATURE No Refuse every mandate not signed by its principal. Default: false
AMR_ATTESTATION_LIFETIME_SECONDS No Longest lifetime of a mandate attestation. Default: 900
AMR_PUBLIC_SNAPSHOT_MAX_AGE_SECONDS No Public registry: answer snapshot_too_old instead of a status past this age. Unset by default.
AMR_PRINCIPAL_SIGNATURE_MAX_AGE_SECONDS No Allowed gap between signed_at and the registry clock. Default: 900

Similar servers