API Design · Junior · Question 17 of 75

Why is returning 200 OK with { "error": "not found" } a bad practice?

Explanation

Use the right status code and a consistent error body.

Further reading

Problem with a question

API Design · Junior · question 17

Test yourself

Take the API Design · Junior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz