Skip to content

sameh-tarek/User-APi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

User API

This project is a user management API that allows users to authenticate, register, activate/deactivate users, and retrieve a list of all users. It is built using Java Spring Boot and MySQL database.

Test the API

Run In Postman

Requirements

  • Java Development Kit (JDK) 17 or above
  • MySQL Database (You can either use a local MySQL instance or connect to a remote one)

How to Run

  1. Clone the project repository from Git (if it's not already cloned).
  2. Import the project into your favorite Java IDE (e.g., IntelliJ, Eclipse, etc.).
  3. Build the project to resolve dependencies.

Features

No. Feature Description Endpoint
1. Authenticate Authenticate user credentials POST /users/auth/authenticate
2. Register Register a new user POST /users/auth/register
3. Activate User Activate a user account PUT /users/activation/{userId}
4. Deactivate User Deactivate a user account PUT /users/deactivation/{userId}
5. Get All Users Retrieve a list of all users GET /users
6. Validate Token Validate the token GET /users/auth/token/validation

ERD

erDiagram
     USERS {
    long id PK
    string email "Unique"
    string password 
    boolean enabled "Active or Not"
    }
Loading