Skip to main content
REST and service testing

API Testing Questions

Prepare for API testing interviews with practical REST scenarios, status-code reasoning, schema checks, auth coverage, and automation-ready test ideas.

Request and response basics

Practice reading endpoints, methods, headers, query params, request bodies, response bodies, and status codes.

  • GET, POST, PUT, PATCH, DELETE
  • 2xx, 3xx, 4xx, and 5xx responses
  • Headers and content types

Validation and assertions

Check the exact behavior users depend on, including schema shape, required fields, business rules, and error messages.

  • JSON schema checks
  • Required field behavior
  • Business rule assertions

Negative testing

Cover invalid payloads, missing auth, expired tokens, unsupported methods, rate limits, and boundary cases.

  • Missing or bad tokens
  • Invalid payloads
  • Boundary and limit testing

Automation readiness

Explain how API checks support CI, smoke tests, data setup, cleanup, environment variables, and release gates.

  • Postman collections
  • CI smoke checks
  • Test data cleanup

Scenario questions

A POST request returns 200 but does not create data. What should you verify?

Check the expected status contract, response body, database or follow-up GET result, validation rules, and server logs if available.

An endpoint sometimes returns 500 in CI. How do you debug it?

Compare payloads, auth state, environment config, dependent services, test data collisions, rate limits, and retry or timeout behavior.

How do you test an authorization bug safely?

Use approved test accounts with different roles and verify both allowed and denied actions without touching real customer data.

What are common API testing interview questions?

Common questions cover HTTP methods, status codes, REST conventions, headers, authentication, schema validation, negative tests, and how API tests run in CI.

Which tool should beginners use for API testing?

Postman is a friendly starting point for manual exploration, while automated checks can later move into frameworks such as Playwright API tests, REST Assured, or custom CI scripts.

How is API testing different from UI testing?

API testing checks service behavior directly through requests and responses. UI testing checks what the user sees and does in the browser or app.