API / Backend Testing
Own REST/auth/JWT/schema/chaining + one strategy layer (contract+mocking+microservices pyramid). #1 cluster (69%). STOP before OAuth crypto internals, SOAP mastery, Kafka internals.
- Request/response anatomy (headers, query vs path vs body params, content negotiation)
Know Content-Type/Accept/Authorization/custom headers and where each param lives.
Live coding: 'construct this request and verify it'; whiteboard the anatomy of an HTTP request
- HTTP methods & semantics (GET/POST/PUT/PATCH/DELETE, idempotency, safe vs unsafe, PUT vs PATCH)
Name every method, its intent, which are idempotent/safe, and why it matters for retries and test design.
'Difference between PUT and PATCH? Which methods are idempotent?' (Q1 in question bank)
- Status codes cold (2xx/3xx/4xx/5xx incl. 401/403/404/409/422/429; 5xx family)
Recall the common codes without hesitation and explain the semantically tricky ones.
'Explain 401 vs 403. What does 429 mean and how do you test rate limiting?' (Q2)
- Full response verification (status + body field values + headers + response time + content-type)
Assert all four dimensions of a response, not just the status code.
'What do you assert on an API response?' (expect the four-dimension answer)
- Basic auth & API keys
Attach Basic credentials / API keys correctly and test missing/invalid key paths.
'How do you handle auth in your API suite?'
- JWT structure + testing valid/expired/tampered tokens
Decompose header.payload.signature, read claims/exp, and test around token validity.
'What is in a JWT? How do you test an endpoint needing a valid vs expired token?' (Q3)
- OAuth2 flows (client_credentials, authorization_code) + token refresh testing
Describe the flows conceptually and how you obtain/refresh/expire a token in a suite.
'Walk through the OAuth2 flow you have tested. How do you handle token refresh in your suite?' (Q4)
- RBAC / role-based access testing (same endpoint, different roles -> 200 vs 403)
Verify authorization boundaries per role, not just authentication.
'How do you test that an endpoint enforces permissions correctly?'
- JSON schema validation (types, required fields, enums)
Assert the response SHAPE, not only values, to catch contract drift.
'How do you validate a response schema, not just values? Why bother?' (Q6)
- Contract testing concept (consumer-driven, Pact broker, provider verification)
Articulate consumer-driven contracts, the broker, and why contract testing beats brittle E2E for microservices.
'Walk me through setting up contract testing between a frontend and three backend services.' (Q10, documented common Q)
- OpenAPI/Swagger as contract + spec-driven test generation (Schemathesis, property-based)
Treat the OpenAPI spec as source of truth and auto-generate/validate tests from it.
'How would you catch contract drift before it hits prod?' / spec-driven testing follow-up
- Idempotency, data cleanup/teardown, test independence
Tests are repeatable and independent; created data is torn down.
'How do you make your API tests repeatable / independent?'
- Chained/dependent requests + full CRUD lifecycle (create->capture id->get->update->delete)
Extract a value from response N and feed request N+1 across a full resource lifecycle.
'How do you do API chaining?' + live coding: full CRUD lifecycle with chaining + assertions (Q5, Section-3 live round)
- Data-driven / parametrized testing (Pytest @parametrize, Postman data files)
Drive one test across many input rows instead of copy-pasting cases.
'How do you avoid duplicating tests across many inputs?' (often folded into the live coding task)
- Negative/error testing + boundary/edge + malformed input
Systematically test invalid payloads, missing/expired auth, wrong types, boundaries, malformed JSON.
'How would you write negative tests for a POST endpoint? Give edge cases.' (Q7)
- GraphQL testing (queries vs mutations, single endpoint, 200-with-errors, field-level auth, N+1, query-depth limits)
Know how GraphQL testing differs from REST and its classic gotchas.
'GraphQL: how does testing differ from REST?' (Q15) — single endpoint, 200-with-errors, field auth
- gRPC / Protobuf testing (4 RPC types, .proto schema, status codes, backward-compat)
Name the 4 RPC types, the .proto contract, and gRPC status codes; test with grpcurl/Postman gRPC.
'Have you tested gRPC? How does it differ from REST testing?' (only in high-scale/product cos)
- WebSocket / real-time API testing
Know how to test a persistent bidirectional connection and message flow.
'How would you test a WebSocket / real-time endpoint?' (niche, fintech/crypto)
- SOAP / WSDL / XML / SOAP faults
Know SOAP exists (envelope, WSDL, XML, faults) in one paragraph; legacy.
'Have you tested SOAP services?' (only banking/insurance/telecom legacy)
- Postman (collections, environments, variables, pm.test, pre-request scripts) + Newman in CI
Fluent authoring of collections with assertions and running them headless in CI.
'Postman vs REST Assured — when each? What is Newman?' (Q8)
- Python requests/httpx + Pytest (fixtures, parametrize, session/auth) — his core
Design a clean requests+Pytest API framework fluently — his home turf.
Live coding round in Python; 'walk me through your API framework structure'
- REST Assured (given/when/then, POJO serialization) — read + speak, Java shops
Read REST Assured code and speak to its BDD structure even though he automates in Python.
'In REST Assured, explain given().when().then() and POJO serialization.' (Q9, Java shops)
- Karate framework
Know it is a BDD API-testing DSL; one-paragraph awareness.
'Have you used Karate?' (rare)
- CI/CD integration of API suites + reporting + merge gating
Run API suites automatically in the pipeline and gate merges on results.
'How do you run API tests in CI/CD?' (Q14)
- API performance basics (load/stress/spike/soak; p95/p99; Locust or k6/JMeter)
Smoke-test an SLA and speak to latency/throughput percentiles without being a perf specialist.
'How would you load-test an endpoint and assert an SLA?' (Q16)
- Mocking / service virtualization (WireMock / MSW / Postman mocks / Python responses/httpx) — stub, latency, failure injection
Stub an upstream dependency and inject errors/latency/timeouts to test resilience.
'When and how do you mock/stub a dependency?' (Q12)
- Microservices testing strategy (pyramid: unit->integration->contract->E2E; contract replaces brittle E2E; async/queue testing)
Frame API testing inside a coherent microservices test strategy — the biggest SDET-2 differentiator.
'How do you test microservices — your strategy across unit/integration/contract/E2E?' (Q11)
- UI + API + DB consistency validation (his SDET edge)
Verify a UI action triggers the correct API call and the correct DB state — triangulation few candidates do.
'How do you validate UI action -> API -> DB consistency?' (Q13)
- Event-driven / async / message-queue (Kafka) testing at a functional level
Test that producing an event yields the correct downstream state, without becoming a Kafka engineer.
'How would you test an event-driven / queue-based flow?'
- API security awareness (OWASP API Top 10: BOLA/IDOR, broken auth, excessive data exposure, mass assignment, rate-limit abuse; GraphQL introspection/depth abuse)
Recognize the top API security risks and where they belong in the pipeline.
'What API security risks do you test for?' (~10% of modern interviews)
- CI-native observability: read logs/traces to debug API failures (not just assertion messages)
Debug a failing API test using logs and distributed traces, signalling operational maturity.
'How do you debug a flaky/failing API test in CI?'
- AI-assisted / agentic API testing (generate tests from OpenAPI, LLM oracle/assertion generation, self-healing, MCP) — his lived IK edge
Speak from doing it: using LLMs/agents to generate and maintain API tests.
'How are you using AI in your testing?' (2026 interviews explicitly probe this)
- SDET system-design: design an API/microservices test framework + CI pipeline (test-infra scope)
Architect the test system, not the product — the modern SDET-2 design round.
'Design a test framework for a microservices platform' / 'architect a CI/CD pipeline for 500 daily test runs' (web 2026)