Lesson 23 / 24
Testing APIs
Exercising endpoints by hand and in automated suites.
Postman for exploration
Postman (or Insomnia) lets you build requests visually, save them into collections, chain requests together, and share a documented workspace with a team — great for manual and exploratory testing.
curl for scripting
A one-liner that's copy-pasteable into any shell, CI job, or bug report.
curl -X POST https://api.example.com/v1/orders \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"productId": 42, "qty": 2}'Automate contract tests
Beyond manual checks, run automated tests that assert status codes and response shapes against every endpoint on every deploy — catch breaking changes before clients do.