@interven/gateway
v0.5.5
Published
Interven AI Agent Firewall — drop-in gateway proxy. Scan every tool call through policy + risk scoring. One command, zero infrastructure.
Maintainers
Readme
@interven/gateway
AI Agent Firewall — drop-in gateway proxy that scans every tool call through policy + risk scoring. One command, zero infrastructure.
Quick Start
npx @interven/gateway --api-key iv_live_YOUR_KEYThat's it. Gateway starts on http://localhost:4100 with a live dashboard.
How It Works
Agent → localhost:4100/proxy/<upstream-url> → Interven Cloud → Policy + Risk → Forward or Block- Your agent sends tool calls through the local proxy
- Each call is scanned by Interven (policy, risk scoring, PII/secret detection)
- Based on the decision: ALLOW (forward), DENY (block), SANITIZE (redact & forward), or REQUIRE_APPROVAL (human review)
Usage
Route tool calls through the proxy
Instead of calling upstream APIs directly, prefix with http://localhost:4100/proxy/:
# Before (direct):
curl -X POST https://api.github.com/repos/org/repo/pulls \
-H "Authorization: Bearer ghp_..." \
-d '{"title":"PR","head":"feat","base":"main"}'
# After (through Interven):
curl -X POST http://localhost:4100/proxy/https://api.github.com/repos/org/repo/pulls \
-H "Authorization: Bearer ghp_..." \
-d '{"title":"PR","head":"feat","base":"main"}'Python
import requests
# Route through Interven gateway
response = requests.post(
"http://localhost:4100/proxy/https://api.github.com/repos/org/repo/pulls",
json={"title": "My PR", "head": "feature", "base": "main"},
headers={"Authorization": "Bearer ghp_..."}
)Monitor Mode
Log all decisions without blocking anything — great for evaluation:
npx @interven/gateway --api-key iv_live_YOUR_KEY --mode monitorOptions
| Flag | Env | Default | Description |
|------|-----|---------|-------------|
| --api-key | INTERVEN_API_KEY | — | Your Interven API key (required) |
| --port | PORT | 4100 | Listen port |
| --mode | — | enforce | enforce or monitor |
| --gateway-url | INTERVEN_GATEWAY_URL | https://api.intervensecurity.com | Cloud endpoint |
| --verbose | — | on | Log each decision to stdout |
| --quiet | — | off | Suppress per-request logs |
Dashboard
Open http://localhost:4100 in your browser for a live dashboard showing:
- Total scans, allow/deny/sanitize/approval counts
- Recent decisions with risk scores and reason codes
Get an API Key
- Sign up at app.intervensecurity.com
- Go to API Keys and create a key
- Use it with
--api-keyor setINTERVEN_API_KEY
Docs
License
MIT
