Generates strongly-typed, validated-at-startup configuration objects for any stack, replacing scattered string-keyed config lookups. Covers ASP.NET Core, TypeScript, Python, Spring Boot, and Go.
Ships in AI for Developers Toolkit. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Replace scattered string-keyed config lookups (IConfiguration["Key"], process.env.X, os.environ["X"], @Value("${x}"), os.Getenv("X")) with one strongly-typed, validated settings object per concern that fails fast at startup if misconfigured.
Works on a target: a project or GitHub URL (clone first: git clone --depth 1 <url> /tmp/repo).
| Manifest | Idiomatic typed config | Find lookups to replace |
|---|---|---|
*.csproj | Options pattern + ValidateOnStart | grep -rn "Configuration\[|GetValue<|GetSection(" --include=*.cs |
package.json | zod / envalid / @nestjs/config | grep -rn "process\.env\." --include=*.ts --include=*.js | grep -v node_modules |
pyproject.toml, requirements*.txt | pydantic-settings BaseSettings | grep -rn "os\.environ|os\.getenv|getenv(" --include=*.py |
pom.xml, build.gradle(.kts) | @ConfigurationProperties + @Validated | grep -rn "@Value(\"\${" <target>/src / Environment.getProperty |
go.mod | envconfig / caarlos0/env / viper + validator | grep -rn "os.Getenv|os.LookupEnv|viper.Get" --include=*.go |
JwtSettings, DatabaseSettings), grouped under a section/prefix. No string keys outside the binding code.secrets-config-auditor).public class JwtOptions
{
public const string Section = "Jwt";
[Required] public string Issuer { get; init; } = default!;
[Required] public string Audience { get; init; } = default!;
[Required, MinLength(32)] public string Key { get; init; } = default!;
[Range(1, 1440)] public int AccessTokenMinutes { get; init; } = 15;
}
builder.Services.AddOptions<JwtOptions>()
.Bind(builder.Configuration.GetSection(JwtOptions.Section))
.ValidateDataAnnotations()
.ValidateOnStart(); // fail at startup, not at first use
IValidateOptions<JwtOptions> (or use FluentValidation inside it); cross-field checks go there too.[OptionsValidator] on a partial class implementing IValidateOptions<T>) avoids reflection and is AOT-friendly.Which interface to inject:
IOptions<T> - singleton, value fixed at startup. Most config.IOptionsSnapshot<T> - scoped, re-read per request. For values that change and need per-request freshness.IOptionsMonitor<T> - singleton with change notifications. For singletons that must react to config reloads.
Don't inject IOptionsSnapshot into a singleton.process.env once in config.ts, export the typed result, import it everywhere.import { z } from 'zod';
const Env = z.object({
NODE_ENV: z.enum(['development', 'test', 'production']),
PORT: z.coerce.number().int().default(3000),
DATABASE_URL: z.string().url(),
JWT_KEY: z.string().min(32),
});
export const config = Env.parse(process.env); // throws at startup with every missing/invalid key
cleanEnv(process.env, { PORT: port({ default: 3000 }), DATABASE_URL: url() }) - same idea, purpose-built for env vars.ConfigModule.forRoot({ isGlobal: true, validate }) where validate runs a zod schema (or validationSchema with Joi); group with registerAs('jwt', () => ({...})) and inject via ConfigType<typeof jwtConfig>.NEXT_PUBLIC_*, VITE_*) get bundled.from pydantic import Field, PostgresDsn
from pydantic_settings import BaseSettings, SettingsConfigDict
class JwtSettings(BaseSettings):
model_config = SettingsConfigDict(env_prefix="JWT_", env_file=".env", extra="ignore")
issuer: str
audience: str
key: str = Field(min_length=32)
access_token_minutes: int = Field(default=15, ge=1, le=1440)
settings = JwtSettings() # raises ValidationError at import/startup if invalid
env_nested_delimiter="__" (DB__HOST). Use SecretStr for secrets so they don't print in logs or reprs.@lru_cache def get_settings()) so tests can override it. Django: build settings.py values from a BaseSettings instance.@Validated
@ConfigurationProperties(prefix = "jwt")
public record JwtProperties(
@NotBlank String issuer,
@NotBlank String audience,
@NotBlank @Size(min = 32) String key,
@Min(1) @Max(1440) int accessTokenMinutes) {}
@ConfigurationPropertiesScan (or @EnableConfigurationProperties(JwtProperties.class)); needs spring-boot-starter-validation on the classpath for @Validated to fail startup.Duration/DataSize types for timeouts and sizes (30s, 10MB bind natively). Add spring-boot-configuration-processor for IDE metadata.@Value("${...}") scattered across beans with injected properties records. Kotlin: data class with @ConfigurationProperties.type Config struct {
Port int `envconfig:"PORT" default:"8080"`
DatabaseURL string `envconfig:"DATABASE_URL" required:"true"`
JWTKey string `envconfig:"JWT_KEY" required:"true"`
Timeout time.Duration `envconfig:"TIMEOUT" default:"5s"`
}
func Load() (Config, error) {
var c Config
if err := envconfig.Process("", &c); err != nil { return c, err }
if len(c.JWTKey) < 32 { return c, errors.New("JWT_KEY must be at least 32 chars") }
return c, nil
}
github.com/kelseyhightower/envconfig or github.com/caarlos0/env for env vars; github.com/spf13/viper for files + env + flags (unmarshal into a struct, then validate with github.com/go-playground/validator/v10 struct tags).Load() in main, exit non-zero on error, pass Config (or sub-structs) into constructors.## Current state
<stack, magic-string lookups found (file:line), missing validation>
## Settings types
<typed classes/schemas per concern with validation rules>
## Binding + startup validation
<registration code, where it runs, what fails the boot>
## Call-site changes
<lookups replaced with the injected settings object>
"Convert this config to the options pattern", "strongly-type and validate my env vars", "fail at startup if config is missing", "replace process.env everywhere with a zod config", "pydantic settings for my FastAPI app", "IOptions vs IOptionsSnapshot here". Pairs with secrets-config-auditor.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/ai-dev-toolkit:typed-config-generatorfrom AI for Developers Toolkit
npx claudepluginhub stefanthecode/ai-for-developers --plugin ai-dev-toolkit45 skills in this plugin
/api-endpoint-scaffolderScaffold HTTP API endpoints in any stack - ASP.NET Core Minimal APIs or controllers, Express, Fastify, NestJS, FastAPI, Django REST Framework, Spring Boot controllers, Go net/http, chi, Gin - one feature per endpoint (REPR style) with request validation, typed responses, route grouping, auth, and OpenAPI metadata. Use this skill whenever the user wants to add an endpoint or route, convert controllers to minimal APIs, structure routes or routers, set up endpoint groups, TypedResults, route handlers, request DTOs/schemas (zod, Pydantic, Bean Validation, binding tags), or asks "how do I add an endpoint / structure my API routes". Always use this skill for endpoint scaffolding; it generates a complete, validated endpoint that matches the project's conventions./architecture-test-generatorGenerate architecture tests / fitness functions that fail the build when architectural rules are violated - layer dependencies, module boundaries, cycles, naming, and visibility conventions - in any stack: NetArchTest or ArchUnitNET (.NET), ArchUnit or Konsist (Java/Kotlin), dependency-cruiser or eslint-plugin-boundaries (TypeScript/JavaScript), import-linter (Python), go-arch-lint or depguard (Go). Use this skill whenever the user wants architecture tests, to enforce layering or the dependency rule, dependency rules as tests, import rules, forbidden imports, no circular dependencies, naming conventions, fitness functions, or asks "how do I stop people breaking the architecture / enforce my layers / keep modules from importing each other". Always use this skill for architecture-test requests; it generates rules matching the project's real structure./async-await-auditorAudit async and concurrent code in any language for correctness and performance bugs - C#/.NET (async/await, Task), JavaScript/TypeScript (Promises, async/await), Python (asyncio), Java/Kotlin (CompletableFuture, virtual threads, coroutines), Go (goroutines, channels, context), Rust (tokio/async). Use this skill whenever the user shares async or concurrent code, or asks about deadlocks, hangs, blocking calls, .Result/.Wait(), async void, ConfigureAwait, floating or unhandled promises, await in a loop vs Promise.all, blocking the event loop, forgotten await, asyncio.gather/TaskGroup, CompletableFuture.join, virtual thread pinning, goroutine leaks, context cancellation, WaitGroup/errgroup, holding a lock across .await, fire-and-forget tasks, cancellation tokens, or "why does my async code hang". Always use this skill for async/concurrency reviews instead of answering from memory; it applies a fixed checklist and rewrites the code./authorization-setupDesign API authorization in any stack - policy-based, role-based, claims/permission-based, and resource-based (ownership) checks. Covers ASP.NET Core policies and AuthorizationHandler, NestJS guards, Express middleware and CASL, FastAPI dependencies/scopes, Django and DRF permission classes, Spring Security (@PreAuthorize, SecurityFilterChain), Go middleware, and Casbin/OPA. Use this skill whenever the user wants authorization policies, role/claim/permission checks, RBAC/ABAC, custom authorization rules, resource-based authorization, IDOR protection, "deny by default", or asks "how do I authorize this / policy vs role / restrict this endpoint to X / stop users seeing other users' data". Always use this skill for authorization requests; it generates policies, handlers, and endpoint wiring./benchmark-setupSet up correct micro-benchmarks in any stack and interpret the results - BenchmarkDotNet (.NET), JMH (Java/Kotlin), pytest-benchmark / pyperf (Python), Vitest bench / tinybench / mitata (JavaScript/TypeScript), Go testing.B + benchstat, Rust criterion. Use this skill whenever the user wants to benchmark code, measure performance, compare two implementations or functions, set up a benchmark harness, or asks "which is faster", "benchmark these two functions", "how do I benchmark this", "is this optimization worth it", or "interpret these benchmark results". Always use this skill for micro-benchmarking requests; it writes correct benchmarks, avoids the classic pitfalls, and explains the numbers./caching-strategy-setupAdd the right caching to an app in any stack - in-process, distributed (Redis/Valkey/Memcached), two-level, or HTTP/output caching - with correct keys, expiration, stampede protection, and invalidation. Covers HybridCache / IMemoryCache / IDistributedCache / output caching in .NET, lru-cache / keyv / cache-manager / ioredis in Node, functools / cachetools / redis-py / Django cache in Python, Spring Cache with Caffeine or Redis in Java/Kotlin, and ristretto / groupcache / singleflight / go-redis in Go. Use this skill whenever the user wants caching, to cache a query/response, Redis caching, @Cacheable, lru_cache, HybridCache, cache-aside, output caching, or asks "how do I cache this / add caching / avoid cache stampede / invalidate this cache". Always use this skill for caching requests; it picks the right layer and wires expiration + invalidation correctly.Other plugins' skills for the same job