A vibrant online community where users can engage in discussions, share content, and discover a world of diverse perspectives. Built with Angular for a sleek and dynamic front-end experience, paired with the robust Spring Boot framework and MySQL backend, Our platform offers a seamless and responsive environment for users to connect.
Angular Client repo: https://github.com/ahmedrafat-SW/reddit-ui
Registers a new user.
- Request Body:
RegisterRequest - Response:
200 OKwith message "User Registration Successful"
Verifies user account with the given token.
- Path Variable:
token(String) - Response:
200 OKwith message "Account is Activated Successfully."
Authenticates a user and returns a JWT.
- Request Body:
LoginRequest - Response:
200 OKwithAuthenticationResponse
Generates a new JWT using a refresh token.
- Request Body:
RefreshTokenRequest - Response:
201 CreatedwithAuthenticationResponse
Logs out the user and deletes the refresh token.
- Request Body:
RefreshTokenRequest - Response:
200 OKwith message "Refresh Token Successfully deleted."
Creates a new comment.
- Request Body:
CommentDto - Response:
201 CreatedwithCommentDto
Gets comments by post ID.
- Path Variable:
id(long) - Response:
200 OKwith list ofCommentDto
Gets comments by username.
- Path Variable:
name(String) - Response:
200 OKwith list ofCommentDto
Creates a new post.
- Request Body:
PostRequest - Response:
201 CreatedwithPostResponse
Gets all posts.
- Response:
200 OKwith list ofPostResponse
Gets a post by ID.
- Path Variable:
id(int) - Response:
200 OKwithPostResponse
Gets posts by subreddit ID.
- Path Variable:
id(int) - Response:
200 OKwith list ofPostResponse
Gets posts by username.
- Path Variable:
name(String) - Response:
200 OKwith list ofPostResponse
Creates a new subreddit.
- Request Body:
SubredditDto - Response:
201 CreatedwithSubredditDto
Gets a subreddit by ID.
- Path Variable:
id(int) - Response:
200 OKwithSubredditDto404 Not Foundwith message "Can't find this subreddit"
Gets all subreddits.
- Response:
200 OKwith list ofSubredditDto
Creates a vote.
- Request Body:
VoteDto - Response:
201 Created