home / skills / ehtbanton / claudeskillsrepo / jwt-config-generator
This skill generates a complete JWT authentication configuration and utilities in TypeScript, enabling secure token signing, verification, and refreshing for
npx playbooks add skill ehtbanton/claudeskillsrepo --skill jwt-config-generatorReview the files below or copy the command above to add this skill to your agents.
---
name: jwt-config-generator
description: Generate JWT authentication configuration and utilities for API security. Triggers on "create jwt config", "generate jwt authentication", "jwt setup", "token auth config".
---
# JWT Config Generator
Generate JWT authentication configuration and utility functions.
## Output Requirements
**File Output:** `jwt.ts` with sign/verify utilities
**Format:** Valid TypeScript
**Standards:** JWT best practices, jsonwebtoken library
## When Invoked
Immediately generate a complete JWT configuration with token utilities.
## Example Invocations
**Prompt:** "Create JWT authentication config"
**Output:** Complete JWT utilities with sign, verify, and refresh logic.
This skill generates a complete JWT authentication configuration and utility file in TypeScript. It outputs a ready-to-use jwt.ts containing sign, verify, and refresh token logic following JWT best practices. The utilities target the jsonwebtoken library and include sensible defaults for expiration, algorithms, and key handling.
When triggered, the skill produces a TypeScript module that exports functions to create access and refresh tokens, verify tokens, and decode payloads safely. The generated code uses jsonwebtoken for signing and verification, supports environment-based secret or key selection, and includes error handling and token rotation guidance. It follows common patterns for token lifetimes, algorithms, and secure storage recommendations.
Which library does the generated code use?
The output uses the jsonwebtoken library for signing and verification in TypeScript.
Does it support symmetric and asymmetric keys?
Yes. The template supports both HS256 (shared secret) and RS256 (private/public keys) via environment configuration.