@podut/cwescan-cli
v0.3.5
Published
CWEScan CLI - Manage AI coding skills and documentation context
Maintainers
Readme
cwescan
CLI for cwescan - query up-to-date library documentation and manage AI coding skills.
Skills are reusable prompt instructions that enhance your AI coding assistant with specialized capabilities like working with specific frameworks, libraries, or coding patterns.
Installation
# Run directly with npx (no install needed)
npx cwescan
# Or install globally
npm install -g cwescanQuick Start
# Set up cwescan MCP for your coding agents
cwescan setup
# Target a specific agent
cwescan setup --cursor
cwescan setup --claude
cwescan setup --opencodeLibrary Documentation
# Find a library
cwescan library react
cwescan library nextjs "app router"
# Get documentation
cwescan docs /facebook/react "useEffect cleanup"
cwescan docs /vercel/next.js "middleware"Skills
# Search for skills
cwescan skills search pdf
# Install a skill
cwescan skills install /anthropics/skills pdf
# Generate a custom skill with AI
cwescan skills generate
# List installed skills
cwescan skills list --claudeUsage
Find a library
Resolve a library name to a cwescan library ID.
cwescan library react
cwescan library nextjs "app router setup"
cwescan library prisma "database relations"
# Output as JSON
cwescan library react --jsonQuery documentation
Fetch documentation for a specific library using its cwescan ID.
cwescan docs /facebook/react "useEffect cleanup"
cwescan docs /vercel/next.js "middleware authentication"
cwescan docs /prisma/prisma "one-to-many relations"
# Output as JSON
cwescan docs /facebook/react "hooks" --jsonSetup
Configure cwescan MCP and a rule for your AI coding agents. Authenticates via OAuth, generates an API key, and writes the config.
# Interactive (prompts for agent selection)
cwescan setup
# Target specific agents
cwescan setup --cursor
cwescan setup --claude
cwescan setup --opencode
# Use an existing API key instead of OAuth
cwescan setup --api-key YOUR_API_KEY
# Use OAuth endpoint (IDE handles auth flow)
cwescan setup --oauth
# Configure for current project only (default is global)
cwescan setup --project
# Skip prompts
cwescan setup --yesGenerate skills
Generate custom skills tailored to your use case using AI. Requires authentication.
# Log in first
cwescan login
# Generate a skill (interactive)
cwescan skills generate
# Short aliases
cwescan skills gen
cwescan skills g
# Generate and install to a specific client
cwescan skills generate --cursor
cwescan skills generate --claude
cwescan skills generate --universal
# Generate globally
cwescan skills generate --globalThe generate flow:
- Describe the expertise you want (e.g., "OAuth authentication with NextAuth.js")
- Select relevant libraries from search results
- Answer 3 clarifying questions to focus the skill
- Review the generated skill, request changes if needed, then install
Weekly generation limits apply: free accounts get 6 generations/week, Pro accounts get 10.
Authentication
Log in to access skill generation and other authenticated features.
# Log in (opens browser for OAuth)
cwescan login
# Check login status
cwescan whoami
# Log out
cwescan logoutInstall skills
Install skills from a project repository to your AI coding assistant's skills directory.
# Install all skills from a project (interactive selection)
cwescan skills install /anthropics/skills
# Install a specific skill
cwescan skills install /anthropics/skills pdf
# Install multiple skills at once
cwescan skills install /anthropics/skills pdf commit
# Install to a specific client
cwescan skills install /anthropics/skills pdf --cursor
cwescan skills install /anthropics/skills pdf --claude
cwescan skills install /anthropics/skills pdf --universal
# Install globally (home directory instead of current project)
cwescan skills install /anthropics/skills pdf --globalSearch for skills
Find skills across all indexed projects in the registry.
cwescan skills search pdf
cwescan skills search typescript
cwescan skills search react testingList installed skills
View skills installed in your project or globally.
cwescan skills list
cwescan skills list --claude
cwescan skills list --cursor
cwescan skills list --universal
cwescan skills list --globalShow skill information
Get details about available skills in a project.
cwescan skills info /anthropics/skillsRemove a skill
Uninstall a skill from your project.
cwescan skills remove pdf
cwescan skills remove pdf --claude
cwescan skills remove pdf --universal
cwescan skills remove pdf --globalSupported Clients
The CLI automatically detects which AI coding assistants you have installed and offers to install skills for them:
| Client | Skills Directory |
|--------|-----------------|
| Universal (Amp, Codex, Gemini CLI, GitHub Copilot, OpenCode + more) | .agents/skills/ |
| Claude Code | .claude/skills/ |
| Cursor | .cursor/skills/ |
| Antigravity | .agent/skills/ |
Shortcuts
For faster usage, the CLI provides short aliases:
cwescan si /anthropics/skills pdf # skills install
cwescan ss pdf # skills search
cwescan skills gen # skills generate
cwescan skills g # skills generateDisabling Telemetry
The CLI collects anonymous usage data to help improve the product. To disable telemetry, set the cwescan_TELEMETRY_DISABLED environment variable:
# For a single command
cwescan_TELEMETRY_DISABLED=1 cwescan skills search pdf
# Or export in your shell profile (~/.bashrc, ~/.zshrc, etc.)
export cwescan_TELEMETRY_DISABLED=1Learn More
Visit cwescan.com to browse the skills registry and discover available skills.
