A police records bureau’s scripts call a network controller API and sometimes receive HTTP 401, 429, or 5xx responses. Which client behavior is most appropriate?
Select an answer to reveal the explanation.
Short Explanation
Controller APIs talk in status codes the way dispatch talks in ten-codes—401 means fix the badge, 429 means slow down, 5xx means the other end is sick. Refresh auth, back off, and only escalate when it keeps failing. Blind hammering just makes the outage louder.
Full Explanation
Robust API consumers distinguish authentication failures (401/403), rate limiting (429), and server errors (5xx). Refreshing tokens or credentials addresses 401; exponential or jittered backoff with a retry budget suits 429 and transient 5xx; persistent failures should alert operators. Tight infinite retries amplify load. Swallowing errors or disabling TLS does not improve reliability or security.