Production-ready multi-tenant SaaS API boilerplate built with Bun.js, TypeScript, DDD, and Clean Architecture. Features RBAC, Firebase Auth, Swagger docs, and 8 Claude Code AI skills for rapid development.
git clone https://github.com/moasadi/ddd-bun-api-boilerplate.gitHermes is a production-ready backend boilerplate demonstrating Domain-Driven Design (DDD) and Clean Architecture principles using Bun.js, TypeScript, and MongoDB. It provides a scalable foundation for building multi-tenant SaaS APIs with Firebase authentication, permission-based access control, comprehensive Swagger documentation, and built-in features like rate limiting, caching, audit trails, and health checks. The boilerplate includes two working example contexts (User and Todo management) organized as bounded domains with strict separation of concerns. Developers can use this as a reference implementation to rapidly build maintainable, production-grade REST APIs following industry best practices without reinventing architectural patterns.
Clone the repository, install dependencies with `bun install`, configure environment variables (Firebase credentials and MongoDB URI), and run `bun run dev` to start the development server. The API will be available at http://localhost:3000/api/v1 with Swagger documentation at http://localhost:3000/swagger.
Rapid development of multi-tenant SaaS backends with pre-configured architecture
Learning DDD and Clean Architecture patterns through a working example
Building secure REST APIs with Firebase authentication and permission-based access control
Creating maintainable TypeScript APIs with strict typing and zero technical debt
No install command available. Check the GitHub repository for manual installation instructions.
git clone https://github.com/moasadi/ddd-bun-api-boilerplateCopy the install command above and run it in your terminal.
Launch Claude Code, Cursor, or your preferred AI coding agent.
Use the prompt template or examples below to test the skill.
Adapt the skill to your specific use case and workflow.
Generate a production-ready API endpoint for a [COMPANY] in the [INDUSTRY] sector. The endpoint should handle [DATA] and include RBAC permissions. Use the ddd-bun-api-boilerplate with Firebase Auth and provide Swagger documentation.
```markdown
## API Endpoint: User Profile Management
### Description
Handles CRUD operations for user profiles with role-based access control (RBAC).
### Endpoint
`POST /api/users/profile`
### Request Headers
```
- `Authorization: Bearer <Firebase_ID_TOKEN>`
- `Content-Type: application/json`
```
### Request Body
```json
{
"userId": "123e4567-e89b-12d3-a456-426614174000",
"name": "John Doe",
"email": "john.doe@example.com",
"role": "admin"
}
```
### Response
```json
{
"status": "success",
"message": "User profile updated successfully",
"data": {
"userId": "123e4567-e89b-12d3-a456-426614174000",
"name": "John Doe",
"email": "john.doe@example.com",
"role": "admin"
}
}
```
### Swagger Documentation
```yaml
paths:
/api/users/profile:
post:
summary: Update user profile
description: Updates the user profile with the provided data.
security:
- firebaseAuth: []
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UserProfile'
responses:
'200':
description: User profile updated successfully
content:
application/json:
schema:
$ref: '#/components/schemas/UserProfile'
```
```Auto-transcribe meetings and generate action items
Design, document, and generate code for APIs with interactive tools for developers.
Google's app development platform with hosting and auth
Real-time collaborative writing platform
AI assistant built for thoughtful, nuanced conversation
Automate your spreadsheet tasks with AI power
Take a free 3-minute scan and get personalized AI skill recommendations.
Take free scan