Pcornel
Automation · APIs

Response Headers

Cheat sheet · https://pcornel.dk/topic.php?topic=5302

Back to the Topic

Answer

Server and intermediary metadata describing representation type, caching, pagination, throttling, resource location, concurrency and correlation.

Remember

  • Response header present ≠ body correct; headers and payload are separate evidence.
  • Retry-After ≠ request safe to retry; method/idempotency still governs replay risk.
  • ETag ≠ universal version number; comparison semantics are resource- and server-specific.
  • Location header ≠ resource ready; creation or asynchronous processing may continue.

First checks

  • curl -sS -D - -o /dev/null <url> — response headers
  • Rate limit headers (X-RateLimit-*, Retry-After) — limits
  • Request ID header — support/tracing

Verify in this order

response headers → client behaviour

Where it usually breaks

Response headers describe the response and follow-up contract; they do not independently prove payload correctness or target completion.

Response Headers API boundary map

BoundaryHealthy evidenceSuspicious evidence
Caller / requestEnvironment/version, identity and exact request contract are attributableHidden defaults, wrong endpoint/version, leaked or mismatched credentials
Server / responseStatus, headers, structured body and request ID are interpreted togetherStatus-only handling, ignored error body, ambiguous async result or unsafe retry
State / proofWrite result is reconciled with resource read-back or acceptance testResponse success treated as final target success without verification
TroubleshootingFirst failed boundary is preserved, changed minimally and retestedBlind retries, credential rotation, replay or payload edits before evidence is captured

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=5302

Confirmation

Confirm action

Continue?