← Quiz: API Design: all 15 questions
Quiz: API Design · Question 9 of 15
A server returns 200 OK with the body {"error": "payment failed"}. What is the main problem?
A server returns 200 OK with the body {"error": "payment failed"}. What is the main problem?
- A.The body is too small
- B.Clients and monitoring see a success code and cannot tell the request failed
- C.200 is only allowed for GET
- D.JSON cannot contain the word error
Answer & explanation
Correct answer: Clients and monitoring see a success code and cannot tell the request failed
Status codes are how tools count failures; a failed request needs a 4xx or 5xx code.
Can you get the rest right without peeking?
Take the timed Quiz: API Design quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →