Validate full-stack app (backend, frontend, database, API contracts) with auto-fix
Comprehensive validation for full-stack apps that detects project structure, runs parallel checks on backend, frontend, database, and API contracts, then auto-fixes common issues like unused imports, SQL queries, and build configs. Use before deployments, after major changes, or in CI/CD pipelines to ensure production readiness.
/plugin marketplace add bejranonda/LLM-Autonomous-Agent-Plugin-for-Claude/plugin install bejranonda-autonomous-agent@bejranonda/LLM-Autonomous-Agent-Plugin-for-Claudevalidate/Slash command: /validate:fullstack
Description: Comprehensive validation workflow for full-stack applications. Automatically detects project structure, runs parallel validation for all components, validates API contracts, and auto-fixes common issues.
This command orchestrates a complete validation workflow for multi-component applications:
Project Detection (5-10 seconds)
Parallel Component Validation (30-120 seconds)
Cross-Component Validation (15-30 seconds)
Auto-Fix Application (10-30 seconds)
Quality Assessment (5-10 seconds)
Ideal scenarios:
Project types:
User runs: /validate:fullstack
v
Orchestrator Agent:
1. Load skills: fullstack-validation, code-analysis, quality-standards
2. Detect project structure
3. Create validation plan
v
Parallel Execution (background-task-manager):
+- [Frontend-Analyzer] TypeScript + Build validation
+- [Test-Engineer] Backend tests + coverage
+- [Quality-Controller] Code quality checks
+- [Build-Validator] Build config validation
v
Sequential Execution:
1. [API-Contract-Validator] Frontend ↔ Backend synchronization
2. [Quality-Controller] Cross-component quality assessment
v
Auto-Fix Loop (if quality score < 70):
1. Apply automatic fixes
2. Re-run validation
3. Repeat until quality ≥ 70 or max 3 attempts
v
Results:
- Terminal: Concise summary (15-20 lines)
- File: Detailed report saved to .claude/data/reports/
- Pattern Storage: Store results for future learning
✅ Full-Stack Validation Complete (2m 34s)
📊 Component Status:
+- Backend (FastAPI): ✅ 96/100 (42% coverage -> target 70%)
+- Frontend (React): ✅ 87/100 (0 errors, 882KB bundle)
+- API Contract: ✅ 23/23 endpoints matched
🔧 Auto-Fixed (11 issues):
[PASS] Removed 5 unused TypeScript imports
[PASS] Added text() wrapper to 3 SQL queries
[PASS] Fixed 2 React Query v5 syntax
[PASS] Generated vite-env.d.ts
[WARN]️ Recommended (2 actions):
1. Increase test coverage to 70% (currently 42%)
2. Add indexes to users.email, projects.created_at
🎯 Overall Score: 87/100 (Production Ready)
📄 Detailed report: .claude/data/reports/validate-fullstack-2025-10-22.md
Saved to .claude/data/reports/validate-fullstack-YYYY-MM-DD.md:
| Issue | Detection | Fix | Success Rate |
|---|---|---|---|
| Unused TypeScript imports | ESLint | Remove import | 100% |
| Raw SQL strings | Regex | Add text() wrapper | 100% |
| ESM in .js file | File check | Rename to .mjs | 95% |
| Missing vite-env.d.ts | File check | Generate file | 100% |
| Database CASCADE | Error message | Add CASCADE | 100% |
| Missing .env.example | Env var scan | Generate file | 100% |
| Issue | Detection | Fix | Success Rate |
|---|---|---|---|
| React Query v4 syntax | Pattern match | Update to v5 | 92% |
| Missing type hints | mypy | Add annotations | 70% |
| Missing error handling | Pattern match | Add try-catch | 88% |
| Large bundle size | Size analysis | Code splitting | 85% |
| API contract mismatch | Schema compare | Generate types | 95% |
Total Score (0-100):
+- Component Scores (60 points):
| +- Backend: 20 points max
| +- Frontend: 20 points max
| +- Integration: 20 points max
+- Test Coverage (15 points):
| +- 70%+ = 15, 50-69% = 10, <50% = 5
+- Auto-Fix Success (15 points):
| +- All fixed = 15, Some fixed = 10, None = 0
+- Best Practices (10 points):
+- Documentation, types, standards
Threshold:
✅ 70-100: Production Ready
[WARN]️ 50-69: Needs Improvement
❌ 0-49: Critical Issues
Create .claude/config/fullstack-validation.json to customize:
{
"coverage_target": 70,
"quality_threshold": 70,
"auto_fix": {
"typescript_imports": true,
"sqlalchemy_text": true,
"react_query_syntax": false,
"build_configs": true
},
"parallel_validation": true,
"max_auto_fix_attempts": 3,
"skip_components": [],
"custom_validators": []
}
Before /validate:fullstack:
/learn:init - Initialize pattern learningAfter /validate:fullstack:
/analyze:quality - Deep dive into specific issues/learn:performance - Analyze performance trendsComplementary:
/monitor:recommend - Get workflow suggestions based on validation resultsValidation is considered successful when:
Validation takes too long (>5 min):
Auto-fix failures:
.claude/data/reports/ for detailed error messagesQuality score unexpectedly low:
This command automatically stores patterns for:
After 5-10 runs on similar projects, validation becomes significantly faster and more accurate.
Use Case 1: Pre-Deployment Check
/validate:fullstack
# Wait for validation
# Review score and recommendations
# If score ≥ 70: Deploy
# If score < 70: Address critical issues and re-validate
Use Case 2: CI/CD Integration
# In CI pipeline
claude-code /validate:fullstack --ci-mode
# Exit code 0 if score ≥ 70
# Exit code 1 if score < 70
Use Case 3: Code Review Preparation
/validate:fullstack
# Auto-fixes applied automatically
# Review recommendations
# Commit fixes
# Create PR with validation report
Typical execution times for different project sizes:
| Project Size | Components | Validation Time |
|---|---|---|
| Small | Backend + Frontend | 45-60 seconds |
| Medium | Backend + Frontend + DB | 90-120 seconds |
| Large | Microservices + Frontend | 120-180 seconds |
| Extra Large | Complex monorepo | 180-240 seconds |
Auto-fix adds 10-30 seconds depending on issue count.
Note: This command requires the following agents to be available:
autonomous-agent:orchestratorautonomous-agent:frontend-analyzerautonomous-agent:api-contract-validatorautonomous-agent:build-validatorautonomous-agent:test-engineerautonomous-agent:quality-controllerautonomous-agent:background-task-managerAll agents are included in the autonomous-agent plugin v2.0+.