-
Specs Link
- Routing Structure
-
Setup
- Setup GIT
- Setup Express
- Setup DotENV
- Add Dev and Prod Scripts in Pckg.json
-
Basic Routing
- Setup Express Routes and Routes Dir
- create routes dir
- setup express router and mount to server
- create controllers dir
- add methods to routes on controller file
- mount to express router
- GET
- POST
- PUT
- DELETE
- GET /todos --> get todos
- GET /todos/1 --> get todo of id 1
- POST /todos --> add todos
- POST /todos/1 --> add todo of id 1
- DELETE /todos/1 --> remove todo of id 1
/api/v1/bootcamps
-
1.xx -> Informational
-
2.xx -> Success
-
200 -> success
-
201 -> Created and Successfull
-
204 -> No Content (when deleting)
-
300 -> redirection
-
304 -> Not modified
-
4.xx -> Client Error
-
400 -> Bad Request (give what was needed)
-
401 -> Unauthorized
-
404 -> Non Found
-
5.xx -> Server error
-
500 -> Internal Server Error