Agent skill · software engineering · aiskillstore

env-config

Use when setting up environment configuration, loading .env files, or managing application settings across environments. Triggers for: .env setup, loading environment variables, Pydantic BaseSettings, configuration validation, or secret management. NOT for: code-specific logic, feature flags, or runtime feature toggles.

Why this skill is useful

Provides specific patterns and configurations for managing environment variables in Python/FastAPI applications that the AI wouldn't reliably generate on its own.

What it needs

Requires pydantic, pydantic-settings, python-dotenv installed locally. About 4k tokens when loaded. Last updated 2026-08-07. 405 stars on the source repository.

What this skill does

Environment Configuration Skill Expert environment configuration management for Python/FastAPI projects with secure secrets handling and multi-environment support. Quick Reference Pattern Usage --------- ------- Load .env loaddotenv() at application start Access var settings.DBURL, settings.JWTSECRET Required var Field(..., description="Database URL") Optional var DBHOST: str = "localhost" Secret type SecretStr for sensitive values Project Structure settings.py - Base Configuration .env.example - Template File .env - Local Development Usage in Application FastAPI Application Database Connection JWT Configuration Multi-Environment Support Environment-Specific Configs Production Override Secret Management Generate Secrets Secret Rotation Script Quality Checklist [ ] Validation on load: All required fields have Field(..., ...) validation [ ] No leaks in logs: Use SecretStr for sensitive values, never print settings [ ] .env.example committed: Template shows all required variables [ ] .env.gitignored: Local development file excluded from version control [ ] Secrets generated: JWT secrets use openssl rand -hex 32 [ ] Environment isolation: Different configs for dev/staging/production [ ] Type safety: All settings have proper type annotations Integration with Other Skills Skill Integration Point ------- ------------------- @jwt-auth JWTSECRETKEY from settings @sqlmodel-crud DBURL from settings @fastapi-app All app settings from settings @db-migration Database URL for migrations @api-route-design API prefix, CORS origins Security Best Practices DO Use SecretStr for passwords, API keys, tokens Rotate secrets regularly Use different secrets per environment Store production secrets in secrets manager Validate all required settings at startup DON'T Never commit .env files to version control Never hardcode secrets in source code Never log settings or environment variables Never use default/placeholder secrets in production Never expose configuration details in error messages St …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills aiskillstore/env-config--7e0df4

View the source on GitHub

Browse the @skills marketplace