agentgov-gateway
The local FastAPI gateway that Claude Code (via ANTHROPIC_BASE_URL=http://localhost:8000) talks to.
Runs on each developer's machine. Vaults the upstream credential (X25519 sealed-box decrypted from the signed policy snapshot). Enforces repo-lock + work-item binding + budget middleware chain. Streams SSE verbatim to Claude Code while tee-parsing usage frames for attribution.
Part of the AgentGov project — see github.com/deepakahu/agentGov for the full monorepo (control tower, CLI, client assets, Supabase migrations, docs).
Install
pip install agentgov-gateway
Configure
Requires these env vars — see the project .env.example for the full list:
CONTROL_TOWER_URL— where your AgentGov control tower is deployedGATEWAY_SERVICE_TOKEN— agtw_...token fromagentgov register-devicePOLICY_SIGNING_PUBLIC_KEY_B64— Ed25519 public key (control tower gives you this)DEVICE_KEY_PATH— path to your X25519 device private key (default:./.runtime/device_key.priv)UPSTREAM_MODE—oauth_passthrough(default, personal) orapikey_vault
Run
uvicorn agentgov_gateway.main:app --host 127.0.0.1 --port 8000
Under systemd / launchd for persistent operation.
License
Apache-2.0
Metadata
Release files for agentgov-gateway 0.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| agentgov_gateway-0.1.6.tar.gz | 187.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| agentgov_gateway-0.1.6-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 253.6 kB
Release files / agentgov_gateway-0.1.6.tar.gz
| Download URL | agentgov_gateway-0.1.6.tar.gz |
|---|---|
| Size | 187.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3e679566e3d5ec709323da939a4becfa05926997e7c728168cac08f87c181d03
|
|
BLAKE2b-256 checksum How to use checksums |
7431f6f791c49f39ff963ff63db9464e6f3d8e9e729c06dc5f1b85f12ad342bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.3
|
Release files / agentgov_gateway-0.1.6-py3-none-any.whl
| Download URL | agentgov_gateway-0.1.6-py3-none-any.whl |
|---|---|
| Size | 65.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2c924928bbe4d2f3ace6d29034cdf22b5a6802f2fcebad80909124a92a66ca58
|
|
BLAKE2b-256 checksum How to use checksums |
e667d05c02c9597ccf3f1f58e7c4e161c1448b0599d4700901fdc27457513a96
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.3
|