https://github.com/ahmadammarm/bumbase-be
Back end repo for Bumbase, a blog based food recipe application
https://github.com/ahmadammarm/bumbase-be
ci-cd docker express mongodb nodejs
Last synced: 3 months ago
JSON representation
Back end repo for Bumbase, a blog based food recipe application
- Host: GitHub
- URL: https://github.com/ahmadammarm/bumbase-be
- Owner: ahmadammarm
- Created: 2025-06-29T00:20:17.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2025-07-14T16:32:46.000Z (4 months ago)
- Last Synced: 2025-07-14T21:12:08.710Z (4 months ago)
- Topics: ci-cd, docker, express, mongodb, nodejs
- Language: JavaScript
- Homepage:
- Size: 173 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Bumbase Backend
Backend project for blog based food recipe application.
      
## Prequisites
- NodeJs 18 or later
- ExpressJs
- MongoDB
- Docker (optional)
## Features
- *Middleware*: Implements JWT authentication and request rate limiting.
- *CRUD Implementation*: Implements full Create, Read, Update, and Delete (CRUD) logic for model entities.
- *Email Verification*: Uses Nodemailer with SMTP to send user verification emails.
- *Environment Configuration*: Supports environment variables configuration via .env files.
- *CORS Support*: Enables Cross-Origin Resource Sharing (CORS) configuration.
- *Deployment*: Supports containerized development and deployment via Docker.
## 📡 REST API Overview
This project provides a RESTful API for managing categories and recipes, following standard REST conventions.
### 🔐 Authentication API Routes
- POST /api/v1/auth/signup - Register a new user.
- POST /api/v1/auth/signin - Signin for the existing user.
- POST /api/v1/auth/send-verification-email - Send a verification email to the user.
- POST /api/v1/auth/verification - Verify the user's email using a verification code.
- POST /api/v1/auth/forgot-password-code - Send a password recovery code to the user's email.
- POST /api/v1/auth/recover-password - Recover a user’s password using email and verification code.
- PUT /api/v1/auth/change-password - Update the user’s password.
- PUT /api/v1/auth/update-profile - Update the user’s profile information.
- GET /api/v1/auth/current-user - Retrieve the currently authenticated user's information.
### 🗂 Category API Routes
Superadmin Only
- POST /api/v1/admin/category - Create a new category.
- PUT /api/v1/admin/category/:id - Update a category by id.
- DELETE /api/v1/admin/category/:id - Delete a category by id.
- DELETE /api/v1/admin/category - Delete all categories.
Accessible by All Roles
- GET /api/v1/category - Retrieve all categories.
- GET /api/v1/category/:id - Retrieve a category by id.
### 🍽 Recipe API Routes
Superadmin Only
- POST /api/v1/admin/recipe - Create a new recipe.
- PUT /api/v1/admin/recipe/:id - Update a recipe by id.
- DELETE /api/v1/admin/recipe/:id - Delete a recipe by id.
Accessible by All Roles
- GET /api/v1/recipe - Retrieve all recipes.
- GET /api/v1/recipe/:id - Retrieve a recipe by id.
### 🖼 Image Upload API Routes
Superadmin Only
- POST /api/v1/file - Upload an image (JPG, JPEG, PNG formats supported).
- DELETE /api/v1/file/:id - Delete an image by ID.
### 🤖 Google Gemini API Route
- POST /api/v1/gemini - Generate content for a recipe based on the user’s prompt using the Gemini AI model.
## Getting Started
1. Clone the repository:
```
git clone https://github.com/ahmadammarm/bumbase-be.git
```
2. Navigate to the project directory:
```
cd bumbase-be
```
3. Install the project dependencies:
```
npm install
```
4. Configure Environment Variable: Copy the file .env.example to .env and adjust it to your configuration:
```
cp .env.example .env
```
5. Run the project:
```
npm start
```
## Getting Started with Docker
1. Clone the repository:
```
git clone https://github.com/ahmadammarm/bumbase-be.git
```
2. Navigate to the project directory:
sh
cd bumbase-be
3. Run the Docker Compose:
```
docker-compose up
```
or run in detach mode:
```
docker-compose up -d
```
4. To stop the Docker Compose:
```
docker-compose down
```
The project will be available at:
http://localhost:8000
### 🌱 Contributing
Contributions are welcome! Feel free to fork the repository and submit a pull request.
### 🔗 Frontend Project
You can find the frontend repository here:
Bumbase Frontend