Independent synthetic demonstration
Find what changed
in the third request.
Create, confirm, assessment. Compare the prepared requests without contacting a service or exposing credential values.
Download runnable Python sampleActual Requests preparation. Seven passing checks. No network sends.
One request breaks the fixture.
- CreateSame metadata
- ConfirmSame metadata
- AssessmentFour differences
| Field | Expected preparation | Broken preparation |
|---|---|---|
| content_type | application/json | application/x-www-form-urlencoded |
| header_names | ["accept","accept-encoding","connection","content-length","content-type","cookie","origin","referer","user-agent"] | ["content-length","content-type"] |
| cookie_names | ["demo_session"] | [] |
| payload_shape | {"$":"dict","$.application_id":"str","$.confirmed":"bool"} | {"$":"dict","$.application_id":"str","$.confirmed":"str"} |
The corrected fixture retains the same session and JSON encoding. Its metadata comparison has zero differences.
Review the method.
with requests.Session() as session:
prepared = session.prepare_request(
requests.Request("POST", url, json=payload))Run python -m unittest -v and python flow_review.py. Python 3.11+ and Requests are required.