Documentation
Everything you need to secure your AI agents with SpiderShield.
Quickstart
Python SDK
python
pip install spidershield from spidershield import SpiderGuard, Decision guard = SpiderGuard(policy="balanced", dlp="redact") # Check before tool execution result = guard.check("execute_sql", {"query": "SELECT * FROM users"}) if result.decision == Decision.ALLOW: output = run_tool("execute_sql", {"query": "SELECT * FROM users"}) # Scan output for secrets / PII clean = guard.after_check("execute_sql", output)
CLI
bash
# Guard mode — wrap any MCP server "code-keyword">$ "code-function">spidershield guard "code-keyword">--preset balanced -- "code-function">npx @modelcontextprotocol/server-filesystem /tmp # Scan mode — static security analysis "code-keyword">$ "code-function">spidershield scan ./my-mcp-server # Proxy mode — transparent interception "code-keyword">$ "code-function">spidershield proxy "code-keyword">--policy strict -- python my_mcp_server.py
Guides
Runtime Guard
Policy enforcement before every tool call. ALLOW, DENY, or ESCALATE decisions in real time.
DLP Scanner
Detect and redact PII, API keys, secrets, and prompt injection in tool outputs.
CLI Reference
Full command reference for scan, guard, proxy, audit, policy, and dataset commands.
Policy Engine
YAML-based policy presets (permissive, balanced, strict) and custom rule authoring.
Audit Logging
JSONL audit trail for every tool call, decision, and DLP event. Queryable via CLI.
Agent Security
Config audit, skill scanning, toxic flow detection, and content pinning for agent frameworks.
Installation
PyPI
pip install spidershieldpipx (CLI only)
pipx install spidershieldFrom source
git clone && pip install -e .