https://github.com/apostolos-k/ntua-softeng-project
A project for the Software Engineering course at Ece Ntua 2022-23, in which we implement a smart questionnaire software Rest API and web interface with basic functionalities.
https://github.com/apostolos-k/ntua-softeng-project
javascript mongodb nodejs ntua-ece reactjs rest-api visual-paradigm
Last synced: 2 months ago
JSON representation
A project for the Software Engineering course at Ece Ntua 2022-23, in which we implement a smart questionnaire software Rest API and web interface with basic functionalities.
- Host: GitHub
- URL: https://github.com/apostolos-k/ntua-softeng-project
- Owner: apostolos-k
- License: mit
- Created: 2023-02-19T21:16:11.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-03-14T17:12:46.000Z (over 3 years ago)
- Last Synced: 2025-07-04T02:44:08.889Z (12 months ago)
- Topics: javascript, mongodb, nodejs, ntua-ece, reactjs, rest-api, visual-paradigm
- Language: JavaScript
- Homepage: http://localhost:3000
- Size: 1.23 MB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# IntelliQ
A project for the Software Engineering course at Ece Ntua 2022-23, in which we implement a smart questionnaire software Rest API and web interface with basic functionalities.
## Contributors
- [Karam Konstantinos](https://github.com/KostasKram)
- [Kolios Apostolos](https://github.com/apostolos-k)
## Tech Stack
**Programming Languages:** [Javascript](https://www.javascript.com/)
**Backend Development:** [NodeJS](https://nodejs.org/en/), [ExpressJS](https://expressjs.com/)
**Frontend Development:** [ReactJS](https://reactjs.org/)
**Database:** [MongoDB](https://www.mongodb.com/)
## Installation
Clone the project
```bash
git clone https://github.com/apostolos-k/ntua-softeng-project.git
```
Go to the project directory
```bash
cd ntua-softeng-project
```
Install backend dependencies
```bash
cd api-backend
npm install
```
Install frontend dependencies
```bash
cd ../frontend
npm install
```
## Run Locally
Go to the project directory
```bash
cd ntua-softeng-project
```
Start backend server (https://localhost:9103)
```bash
cd api-backend
npm start
```
Start frontend server (http://localhost:3000) on a new terminal window
```bash
cd frontend
npm start
```
## Running Tests
To run tests, run the following commands
```bash
cd api-backend
npm test
```
## Administartion Endpoints
#### End-to-end connectivity check
```text
GET /admin/healthcheck
```
#### Upload questionnaire to database
```text
POST /admin/questionnaire_upd
```
#### Reset everything in database (questionnaires, answers)
```text
POST /admin/resetall
```
#### Reset answers of a specific questionnaire
```text
POST /admin/resetq/:questionnaireID
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire |
## Operational Endpoints
#### View a questionnaire
```text
GET /questionnaire/:questionnaireID
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire |
#### View a question
```text
GET /question/:questionnaireID/questionID
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire|
| `questionID` | `string` | **Required**. ID of question |
#### Submit an answer
```text
POST /doanswer/:questionnaireID/:questionID/:session/:optionID
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire |
| `questionID` | `string` | **Required**. ID of question |
| `session` | `string` | **Required**. User identifier |
| `optionID` | `string` | **Required**. ID of answer option |
#### View answers by a session
```text
GET /getsessionanswers/:questionnaireID/:session
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire |
| `session` | `string` | **Required**. User identifier |
#### View answers by a question
```text
GET /getsessionanswers/:questionnaireID/:questionID
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire |
| `questionID` | `string` | **Required**. ID of question |
#### Use case: export answers to CSV or JSON
```text
GET /exportanswers/:questionnaireID
```
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| `questionnaireID` | `string` | **Required**. ID of questionnaire |
## Tools Used
- [Visual Studio Code](https://code.visualstudio.com/)
- [Postman](https://www.postman.com/)
- [MongoDB Compass](https://www.mongodb.com/products/compass)
- [Visual Paradigm](https://www.visual-paradigm.com/)
- [GitHub](https://github.com/)
## Info
More information about specific project sections can be found at their `README.md` located in each folder.