REST API STUDENT
Spring boot Docker Hub MongoDB Junit
Step 1: clone project
git clone https://github.com/medchelios/api-students.gitStep 2: up image
./docker-compose upStep3: build package and run project
./mvn package && java -jar target/api-etudiants-0.0.1-SNAPSHOT.jarStep4: test all endpoint
GET ALL
For Example you can use file data.json
curl --location --request GET 'http://localhost:8081/students/'SAVE
curl --location --request POST 'http://localhost:8081/students/save' \
--header 'Content-Type: application/json' \
--data-raw ' {
"name": "Mohamed",
"studentNumber": 115,
"email": "[email protected]",
"courseList": [
"Docker",
"Mongodb",
"TDD"
],
"gpa": 5.0
}'DELETE
curl --location --request DELETE 'http://localhost:8081/students/delete/41'You find other endpoint on controller StudentRestController
Thanks You