You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Place `jwt_private.pem` and `jwt_public.pem`in the `secrets` directory. *(Create the `secrets` directory if it doesn't exist.)*
106
100
107
-
4. **Database Setup:**
108
101
109
-
* Configure MySQL connection in `config/config.json`.
110
-
* Create the database and run migrations:
111
-
112
-
<!-- end list -->
102
+
4. **Install Dependencies:**
113
103
114
104
```bash
115
-
npx sequelize-cli db:create
116
-
npx sequelize-cli db:migrate
105
+
npm install
117
106
```
118
107
119
-
5. **Install Dependencies:**
120
-
121
-
<!-- end list -->
108
+
5. **Database Setup:**
122
109
123
-
```bash
124
-
npm install
125
-
```
110
+
* Configure MySQL connection in `config/config.json`.
111
+
* Create the database and run migrations:
126
112
127
-
6. **Run the Server:**
113
+
```bash
114
+
npx sequelize-cli db:create
115
+
npx sequelize-cli db:migrate
116
+
```
128
117
129
-
<!-- end list -->
130
118
131
-
```bash
132
-
npm run dev # (or npm start if you have that script defined)
133
-
```
119
+
6. **Run the Server:**
134
120
121
+
```bash
122
+
npm run dev # (or npm start if you have that script defined)
123
+
```
135
124
136
-
* The server will typically start on port 5000 (configurable in `.env`).
125
+
The server will typically start on port 5000 (configurable in `.env`).
137
126
138
127
139
-
[Go to Table of Contents](https://www.google.com/url?sa=E&source=gmail&q=#table-of-contents)
128
+
[Go to Table of Contents](#table-of-contents)
140
129
141
130
## API Endpoints <a name="api-endpoints"></a>
142
131
143
-
*(Provide a few key API endpoint examples with request methods, URLs, request bodies (if needed), and response examples. This is crucial for developers wanting to use your API.)*
144
-
145
132
```
146
-
POST /auth/register - Register a new user
147
-
POST /auth/login - Login a user
148
-
GET /auth/verify/:token - Verify email
149
-
POST /auth/resend-verification - Resend verification email
150
-
# ... (add more endpoints)
133
+
POST /register - Register a new user
134
+
POST /login - Login a user with email and password
135
+
GET /login/google - Login via google
136
+
GEt /google/callback - Web hook used by google oauth server on authenticated
137
+
GET /dashboard -
138
+
POST /refresh - Generates new access token based on sent refresh token in request body
139
+
GET /verify/email/link - Send a new email verification link to registered email, requires login
140
+
GET /verify/email - Verify email
141
+
PATCH /email/new - Change email, requires login
142
+
POST /password/reset/link - Generate the password reset link
143
+
PATCH /password/reset - Reset password if forget
144
+
PATCH /password/new - Change password, requires log in
145
+
GET /logout - Log out, requires login
151
146
```
152
147
153
-
[Go to Table of Contents](https://www.google.com/url?sa=E&source=gmail&q=#table-of-contents)
0 commit comments