Beginner's guide

Put Aggrete between Claude and your data.

New to this? This guide goes from a fresh Claude install to Claude working through Aggrete, so a policy you set is enforced on every request. No prior MCP experience needed, about 15 minutes.

What is Aggrete? Claude can be given tools: your files, Slack, a database, an internal system. Aggrete is a checkpoint that sits in front of those tools. You give it a policy, in effect your code of conduct, and it checks every request Claude makes before it happens. If a request would cross a line, leak a secret, build a layoff list, or send data out after reading something untrusted, Aggrete refuses it and records why. Everything else passes straight through.
Step 0 · look first

See what "governed" means, before installing anything.

Two ways to get the idea in a couple of minutes.

in your browser

Open the live console

A read-only demo on a sample company: what was checked, what was prevented, and why, in plain language. Nothing to install.

Open the console
in your terminal

Run the walkthrough

One command, no config and no network. It asks four questions and shows an allow, a warning, and a refusal.

# Python 3.10+
pip install aggrete
aggrete --demo
Set up

Five steps to Claude working through Aggrete.

This runs Aggrete on your own machine against bundled mock connectors, so you can watch it work end to end before wiring in your real systems.

1

Check your Python

Aggrete needs Python 3.10 or newer.

python3 --version   # need 3.10 or newer

On a Mac the built-in python3 is often 3.9, which is too old. If so, install a newer one (brew install python@3.12) and use that to create the virtualenv below.

2

Get the sample policy and mock tools

Clone the repo so you have a ready policy (coc.yaml), a proxy config, and mock HR, finance and ops connectors to try it against.

git clone https://github.com/aggrete/aggrete
cd aggrete
python3 -m venv .venv && .venv/bin/pip install -e .
3

Check it starts

Run the proxy once by hand. It launches the mock connectors and waits for a client. Press Ctrl-C to stop, then let Claude launch it in the next step.

.venv/bin/aggrete --config proxy.config.yaml
4

Connect Claude

Pick how you use Claude. Both run Aggrete locally over stdio, so nothing leaves your machine. Use full paths.

Claude Code (terminal)
claude mcp add aggrete -- \
  "$PWD"/.venv/bin/aggrete \
  --config "$PWD"/proxy.config.yaml

Then type /mcp in Claude Code to see the tools appear.

Claude Desktop (app)

Add this to claude_desktop_config.json (macOS: ~/Library/Application Support/Claude/), then quit and reopen Claude.

{
  "mcpServers": {
    "aggrete": {
      "command": "/PATH/aggrete/.venv/bin/aggrete",
      "args": ["--config",
        "/PATH/aggrete/proxy.config.yaml"]
    }
  }
}
5

Try it in Claude

Ask Claude to do something the sample policy forbids, like combining budget and personnel records to flag who might be let go. Aggrete refuses before anything is fetched, and hands Claude the reason instead of the data. Ordinary questions pass straight through.

claude · through aggrete
you ▸"Pull the budget and the personnel list and flag who's most at risk."
refusedcode of conduct · records may not be combined to derive a departure
Nothing was fetched. Claude receives the reason, not the data.
Make it yours

Swap in your policy and your tools.

Three things to change when you are ready to move past the mocks.

policy

Use your code of conduct

Edit coc.yaml by hand, or drop your handbook into the console and let it draft rules you review. Turn protection packs on and off in plain language.

Try the drafter
tools

Put a real system behind it

Replace the mocks with a connector, Google Drive, Slack, GitHub and more, each fenced to a boundary and mapped to a policy domain.

See connectors
everyone

Share it with a team

Run Aggrete as a service with sign-in, so every teammate's Claude goes through the same policy. Same rules, one place.

Deploy options
Deploy

Four ways to run it.

Start on a laptop, graduate to a shared service, make it the company default, or embed the enforcement in a gateway you already run.

01 · local

stdio on one laptop

The simplest path. Identity is advisory; good for trying rules against the mocks or your own connectors.

# .mcp.json in the project root
python -m aggrete.proxy
  --config proxy.config.yaml
02 · shared

HTTP service, tokens from your IdP

One streamable-HTTP service. Users are derived from the OAuth token; state in Redis for multiple replicas.

# requires auth: in config
--transport streamable-http
--host 0.0.0.0 --port 8080
03 · company-wide

The default, not an option

Ship a managed MCP config by MDM and fence connectors to the proxy host, so assistants can only talk to Aggrete.

# helm
helm install aggrete
  deploy/helm/aggrete
04 · embed

Gateway plugin

Already run a gateway? Add just the enforcement via the before/after hook or the ASGI middleware.

# aggrete/plugin.py
from aggrete.plugin import
  PolicyHook, AggreteMiddleware
Keep going

Where to next.

Stuck?

We read every question.

If a step did not work or a clause is hard to model, open an issue. It is the fastest way to get help, and it makes the guide better for the next person.

Ask a question Read the README