Installation
Install the AgentShield services, the Python and TypeScript SDKs, and the framework integrations.
AgentShield has two halves: the services you run (gateway, control plane, dashboard, intelligence engine, event relay) and the clients your agents use (SDKs and framework integrations). This page covers both.
Requirements
| Tool | Version | Needed for |
|---|---|---|
| Docker with Compose v2 | Current | Data services, and the full stack in containers |
| Go | 1.23 or newer | Running the gateway and event relay from source |
| Node.js | 22 or newer (.nvmrc) | Control plane, dashboard, TypeScript SDK |
| Python | 3.11 or newer | Intelligence engine, Python SDK, integrations |
| kubectl | With built-in Kustomize | Kubernetes deployment |
Services
The fastest path. Every image runs as a non-root user on a read-only filesystem with all capabilities dropped.
docker compose --profile app up -d --build
docker compose --profile app run --rm control-plane node apps/control-plane/dist/bootstrap.jsdocker compose up -d without a profile starts only PostgreSQL, Redis, NATS, MinIO, and Mailpit, for running the applications from source. See Docker Compose.
Python SDK
The Python SDK lives in sdk/python as the agentshield-sdk distribution. Its only dependency is cryptography.
python -m pip install ./sdk/pythonfrom agentshield_sdk import Client, public_keyAlternatively, put the source directory on PYTHONPATH, which is how the repository's own tests and examples run:
python -m pip install "cryptography>=43,<47"
export PYTHONPATH=sdk/pythonFramework integrations
Each integration is its own pip package that depends on agentshield-sdk and on its framework. Install the SDK and the integration from the repository in one command, so pip resolves the SDK dependency locally:
| Integration | Install | Pulls in |
|---|---|---|
| LangGraph node | python -m pip install ./sdk/python ./integrations/langgraph | Nothing else. Works with any LangGraph state that has messages |
| LangChain tools | python -m pip install ./sdk/python ./integrations/langchain | langchain-core 0.3 or newer |
| CrewAI tools | python -m pip install ./sdk/python ./integrations/crewai | crewai 0.100 or newer |
| MCP server | python -m pip install ./sdk/python ./integrations/mcp | Nothing else. Adds the agentshield-mcp command |
The repository's tests still run from source with PYTHONPATH pointing at sdk/python and the integration directories; both ways load the same code.
TypeScript SDK
Build a package tarball from the repository and install it into your project:
# in the AgentShield repository
npm ci
npm pack --workspace @agentshield/sdk # builds dist/ and writes agentshield-sdk-0.1.0.tgz
# in your project
npm install /path/to/agentshield-sdk-0.1.0.tgzimport { Client } from "@agentshield/sdk";The package is ESM with type declarations, uses only node:crypto and the global fetch, and has no runtime dependencies. It works with plain node and any TypeScript setup using "moduleResolution": "NodeNext" or "Bundler". Inside the repository, workspaces can depend on it directly after npm run build --workspace @agentshield/sdk.
Node.js 22 or newer
The client relies on the global fetch and on Ed25519 support in node:crypto. Both are available in every supported Node.js release.
Verify the installation
curl -s http://127.0.0.1:8081/health/ready # gateway: PostgreSQL and Redis answer
curl -s http://127.0.0.1:8080/health/ready # control plane: PostgreSQL answers
curl -s http://127.0.0.1:8082/health/ready # intelligence: ruleset loaded
curl -s http://127.0.0.1:8083/health/ready # event relay: database, NATS, outbox ageEach returns HTTP 200 when ready and 503 otherwise. A gateway whose readiness is 503 does not return allow.
Was this page helpful?