Guides
Guides
Practical, sourced how-tos for handling credentials, useful whichever tools you use.
How AI agents get credentials: six models compared
Six ways AI agents get credentials, compared: environment variables, MCP retrieval, credential proxies, token exchange, browser sign-in approval and intent brokering.
How to give AI coding agents API access safely
Practical ways to let an AI coding agent call APIs without exposing a powerful key: scoped credentials, sandboxes, approvals, proxies and what to avoid.
How to keep .env files away from AI coding agents
Per-tool settings for hiding .env files from Claude Code, Cursor, Aider, Gemini CLI and others, with sourced limits on what each ignore mechanism does not cover.
How to rotate API keys without downtime
A step-by-step method for rotating API keys safely: create, deploy, verify, then revoke, with provider-specific notes for Stripe, AWS, Cloudflare, GitHub and more.
How to store API keys safely
Where to keep API keys so they stay out of code, repositories and chat: a practical ladder from local development to production, with checks you can run today.
Secrets in CI/CD pipelines: how to handle them safely
How to store, scope and protect API keys and tokens in CI/CD, using GitHub Actions as the worked example: OIDC, pinned actions, environment secrets and what to avoid.
What to do when an API key leaks
A calm, ordered response plan for an exposed API key: revoke, replace, check for misuse, clean up the exposure, and prevent a repeat, with provider-specific steps.
Store API keys in your framework
- .NET
- Android (Kotlin)
- Django
- Docker Compose
- GitHub Actions
- Go
- iOS (Swift)
- Java (Spring Boot)
- Next.js
- Node.js
- PHP (Laravel)
- Python
- React
- Ruby on Rails
- Rust
- Vite
Provider-specific guides
Where to find, how to scope, rotate and revoke the keys of each provider: API key guides. For coding agents: agent setup guides.