@wafersecurity/cli
v0.4.2
Published
Agent-native CLI for Wafer — the AI security gateway. Manage projects, guardrails, limits, logs and run guardrail tests from the terminal or an agent.
Maintainers
Readme
@wafersecurity/cli
Agent-native CLI for Wafer — the AI security gateway.
Manage projects, guardrails, limits, logs and run guardrail tests from the
terminal or an agent. Zero dependencies, every command supports --json.
Install
npm i -g @wafersecurity/cli # once published
# or run from source:
node packages/cli/src/cli.js helpAuth
Create an API key in the console (API keys in the header), then log in:
wafer login # paste the key when prompted (saved to ~/.wafer/config.json)
# or: wafer login wafer_sk_...
# or, instead of login, set an env var:
export WAFER_API_KEY=wafer_sk_...wafer logout removes the saved key. WAFER_URL overrides the base (default
https://wafersecurity.ai).
Commands
wafer projects # list projects
wafer projects create "My App" --id my-app
wafer projects delete my-app
wafer guardrails get my-app
wafer guardrails set my-app pii redact # rule: secrets|pii|blocklist|injection
wafer cache my-app on
wafer ratelimit my-app 60
wafer budget my-app 1000000
wafer test my-app "email me at [email protected]" # run guardrails, no model call
wafer logs my-app --limit 20
wafer analytics my-app
wafer init my-app # print the gateway base URLs
wafer keys list
wafer keys create ci
wafer keys revoke <id>
wafer whoamiAdd --json to any command for machine-readable output — ideal for agents.
