opena2a-org/secretless-ai
About
One command to keep secrets out of AI (LLMs). Works with Claude Code, Cursor, Copilot, Windsurf, and any AI coding tool.
Developer ToolsMeasured star growth
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- Collecting history
- in 1 month
- Collecting history
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README.md
OriginalSecretless AI
OpenA2A: CLI · HackMyAgent · Secretless · AIM · Browser Guard · DVAA
Secretless stores API keys outside your project files and sets up Claude Code, Cursor, GitHub Copilot, Windsurf, Cline and Aider not to read credential files. In Claude Code a hook and deny rules enforce that.
Quick start
npx secretless-ai init
What npx secretless-ai init prints, trimmed (full output):
Configured: Claude Code (1 of 1 detected)
Enforced: Claude Code (guard hook and deny patterns)
Created:
+ .claude/hooks/secretless-guard.sh
+ .claude/hooks/secretless-output-check.cjs
+ .claude/settings.json (147 deny patterns)
+ CLAUDE.md
Next steps:
Verify: secretless-ai verify
Scan: secretless-ai scan
Status: secretless-ai status
Captured in a project holding an empty .claude/ directory. Run it in a project root. It needs Node.js 20.19 or later and exits 1 when it leaves a tool not configured.
npx secretless-ai status prints Protected only where the Claude Code hook or deny patterns apply. A project set up through instruction files alone reads Advisory only.
Recorded with secretless-ai 0.23.1 on 2026-10-22 (pre-release build)
Text version · How it was recorded
Common tasks
- Store a secret and use it by name
- Scan for hardcoded credentials
- Send scan findings to the GitHub Security tab
- Encrypt keys in MCP configs
- Move secrets to another machine
- Track an exposed key until rotated
- Give git a stored token
- Push secrets to a cloud store
- Switch storage backend
- Run the broker
Store secrets and use them in AI sessions
npx secretless-ai secret set STRIPE_SECRET_KEY --from-clipboard # key copied from a web page
npx secretless-ai secret set STRIPE_SECRET_KEY # or type or paste it at a prompt, input hidden
npx secretless-ai import .env # or migrate an existing .env in one step
npx secretless-ai secret list # names only, values are never printed
npx secretless-ai run --only STRIPE_SECRET_KEY -- node charge.js # one command gets the value
Commands and AI tools see the name, and the value goes to the process that uses it. With no backend configured, secrets go to the OS keychain where one is available, and otherwise to an AES-256-GCM encrypted file.
On a terminal, secret set asks before it adds a hook to ~/.zshenv or ~/.bashrc that exports every stored secret as an environment variable in each new terminal; --no-shell-hook skips the question, and with a value piped in the profile is left as it is. secret set NAME=VALUE puts the value in shell history.
init also registers a prompt-submit hook that refuses a prompt holding a credential-shaped value or a stored secret's value, and offers a watcher that redacts a credential reaching a saved transcript. Both are local hooks; a chat in a browser is outside their reach.
Install
npm install -g secretless-ai
brew install opena2a-org/tap/secretless-ai
Install covers building from source, checking a release's provenance, and when Secretless reads a value it stores.
Telemetry
Secretless sends anonymous tier-1 usage data to the OpenA2A Registry: tool name (secretless-ai), version, command name (scan, init, etc.; a first argument that is not a command is sent as unknown), success, duration, platform, Node major version, and a stable per-machine install_id.
No content is collected. No scanned secrets, no file paths, no env-var values, no rule contents, no IPs.
- Policy: opena2a.org/telemetry.
- Status:
secretless-ai telemetry status. - Disable per-invocation:
OPENA2A_TELEMETRY=off secretless-ai <anything>. - Disable persistently:
secretless-ai telemetry off. - Audit every payload:
OPENA2A_TELEMETRY_DEBUG=print secretless-ai <anything>echoes each event to stderr as JSON.
Never sent from CI or a test runner: nothing is sent while CI, a CI service's own variable (GITHUB_ACTIONS, GITLAB_CI, JENKINS_URL, TF_BUILD and others), VITEST, JEST_WORKER_ID or NODE_TEST_CONTEXT is set. telemetry status then shows state: off and names the variable.
A variable counts as unset when its value is empty or only spaces, or is false or 0 in any letter case with surrounding spaces ignored, so CI=false and CI= leave telemetry as you configured it.
While telemetry is off (OPENA2A_TELEMETRY=off, telemetry off, CI or a test runner), Secretless writes no install_id to the setting file (~/.config/opena2a/telemetry.json, or $XDG_CONFIG_HOME/opena2a/telemetry.json when that variable is set), and removes one an earlier run stored there, keeping the stored on or off setting. The next run with telemetry on creates an install_id again.
Fire-and-forget with a 2-second timeout. Telemetry never blocks Secretless.
What it does not cover
Cursor, GitHub Copilot, Windsurf, Cline and Aider get instruction or ignore files, and nothing enforces them.
The guard hook and the deny rules check a command before it runs and cannot see what it prints, so a command whose own output is a credential puts that value in AI context: see What the guard cannot see.
Documentation
- How it works: the scan, supported tools, storage backends, Vault Exec and the broker
- Store and use secrets: every
secretworkflow - Commands: MCP protection, triage flags, exit codes
- Scan coverage and exit codes, with what a directory scan opens
- Use cases: step-by-step guides
- Contributing
Security issues: report privately through GitHub private vulnerability reporting or [email protected]. We acknowledge receipt within 48 hours; SECURITY.md has the full policy.
Documentation site · Demos · aicomply
License
Apache-2.0. See LICENSE.
Explore related projects
Loading…