Commit Graph

60 Commits

Author SHA1 Message Date
7aab149bb2 refactor: remove role property from User model and update related logic for role handling 2025-01-06 11:31:57 +01:00
e3365cdff7 feat: change package name 2025-01-05 01:18:16 +01:00
2d35fc413c refactor: enhance error messages and streamline time validation in createRoom method 2025-01-04 20:47:13 +01:00
95ccfc884c feat: add validation to prevent class creation for past dates 2025-01-04 19:04:48 +01:00
341faa3bb0 refactor: streamline time validation logic in ClassService 2025-01-04 19:02:41 +01:00
8e63816616 refactor: improve code formatting and error messages in ClassService 2025-01-04 18:53:46 +01:00
db88a24028 feat: add user profile retrieval to Me module 2025-01-02 22:11:13 +01:00
7fc3e14612 feat: add production start script for Docker deployment 2025-01-02 21:08:28 +01:00
1c19158771 fix: update Docker build script to remove no-cache option for improved performance 2025-01-02 19:54:23 +01:00
3319cc0789 feat: add Docker build script to package.json for containerized deployment 2025-01-02 19:48:14 +01:00
d66a2c2c35 feat: add Me module with service and controller for user-specific class and room management 2025-01-02 18:34:17 +01:00
3577925932 refactor: Simplify jwksRsa import and enhance username extraction logic in JwtAuthGuard 2025-01-02 18:33:53 +01:00
M1000fr
7b43387a0c refactor: Update ping response message format to include the current date and time in French locale 2024-12-13 18:00:55 +01:00
M1000fr
8f51c04cad refactor: Update AUTH_USERNAME_FIELD in .env.example 2024-12-13 13:36:15 +01:00
M1000fr
41a9bfad98 refactor: remove providerId from User 2024-12-13 13:32:12 +01:00
M1000fr
e52c9acf2d feat: remove unused packages, config 2024-12-12 22:06:35 +01:00
M1000fr
bc4dcc26ef refactor: Update user creation logic in UserService 2024-12-12 16:57:28 +01:00
M1000fr
28e42b2248 feat: Add error handling for invalid token in JwtAuthGuard 2024-12-11 18:51:48 +01:00
M1000fr
80ce7d7f16 feat: switch to JWKS verification 2024-12-11 00:41:53 +01:00
M1000fr
0ae3da74a0 refactor: Update Node.js base image in Dockerfile 2024-12-10 14:41:30 +01:00
M1000fr
006fe8cb74 feat: Add Swagger API documentation to AuthController and ClassController 2024-12-10 14:33:43 +01:00
M1000fr
161b01d8cb chrore: Integrate Class CRUD & Service
refactor: user CRUD & Service
2024-12-10 14:19:27 +01:00
M1000fr
238b01f5f3 feat: Add Class module and controller
Add a new Class module and controller to handle CRUD operations for classes. This includes creating a new file for the Class controller, as well as creating the Class module and updating the app.module.ts file to include the Class module.
2024-12-10 11:40:04 +01:00
3d131193b6 ref: format prettier 2024-12-06 01:15:40 +01:00
38e491dc13 refactor: Remove unnecessary comment in Oauth2Strategy constructor 2024-12-06 01:03:30 +01:00
dd486229c4 feat: implement oauth2 2024-12-06 01:00:32 +01:00
M1000fr
76093fb5e8 refactor: Update base Node.js image to Alpine version in Dockerfile 2024-12-05 13:29:49 +01:00
M1000fr
63176d1863 feat: change Role decorator to accept multiples roles 2024-12-05 12:15:28 +01:00
M1000fr
d9cc0db0d2 ref: just add another test route 2024-12-05 00:12:51 +01:00
M1000fr
8245f4ddfc ref: use nestjs-prisma for error handling
- Use GlobalFilters created by nestjs-prisma
- Rename user/users routes
2024-12-03 17:35:11 +01:00
M1000fr
c2028d9309 ref: remove unused params 2024-12-02 19:24:30 +01:00
M1000fr
2e22e0bb4d refactor: Update JWTStrategy to extend PassportStrategy with "jwt" name 2024-12-02 16:57:20 +01:00
M1000fr
a6d24cee9d ref: format with prettier 2024-12-02 16:55:44 +01:00
M1000fr
ccf496a5d9 ref: remove majs on folder 2024-12-02 16:41:13 +01:00
M1000fr
ab51873493 feat: Implement refresh jwt token 2024-12-02 16:39:18 +01:00
M1000fr
6521da705b ref: move dto folder to Dto 2024-12-02 15:39:14 +01:00
M1000fr
f3c5673c75 feat: add swagger 2024-12-02 15:25:36 +01:00
M1000fr
b07b6082e4 refactor: Update Prisma schema to include createdAt field in User and RoomMessage models 2024-12-02 14:38:01 +01:00
M1000fr
3301b365f9 feat: Add Docker configuration files
Add .dockerignore, Dockerfile, and docker-compose.yml files to configure Docker for the project.
2024-12-02 14:37:58 +01:00
M1000fr
1988673f80 feat: add ConfigService with Env validator
- add Role decorator
2024-12-02 13:57:47 +01:00
M1000fr
a95ed47302 refactor: Update Prisma schema to include UserMessage, Class, Room, and RoomMessage models 2024-11-29 00:26:37 +01:00
M1000fr
61bd5cd862 feat: Add Discord and JWT authentication guards
- Added `DiscordAuthGuard` to handle Discord authentication
- Added `JwtAuthGuard` to handle JWT authentication

These guards are used in the `auth.controller.ts` and `user.controller.ts` files to protect routes that require authentication.
2024-11-28 16:11:16 +01:00
M1000fr
b40249fdfb feat: Add class-transformer and class-validator packages
- Added "@nestjs/mapped-types" package to package.json
- Added "class-transformer" and "class-validator" packages to package.json
- Imported ValidationPipe from "@nestjs/common" in main.ts and added it as a global pipe
- Added validation decorators to CreateUserInput, SetUserPasswordInput, and UpdateUserInput classes
- Created UserController with create, findAll, and removeUser methods
- Updated UserEntity class with @Exclude decorator for password field
- Updated UserModule to include UserController
- Updated UserService to use class-transformer for mapping Prisma entities to UserEntity class
- Updated UserService to return UserEntity instances instead of Prisma entities
- Updated UserService to handle NotFoundException for setPassword and remove methods
2024-11-28 15:53:38 +01:00
m1000
38105c3d43 Merge pull request 'feat: remove graphql due to complexity of stack' (#2) from remove/graphql into feature/auth
Reviewed-on: #2
2024-11-28 14:33:19 +00:00
M1000fr
e9cc7fef02 feat: remove graphql due to complexity of stack 2024-11-28 15:32:44 +01:00
M1000fr
fbf7272526 feat: add authentication using Discord oauth2 and JWT
Temporarily disabling GraphQL using Mercuris due to moving to Express (previously fastify)
2024-11-28 15:25:01 +01:00
M1000fr
782698788b Ref: file paths 2024-11-28 14:28:41 +01:00
m1000
1bc25f6eaa Merge pull request 'Integrate GraphQL' (#1) from feature/graphql into feature/auth
Reviewed-on: #1
2024-11-28 13:19:28 +00:00
M1000fr
bdd4561cba ref: add apache license in package.json 2024-11-26 20:31:54 +01:00
M1000fr
2cd37b30a7 ref: remove unused packages 2024-11-26 19:36:00 +01:00