create-thrilled-ts-express-api
v2.0.4
Published
Create production-ready Express TypeScript API projects with a single command
Maintainers
Readme
create-thrilled-ts-express-api
Create production-ready Express.js TypeScript APIs with a single command.
Quick Start
# Using npx (recommended)
npx create-thrilled-ts-express-api my-api
# Using npm
npm create thrilled-ts-express-api my-api
# Using yarn
yarn create thrilled-ts-express-api my-api
# Using pnpm
pnpm create thrilled-ts-express-api my-apiFeatures
🚀 Quick Setup - Get a production-ready API running in seconds 📦 Feature Levels - Choose from Basic, Intermediate, Advanced, or Enterprise 🔧 Configurable - Interactive setup or use command-line options 🐳 Docker Ready - Production and development Docker configurations included ⚡ Modern Stack - Express.js, TypeScript, Jest, ESLint, Prettier
Feature Levels
🟢 Basic
- Express.js server with TypeScript
- Production-ready Docker setup
- Environment configuration
- Basic health check endpoints
- ESLint and Prettier configuration
- Jest testing framework
🟡 Intermediate
- JWT-based authentication system
- PostgreSQL database integration
- Request validation with Joi
- Structured logging with Winston
- Enhanced error handling
- CORS and security middleware
🟠 Advanced
- API rate limiting
- Advanced security headers
- Prometheus metrics collection
- Swagger API documentation
- Redis caching layer
- Database migrations
🔴 Enterprise
- Advanced health checks
- Performance monitoring
- Request correlation tracking
- Audit logging system
- Graceful shutdown handling
- Load balancing ready
Usage
Interactive Mode
npx create-thrilled-ts-express-api my-apiThe CLI will prompt you for:
- Project description
- Author name
- Feature level selection
- Package manager preference (npm/yarn/pnpm)
- Git initialization
- Dependency installation
Command Line Options
npx create-thrilled-ts-express-api my-api \
--description "My awesome API" \
--author "Your Name" \
--level advanced \
--package-manager yarn \
--no-git \
--no-installAvailable Options
-d, --description <description>- Project description-a, --author <author>- Project author-l, --level <level>- Feature level: basic, intermediate, advanced, enterprise-p, --package-manager <manager>- Package manager: npm, yarn, pnpm--no-git- Skip git initialization--no-install- Skip dependency installation--yes- Use default options (non-interactive)
List Features
npx create-thrilled-ts-express-api list-featuresWhat You Get
After running the command, you'll have a complete Express.js TypeScript API with:
my-api/
├── src/
│ ├── app.ts # Express app configuration
│ ├── server.ts # Server entry point
│ ├── config/ # Configuration files
│ ├── controllers/ # API controllers
│ ├── services/ # Business logic
│ ├── routes/ # Route definitions
│ ├── middleware/ # Custom middleware
│ ├── types/ # TypeScript types
│ └── lib/ # Inlined utilities
├── docker-compose.yml # Development services
├── Dockerfile # Production container
├── Dockerfile.dev # Development container
├── .env.example # Environment template
├── .gitignore # Git ignore rules
├── README.md # Project documentation
├── package.json # Dependencies and scripts
└── tsconfig.json # TypeScript configurationAfter Creation
cd my-api
# Start development server
npm run dev
# Build for production
npm run build
# Run tests
npm test
# Start with Docker
docker-compose upRequirements
- Node.js 18+
- npm/yarn/pnpm
Templates
This tool uses the production-tested template from the be-monorepo project, which powers multiple enterprise-grade APIs.
License
MIT
