Software Testing / Learning brief

Tom turns a manual request into a script

What this means in plain language

Tom has sent an add-a-task request by hand. Mei asks for a script anyone can run. Tom checks the status and body, chains a value, makes the data fresh, cleans up, and breaks the check on purpose.

Understand the full idea, step by step

A cook who tastes as they go can make a good soup once. A recipe card lets a friend make the same soup tomorrow, with the same amounts and the same steps.

Daily List has an API, and Tom has sent a request by hand. Mei now wants a script that can be rerun with controlled setup and understandable results. A changed app can legitimately make the check fail.

PLAIN WORDS · 1 in this section
rerun
run again, or an act of running again

Evidence & review

REVIEWED 2026-11-07

The date on this lesson is when it went up on Payments Signal, not when its material was written — most of these were brought across from an earlier catalogue in a single run, which is why so many of them share a date. What the lesson says about the world is dated by the review above and by the sources below it.

Building a first scripted API check as taught in this academy, on a made-up app and made-up requests.

What this brief simplifies: Fiction labelled SYNTHETIC / TRAINING ONLY. Sources were seen only as search excerpts. The code snippets are short teaching sketches, and each tool's own pages are the place to check exact syntax. The separately added Python practice was executed on 7 November 2026 against the unchanged isolated training server using explicitly recorded versions. This does not retroactively certify older unexecuted Java/tool sketches or live-app behavior.

Sources for this brief — 12 sources
  1. Market practice

    Write scripts to test API response data in Postman (Postman Learning Center) ↗ — Postman · Per the search excerpt, a test is written with a name and a function, and it fails if any check inside fails; checks use the Chai expect style (search excerpt, page not opened)

    Per the search excerpt, a test is written with a name and a function; the test fails if any check inside fails. Checks use the Chai expect style. Practitioner guidance, not a standard. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  2. Market practice

    Postman test script examples (Postman Learning Center) ↗ — Postman · Shows a named test that checks the response status code, and a test that reads the body as JSON and checks a field (search excerpt, page not opened)

    Vendor documentation. Per the search excerpt, it shows a named test that checks the response status code, and a test that reads the body as JSON and checks a field. Vendor documentation for one tool. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number; read as a search excerpt only. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  3. Market practice

    Store and reuse values using variables (Postman Learning Center) ↗ — Postman · Per the search excerpt, variables come in five scopes: global, collection, environment, data and local; the narrowest scope wins (search excerpt, page not opened)

    Per the search excerpt, variables come in five scopes: global, collection, environment, data and local; the narrowest scope wins. Practitioner guidance, not a standard. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  4. Market practice

    Quickstart (Requests documentation) ↗ — Python Requests · Shows reading the status code, calling json() to decode the body, raise_for_status() for error codes, and that a decoded body does not mean the call succeeded (search excerpt, page not opened)

    Shows reading the status code, calling json() to decode the body, raise_for_status() for error codes, and that a decoded body does not mean the call succeeded. Practitioner or vendor guidance, not a standard unless stated. · Checked 2026-11-06

    Primary publisher body opened and relevant sections read on 6 November 2026; selected-section reading, not a claim every page or external link was read. See docs/research/v16-testing-automation-literacy-audit-20261106.md for exact sections, version and limitations.

  5. Market practice

    Get started (pytest documentation) ↗ — pytest development team · pytest finds test functions whose names start with test_ in files named test_.py or _test.py, and a plain assert statement is enough because pytest reports the values behind a failed assert (search excerpt, page not opened)

    Says pytest finds test functions whose names start with test_ in files named test_.py or _test.py, and that a plain assert statement is enough because pytest reports the values behind a failed assert. Official language or tool documentation. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  6. Market practice

    Usage (Representational State Transfer (REST) Assured library wiki) ↗ — Representational State Transfer (REST) Assured project (GitHub wiki) · A Java library for testing web APIs with a given, when, then layout: given holds the request set-up, when sends the request and then checks the reply (search excerpt, page not opened)

    Per the search excerpt, a Java library for testing web APIs with a given, when, then layout: given holds the request set-up, when sends the request and then checks the reply. Practitioner guidance, not a standard. · Checked 2026-11-06

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail. V27 supplement, 6 November 2026: relevant primary page sections actually opened; implementation-specific current product guidance, not universal standard. See full V27 audit for version and access scope.

  7. Market practice

    What is the easiest tool to learn for API Automation Testing? (Ministry of Testing forum thread) ↗ — Ministry of Testing · Members mostly name Postman as the easiest start, with a low learning curve and little code, and point to a Java library for testers who can program (search excerpt, page not opened)

    Forum thread. Per the search excerpt, members mostly name Postman as the easiest start, with a low learning curve and little code, and point to a Java library for testers who can program. Practitioner opinion, not a standard. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number; read as a search excerpt only. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  8. Market practice

    HyperText Transfer Protocol (HTTP) response status codes (Mozilla developer docs) ↗ — Mozilla (developer documentation) · Status codes come in five classes: informational, success, redirection, client error and server error (search excerpt, page not opened)

    Per the search excerpt, status codes come in five classes: informational, success, redirection, client error and server error. Pages for 400, 401, 403, 404 and 500 describe each. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  9. Simplified educational illustration

    Payments Signal editorial teaching models — Payments Signal

    This site's own simplified teaching models. · Checked 2026-07-12

    Used wherever diagrams, scenarios, figures, or example values are didactic constructions rather than sourced facts; every such use carries a simplifications disclosure. All people, companies, banks, and list entries in examples are fictional.

  10. Market practice

    Quickstart (Requests documentation) ↗ — Python Requests · Complete Requests2.34.2 Quickstart body actually read 7 November 2026: response/JSON/status distinctions and connect/read inactivity timeout behavior. Runnable exercise separately executed with Requests2.32.5, not a latest-version claim.

    Shows reading the status code, calling json() to decode the body, raise_for_status() for error codes, and that a decoded body does not mean the call succeeded. Practitioner or vendor guidance, not a standard unless stated. · Checked 2026-11-06

    Primary publisher body opened and relevant sections read on 6 November 2026; selected-section reading, not a claim every page or external link was read. See docs/research/v16-testing-automation-literacy-audit-20261106.md for exact sections, version and limitations.

  11. Market practice

    pytest fixture guide ↗ — pytest-dev contributors · Current pytest requesting/scope and complete teardown/finalizer units actually read 7 November 2026; test assertion failure still runs yielded fixture teardown. Setup failure before a known created ID is separately limited.

    Scopes and parameter caching; yield-setup failure; broader/narrower dependency lifetimes. Product/configuration-specific guidance; not a universal team practice. · Checked 2026-11-07

    Selected actual primary passages read, including the specific fixture/marker/collection boundaries described. Daily List rules, people and paths are synthetic; no pytest/xdist execution or complete production fixture design is claimed. Live documentation has no fixed edition claimed.

  12. Market practice

    How to invoke pytest ↗ — pytest · Complete current pytest invocation guide body actually read 7 November 2026: node IDs and -k expressions/name matching. Older source registry excerpt notes retain their historical scope; runnable exercise separately executed with pytest8.4.2.

    Tests are selected by node id with :: and by name expression with -k. · Checked 2026-10-19

    Found through a web search; the page was not opened (search excerpt, page not opened). Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

Learn this properly

START HEREYour first scripted API check: from a manual request to a repeatable testYou can already send an API request by hand. Learn how to turn one into a script that checks the reply, uses its own data, cleans up, and gives the same answer every run.Opens at L0 Explain simply · about 20 min

Related briefs