https://github.com/hafizcode02/learn-sequelize-api
Repository for learning Sequelize & JWT Auth with Express.js
https://github.com/hafizcode02/learn-sequelize-api
express-js mysql sequelize
Last synced: 7 months ago
JSON representation
Repository for learning Sequelize & JWT Auth with Express.js
- Host: GitHub
- URL: https://github.com/hafizcode02/learn-sequelize-api
- Owner: hafizcode02
- Created: 2023-12-01T12:11:03.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-12-02T14:11:25.000Z (about 2 years ago)
- Last Synced: 2025-02-03T14:47:47.280Z (about 1 year ago)
- Topics: express-js, mysql, sequelize
- Language: JavaScript
- Homepage:
- Size: 56.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# sequelize-api
Repository for Learning Sequelize & JWT Auth
For sure, this is my learning repository. if you see the code is awkwkard, bad, or not practicing clean and good code. sorry for it. I just explore code and learn from a lot of resource without concerning about that.
I will improve this code to my next project, soon.
Its include : Sequelize, Migration, Seeder, JWT Auth, Setup Swagger
```markdown
## Prerequisites
Before running the application, make sure you have the following installed on your machine:
- [Node.js](https://nodejs.org/)
- [npm](https://www.npmjs.com/) (Node Package Manager)
```
## Getting Started
1. Clone this repository to your local machine:
```bash
git clone https://github.com/Hafizcode02/sequelize-api.git
```
2. Navigate to the project directory:
```bash
cd sequelize-api
```
3. Install the dependencies:
```bash
npm install
```
## SETTING UP .ENV File
before starting running the application, set env file based on your needs:
```bash
NODE_ENV=
# Database Config
DB_DATABASE=
DB_HOST=
DB_USER=
DB_PASSWORD=
# Server Config
SERVER_ADDRESS=
SERVER_PORT=
CORS_PORT=
SECRET_KEY=
```
## Running the Application
To start the Express.js server and run the file upload example, use the following command:
```bash
npm start db-init
npm start dev
```
## API Endpoint List
```
You can see my postman collection in this repository
```