Social media app backend api with unit tests, built using Spring Boot, Hibernate.
-
User endpoints
- "/user/" POST - create new user (registration)
- "/user/{id}" GET - get user
- "/user/posts/{id}" GET - get users posts
- "/user/{id}" PUT - update user
-
Post endpoints
- "/post/" POST - create new post
- "/post/{id}" GET - get post
- "/post/{id}" PUT - update post
- "/post/{id}" DELETE - delete post
Edit applicaion.properties file
spring.datasource.url=jdbc:mysql://${MYSQL_HOST:localhost}/{db_name}
spring.datasource.username={username}
spring.datasource.password={password}
Run your database, then run the app
cd socialmediarest
./mvnw spring-boot:run
./mvnw test
This project is licensed under the MIT License - see the LICENSE.md file for details