conditional request
If-Match, If-None-Match, If-Modified-Since
a request carrying a precondition field, which the server evaluates before acting — proceeding only if it passes
A conditional request adds an If-* field that the server tests first. The two workhorses:
- If-None-Match: "<etag>" — "only send the body if it changed" (cache revalidation → 304 Not Modified).
- If-Match: "<etag>" — "only apply my PUT/DELETE if nothing changed since I last read it" (lost-update protection → 412 Precondition Failed).
Preconditions are evaluated in a defined order (RFC 9110 §13.2.2), which matters when a request carries more than one.