404 Not Found
404 means the origin did not find a current representation or is unwilling to disclose one.
- status codes
- client errors
Meaning
404 Not Found means the origin did not find a current representation for the
target resource or is unwilling to disclose that one exists. It does not state
whether the condition is temporary or permanent.
HTTP/1.1 404 Not Found
Content-Type: application/problem+json
Cache-Control: max-age=60
{"detail":"No current document has that identifier."}
Expected result: the response reports the target as unavailable and can be reused while fresh under the stated cache policy. The JSON adds application detail without changing the HTTP meaning.
Choose a more specific code when known
Use 410 Gone when the origin knows the resource is likely permanently
unavailable. A server can deliberately use 404 instead of an authorization-related
status to avoid disclosing existence.
Caching
404 is heuristically cacheable. Deployment checks should account for a cached 404 when a newly created route appears missing.
