Skip to main content

What are the key things you validate in an API test?

  • API validation
  • response verification
  • fundamentals

Answer it first, then compare. Nothing here is saved or scored.

Model answer

Five layers of validation: (1) Status code, correct for the scenario (200, 201, 400, 404, etc.). (2) Response body - correct data, structure, and types. (3) Headers - content-type, cache-control, security headers. (4) Performance - response time within SLA. (5) Error handling - proper error messages and codes for invalid inputs. Also validate idempotency for PUT/DELETE and pagination for list endpoints.

What interviewers listen for

  • Schema-first thinking
    You validate response shape before you assert on values, every time.
  • Status-code literacy
    You can defend why 401 vs 403 vs 422 matters for the consumer.
  • Contract awareness
    You know when consumer-driven contract tests beat end-to-end checks.
  • Auth fluency
    You can describe rotating tokens across parallel workers without secrets in logs.

See all 35 api testing questions

Written by , Senior QA Automation Engineer, 50+ QA candidate interviews conductedLast updated July 2026