Metadata-Version: 2.4
Name: bollard-ai
Version: 0.3.0
Summary: See, then govern, your AI agents — watch which apps they use, and enforce what they're allowed to do.
Author: Bollard AI
License: Proprietary
Project-URL: Homepage, https://bollardai.com
Keywords: bollard,ai agents,governance,observability,security
Requires-Python: >=3.9
Description-Content-Type: text/markdown

# bollard

The one line that lets Bollard **see, then govern** your AI agents.

Add it where your agents start up. By default it's **watch-only** — it notes which
apps your agents use (Notion, Slack, Gmail, Xero, Drive, paid AI models), never what
they read or write, and reports it to Bollard. When you protect an app in Bollard, the
same install starts routing *that app's* calls through Bollard so each agent can only
do what you allow — no code change. Every other app stays watch-only.

Three promises, enforced in code:

- **It can't break your agents.** Watch-only observes and, if anything goes wrong,
  falls straight through to the real call. Enforcement is opt-in, per app, reversible.
- **It can't slow them down.** It reports in the background on its own thread.
- **It never sees your data or code.** It reads only the *envelope* of each call — the
  destination and operation name. There is no code path that reads a request or
  response body (see `bollard/_apps.py`).

## Install

```bash
pip install bollard-ai
```

## Use it

**One shared codebase** — wrap the command, no code change:

```bash
bollard watch --key BWATCH-XXXX-XXXX-XXXX -- python your_agents.py
```

**Separate projects** — add one line where each agent starts up:

```python
import bollard
bollard.start(key="BWATCH-XXXX-XXXX-XXXX", agent="sales-follow-up")
```

## Enforcement (opt-in)

Watching needs only your workspace key. To let Bollard *enforce* an agent (once you've
protected an app in the dashboard), give that agent its own identity:

```python
bollard.start(key="BWATCH-...", agent="sales-follow-up", agent_token="boll_agt_...")
```

With an `agent_token`, calls to any **protected** app are routed through Bollard, which
allows or blocks them against that agent's permissions. Apps you haven't protected stay
watch-only. No `agent_token` → always watch-only. If Bollard can't be reached to confirm
the policy, the agent stays watch-only — it never starts blocking off an unconfirmed rule.

## Configuration

`start()` reads these when the arguments are omitted:

| Variable | Meaning |
|---|---|
| `BOLLARD_KEY` | your workspace key (`BWATCH-...`) |
| `BOLLARD_AGENT` | optional name for this agent |
| `BOLLARD_AGENT_TOKEN` | this agent's identity (`boll_agt_...`), for enforcement |
| `BOLLARD_ENDPOINT` | override Bollard's base address (self-hosting / testing) |
