phantom_list_secretsLABSCO SUMMARY
Other secrets managers protect keys at rest and in transit; this one keeps them out of the model's context.
That is where a coding agent actually reads them — the .env file — so the fix is to make what it reads worthless and do the substitution below the agent, at the proxy. The MCP surface follows the same idea: mutating tools need an explicit confirmation flag, and the server refuses to take a real secret value as an argument at all.
What it is
A local-first secrets manager built for AI coding agents. Real values live in your OS keychain, the .env file carries phm_ tokens, and a local reverse proxy substitutes the real key on outbound requests.
What you get
- Vault management from the client: phantom_list_secrets, phantom_status, phantom_init, phantom_add_secret_interactive, phantom_remove_secret, phantom_rotate, phantom_copy_secret
- Diagnostics: phantom_doctor, phantom_why, phantom_check, phantom_env
- Local-to-cloud: phantom_wrap, phantom_unwrap, phantom_sync, phantom_cloud_push, phantom_cloud_pull, phantom_cloud_status
- Teams: phantom_team_list, phantom_team_create, phantom_team_members, phantom_team_invite, phantom_team_key_publish, phantom_team_vault_push, phantom_team_vault_pull
- Mutating tools require an explicit confirm parameter, so a prompt-injected agent cannot silently change state
- Real secret values are never accepted as tool arguments — new secrets are entered in a trusted terminal
- Optional cloud sync is end-to-end encrypted; the server only ever holds ciphertext
Requirements
npx phantom-secrets init detects your .env, moves the real values into the OS keychain and rewrites the file with phantom tokens. phantom setup --client claude writes the MCP config in the right place — cursor, windsurf and codex are also supported — falling back to npx -y phantom-secrets-mcp when phantom-mcp is not on PATH.
Setup effort
Follow the published steps — npm install -g phantom-secrets
USE CASES
Letting an agent use a live API key without seeing it
Run the command through phantom exec; the agent gets a placeholder, the proxy sends the real key.
Checking whether your setup is actually safe
Run the readiness check and get a human-readable answer rather than guessing.
Rotating a key without pasting it anywhere
Ask for the rotation and let the vault handle the new value.
Sharing a vault with a team
Publish your key, then push and pull the team vault instead of sending secrets around.
25 tools
Listed in project docs. Your client may show a different list.
phantom_statusphantom_initphantom_add_secret_interactivephantom_add_secretphantom_remove_secretphantom_rotatephantom_copy_secretphantom_doctorphantom_whyphantom_checkphantom_envphantom_wrapphantom_unwrapphantom_syncphantom_cloud_pushphantom_cloud_pullphantom_cloud_statusphantom_team_listphantom_team_createphantom_team_membersphantom_team_invitephantom_team_key_publishphantom_team_vault_pushphantom_team_vault_pullBEFORE YOU INSTALL
What to know first
Tools you get
25 tools named in the project's documentation.
INSTALLATION
Connect your client
Server setup
npm install -g phantom-secrets
phantom init
phantom setup --client claudeOr --client cursor / windsurf / codex; add --print for any other client.
MCP Clients
Claude Code
phantom setup --client claudeClaude Code — npx
claude mcp add phantom-secrets-mcp -- npx phantom-secrets-mcpCursor, Windsurf
{
"mcpServers": {
"phantom": {
"command": "npx",
"args": [
"-y",
"phantom-secrets-mcp"
]
}
}
}Codex
[mcp_servers.phantom]
command = "npx"
args = ["-y", "phantom-secrets-mcp"]Any MCP client
phantom setup --client claude --print