Skip to content

ahmetcihank/docshift

Repository files navigation

Tech Stack

Java 17 , Postgre Database, Spring Boot, Junit 5 , LomBok Library

For starting app:

  • Clone the project
  • docker network create docshiftnetwork
  • create package: mvn clean install -Dmaven.test.skip=true -->Skip test because app.prop file is empty i provided credentials in docker-compose file
  • then simply: docker-compose up

Api Documentation

  • Profile Create
    Http Method -> POST
    http://localhost:8080/profile/create
    Request Body : { "gender":"MALE", "phoneNumber":"123123", "address":"address", "username":"cihan" }
    Response Body: { "message": "userPP: cihan has been created", "timestamp": 1642340948836 }



  • User Create
    Http Method -> POST
    http://localhost:8080/user/create
    Request Body : { "name":"denem112e", "lastName":"denemee12", "username":"cihan" }
    Response Body: { "message": "user: denem112e has been created", "timestamp": 1642357178553 }



  • All User With Profile
    Http Method -> GET
    http://localhost:8080/user/allusersWithProfiles


    Response Body: [ { "id": 1, "username": "cihan", "name": "jack", "lastname": "joe", "createdDate": 1642340931998, "phoneNumber": "123123", "address": "address", "gender": "MALE", "dateOfBirth": null } ]



  • All Users
    Http Method -> GET
    http://localhost:8080/user/allusers


    Response Body: [ { "id": 1, "username": "cihan", "name": "jack", "lastname": "joe", "createdDate": 1642340931998 }]



  • User by userName
    Http Method -> GET
    http://localhost:8080/user/{username}
    Response Body: [ { "id": 1, "username": "cihan", "name": "jack", "lastname": "joe", "createdDate": 1642340931998 } ]

  • DELETE by userName
    Http Method -> DELETE
    http://localhost:8080/user/delete/{username}
    Response Body: { "message": "user: cihan has been deleted", "timestamp": 1642341007581 }

  • UPDATE user
    Http Method -> PUT
    http://localhost:8787/user/update
    Request Body : { "id":2, "name":"jack", "lastName":"joe", "username":"cihan", "gender":"MALE", "phoneNumber":"123123", "address":"addressupdated", "dateOfBirth":"2012-12-01" }
    Response Body: "User has been updated"

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published