What does 'idempotency' mean for HTTP methods, and which standard methods are defined as idempotent by RFC 9110?
- A.Idempotency is only relevant for POST requests using idempotency keys; API rate limits are required to reset at midnight UTC, the boundary hard-coded into the RateLimit header spec; collections must be singular nouns in REST (/user/42), with plural forms reserved for RPC-style endpoints; idempotency keys work by hashing the request body server-side, and two different payloads with the same key both execute
- B.Idempotent means the method returns the same response every time; JSON:API and HAL are wire-incompatible with plain JSON parsers, requiring a content-type-specific decoder; 429 responses are hop-by-hop, and intermediary caches strip them before they reach the calling client; field filtering with sparse fieldsets breaks HTTP caching permanently, as caches cannot key on query parameters; the Accept-Version request header is a standard HTTP header ratified for API versioning, preferred over URL segments
- C.Only GET and HEAD are idempotent; all other methods create state changes