Open fhkahin opened 1 month ago
Good job and neat code - I think you are thinking about things in the right way!
Your use of different response codes shows that you are thinking about them, which is fantastic! Keep in mind that using these codes comes with its set of responsibilities - HTTP codes were designed such that the consumer of the API can have a very specific set of expectations from the response depending upon the code. For e.g. you have used a 201 when posting a message, which requires a very specific field to be set in the response header (I encourage you to find out which one). Can this field be set? If not - should you change your response status code?
Can you think of reasons in general why we should adhere to HTTP conventions? Or some reasons why you feel we shouldn't?
From Module-Servers created by Dedekind561: CodeYourFuture/Module-Servers#12
Link to the coursework
https://github.com/CodeYourFuture/Module-Node/tree/main/chat-server
Why are we doing this?
In this project, you'll be able to start building out different method endpoints that accept
POST
requests.You'll need to complete up to Level 1 in the Chat server API project.
Maximum time in hours
12
How to get help
Share your blockers in your class channel https://syllabus.codeyourfuture.io/guides/asking-questions
How to submit
There are several projects in this repo. Make a new branch for each project.