https://github.com/varshithsoma/results-backend
This backend processes Excel sheets, extracts student data, and stores it in a MongoDB database. It also provides a set of RESTful APIs that allow the frontend to fetch and display result.
https://github.com/varshithsoma/results-backend
expressjs jwt-authentication mvc-architecture nodejs onrender-deploy xlsx
Last synced: 5 months ago
JSON representation
This backend processes Excel sheets, extracts student data, and stores it in a MongoDB database. It also provides a set of RESTful APIs that allow the frontend to fetch and display result.
- Host: GitHub
- URL: https://github.com/varshithsoma/results-backend
- Owner: VarshithSoma
- Created: 2024-10-09T11:38:45.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-01T14:14:22.000Z (12 months ago)
- Last Synced: 2025-04-12T16:13:25.614Z (12 months ago)
- Topics: expressjs, jwt-authentication, mvc-architecture, nodejs, onrender-deploy, xlsx
- Language: JavaScript
- Homepage: https://snist-hzjb.onrender.com
- Size: 1.25 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SNIST Results - Backend
## Overview
This is the backend for the SNIST Results project. It processes Excel sheets, extracts student data, and stores it in a MongoDB database. The backend also provides REST APIs for the frontend to fetch and display results.
## Tech Stack
- **Node.js** - Backend runtime environment
- **Express.js** - Web framework for building APIs
- **MongoDB** - Database for storing student results
- **Mongoose** - ODM for MongoDB
- **xlsx (npm package)** - To process Excel sheets
- **Cors & dotenv** - To handle cross-origin requests and environment variables
## Features
- Upload and process Excel sheets (.xlsx) containing student results.
- Store processed student data in a MongoDB database.
- Provide RESTful APIs to retrieve student results.
- Handle errors and invalid input gracefully.
## Installation
1. Clone the repository:
```bash
https://github.com/VarshithSoma/Results-Backend
cd Results-Backend
```
2. Install dependencies:
```bash
npm install
```
3. Set up the environment variables:
- Create a `.env` file in the root directory.
- Add the following:
```
PORT=8000
DATABASE_LOCAL=mongodb://127.0.0.1:27017/results
DATABASE_BUILD=your_production_mongodb_uri
DATABASE_PASSWORD=your_database_password
JWT_COOKIE_EXPIRES_IN=90
JWT_SECRET=your_jwt_secret
JWT_EXPIRES_IN=90d
```
4. Start the server:
```bash
npm start
```
## Folder Structure
```
/snist-results-backend
│-- /Controllers # API controllers for handling business logic
│-- /Models # Mongoose models for database schema
│-- /data # Data-related files (if any)
│-- /dev # Development-related configurations or scripts
│-- /routes # API route handlers
│-- /utils # Utility functions
│-- .gitignore # Git ignore file
│-- app.js # Main application file
│-- package.json # Project dependencies and scripts
│-- package-lock.json # Dependency lock file
│-- server.js # Entry point of the application
```