Employee ID: T2551
Employee Name: Varun Sharma
This project contains employee informations and perform CRUD APIs
####Install
brew install redis
####Run the server
brew services start redis
redis-cli MONITOR
###Run Tests
mvn test
###Run the application
mvn spring-boot:run
Alternatively, you can also navigate to target directory and run the application using
cd target
java -jar emp-api-0.0.1-SNAPSHOT.jar
curl http://localhost:8083/api/employee
curl http://localhost:8083/api/employee/id/{{empId}}
curl http://localhost:8083/api/employee/dept/{{deptId}}
curl -X POST -H "Content-Type:application/json" \
-d '{"name":"Varun","email":"[email protected]","dob":"2000-16-10","deptId":1}' \
http://localhost:8083/api/employee
curl -X PUT http://localhost:8083/api/employee/<id>?name=<name>&email=<email>&deptId=<deptId>
curl -X DELETE http://localhost:8083/api/employee/<id>
curl http://localhost:8083/api/department
curl http://localhost:8083/api/department/{{deptId}}
curl -X POST -H "Content-Type:application/json" \
-d '{"name":"FASTag","manager":"abc"}' \
http://localhost:8083/api/department
curl -X PUT http://localhost:8083/api/department/<id>?name=<name>&manager=<manager>
curl -X DELETE http://localhost:8083/api/department/<id>