https://github.com/puzant/portfolio-backend
Back-End Service For Portfolio
https://github.com/puzant/portfolio-backend
bullmq cloudinary-sdk cronjob ejs express mongodb mongoose mvc nodejs redis
Last synced: 2 months ago
JSON representation
Back-End Service For Portfolio
- Host: GitHub
- URL: https://github.com/puzant/portfolio-backend
- Owner: puzant
- Created: 2024-12-19T07:52:37.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-03-25T20:26:58.000Z (3 months ago)
- Last Synced: 2026-03-25T21:50:41.455Z (3 months ago)
- Topics: bullmq, cloudinary-sdk, cronjob, ejs, express, mongodb, mongoose, mvc, nodejs, redis
- Language: JavaScript
- Homepage:
- Size: 522 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Portfolio Backend








This project is a backend system built using Node.js, Express, and MongoDB to manage projects, publications, and associated media. It includes features like CRUD operations, user authentication, file uploads with Cloudinary integration, caching with Node-cache, and a server-side rendered CMS using EJS templates. This backend system is designed with modern software development practices like MVC, dependency injection, and design patterns to ensure maintainability and scalability.
Access the API at [https://portfolio-backend-gq2s.onrender.com/cms](https://portfolio-backend-gq2s.onrender.com/cms)

## API Endpoints V1
**Projects**
| **Endpoint** | **Method** | **Description** | **Data Fields** |
| -------- | ------- | ------- | ------- |
| /projects/api | GET | Get all projects | N/A
| /projects/api/projects-images | GET | Get projects images | N/A
| /projects/api/add | POST | Create new project | name, descrption, preview, link
| /projects/api/edit/:id | POST | Edit project | name, descrption, preview, link
| /projects/reorder-project | POST | Reorder Projects | priority, id
| /projects/api/delete/:id | DELETE | Delete project | id
**Publications**
| **Endpoint** | **Method** | **Description** | **Data Fields** |
| -------- | ------- | ------- | ------- |
| /publications/api | GET | Get all publications | N/A
| /publications/api/add | POST | Create new publication | title, preview, publishedDate, duration, link
| /publications/api/edit/:id | POST | Edit publication | name, descrption, preview, link
| /publications/api/delete/:id | DELETE | Delete publication | id
**Travel Images**
| **Endpoint** | **Method** | **Description** | **Data Fields** |
| -------- | ------- | ------- | ------ |
| /travel-images/api | GET | Get all travel images | N/A
| /travel-images/api/add | POST | Add new travel image | N/A
| /travel-images/api/delete/:id | DELETE | Delete travel image | N/A
## Features
- **Node.js**: The backend runtime environment.
- **Express**: Lightweight and flexible web framework.
- **MongoDB**: Database for storing and managing dynamic content.
- **EJS Templates**: Render the views of the CMS, enabling dynamic server-side content generation.
- **CRUD operations**: Get/ Add / Edit / Delete over projects, publications, travel images
- **Cloudinary SDK**: Used for fetching and managing images stored in Cloudinary.
- **Deployed on Render**: Easily accessible and scalable deployment.
- **WebP Image Format**: Optimized image format for faster load times.
- **Cron Job**: Set to run every 13 minutes, sending an HTTP request to the API to prevent it from entering hibernation mode.
- **Node Cache**: Caches Cloudinary images with a 12-hour TTL, improving performance and reducing redundant requests.
## Dependencies
- **Node.js**: Runtime environment
- **Express**: Web framework
- **Cloudinary SDK**: Cloud image management