This repository contains a Spring Boot application that manages user profiles and user-related functionalities for a specific application. This service integrates user authentication from Authentication Service. This repository also contains the CI/CD Pipeline for building and deploying the service to Dockerhub and deployment repository at https://github.com/MiguelCastilloSanchez/helm-chart-app-services
Endpoint: POST /user/get-basic-profiles
Description: Retrieves basic profile information (ID, name, and thumbnail) for a list of users.
Request Body:
[
"userId1",
"userId2"
]
Endpoint: GET /user/{userId}
Description: Retrieves complete profile information for a specific user.
Path Parameter:
userId
(String): ID of the user whose profile is being requested.
Endpoint: POST /user/update-user
Description: Updates the information of the authenticated user.
Headers:
Authorization: Bearer <token>
Request Body:
{
"instagramProfile": "string",
"spotifyProfile": "string",
}
Endpoint: POST /user/update-profile-picture
Description: Updates the profile picture of the authenticated user.
Headers:
Authorization: Bearer <token>
Request Parameter:
image
(MultipartFile): The profile picture file to upload.
Endpoint: GET /user/get-profile-picture
Description: Retrieves the profile picture of the authenticated user.
Headers:
Authorization: Bearer <token>
Endpoint: DELETE /user/delete
Description: Deletes the authenticated user’s account.
Headers:
Authorization: Bearer <token>
Endpoint: DELETE /user/{userId}/remove
Description: Allows an admin to remove any user from the system.
Path Parameter:
userId
(String): ID of the user to be removed.
Endpoint: POST /user/get-all-profiles
Description: Retrieves basic profile information (ID, name, and thumbnail) for all users.
- Authorization: Some endpoints require an
Authorization
header with a valid JWT token. - Validation: Inputs are validated, and appropriate error messages are returned for invalid requests.
- Roles: Specific endpoints are restricted to users with the
ADMIN
role.