For agents

The rules an agent follows with KeyKeeper, in one page. The full skill file is in the repository.

The complete instructions live in skill/keykeeper.md; Codex and Claude Code read that file. This page is the short version for humans checking what their agent was told. Every docs page is also served as Markdown: add .md to the URL, or fetch /llms.txt.

Use a key without seeing it

keykeeper list                                   # names only
keykeeper run -c openai --reason "why, in one line" -- python app.py

run puts the key into that command's environment and redacts it from the command's output. Always say why (--reason); the person reads it. Without it the person still gets the window, but it says in orange that you gave no reason and recommends allowing you only once. --duration once|run|always is a wish the person sees next to KeyKeeper's own suggestion.

Get a key the user does not have

keykeeper providers                              # templates
keykeeper providers show stripe                  # where, what to choose, key shape, verification
keykeeper save --provider stripe --from-clipboard --create --purpose "refunds for the shop"

The agent opens the provider's page for the user and says what to pick; the user logs in and copies the key; KeyKeeper checks the shape before writing and verifies the key afterwards. The agent gets accepted, rejected or could not reach — never the value. See Providers.

Move a project's .env in

keykeeper import ./.env --id my-app --purpose "what this project is"
keykeeper run -c my-app -- npm run dev

The app opens the file itself and shows the variable names and skipped fields before approval. All imported values go into the Keychain, including ordinary settings; names and lengths cannot prove that a value is safe to expose as plain metadata. The agent gets counts, never values; the credential is inject-only. Single-line assignments only; malformed/multiline syntax is refused, and shell interpolation is never performed. Empty, reserved and unsupported names are skipped. Keep the original until the project works through run and skipped variables are accounted for. Only then recommend removing it and adding .env to .gitignore; consider rotating exposed keys.

What is refused

  • keykeeper get on a key the agent created (inject-only) — use run.
  • A save whose value does not look like the provider's key.
  • --security standard on a new key without a --purpose.
  • Plain fields an agent writes over the command line are not injected until the person confirms them in the app.

An agent that pastes a key into a chat, a file or a command line has already leaked it. The skill tells the agent to say so and to have the user revoke it, then start over through KeyKeeper.