What does the HTTP 204 No Content response mean in a REST context, and when is it appropriate?
- A.The request was accepted but processing continues in the background, appropriate for long jobs, queued emails, and other actions that complete later without a result body, as the client polls a status URL returned in the Location header of the response
- B.The server created a new resource but has no body to return, appropriate for POST requests that add rows, bulk imports, and other actions that finish immediately without a Location header, since the client already knows the URL of the collection it posted to
- C.The request was successful but there is no response body to return - appropriate for DELETE operations, PUT/PATCH updates where the updated resource doesn't need to be returned, and other actions that succeed without meaningful response data
- D.The request was valid but the target resource has moved, appropriate for permanent redirects, renamed endpoints, and other changes that preserve the old path without a body, as the client follows the next hop automatically after the response arrives
Why C is correct