Tutorial Series
API Testing | Pytest & requests
A practical series on building a scalable, production-ready API testing framework using Python, requests, and pytest. Covers modern project setup, clean architecture, real-world API scenarios, and CI integration.
Part 1
#1 - GoRest CRUD APIs with curl
Why understanding raw HTTP with curl is the right place to start before automating API tests — CRUD calls against GoRest, the curl flags worth knowing, and where curl falls short.
Part 2
#2 - Setting Up a Python API Testing Project with uv
A walkthrough of uv — the fast, all-in-one Python package and project manager — and how to use it to bootstrap an API testing project with pyproject.toml and a lockfile.
Part 3
#3 - API Testing with requests
What actually happens under the hood when you call requests.get(), and how to write your first pytest-based API test against GoRest using the requests library.
Part 4
#4 - Pytest Concept
A grounding in pytest's core building blocks — conftest.py, fixtures, fixture scope and parametrization, and how pytest discovers and runs tests under the hood.
Part 5
#5 - Pytest API Automation Framework - Setup
Putting it all together into a 3-layer pytest API automation framework — core HTTP client, application-level business logic, and a tests layer that stays focused on assertions.