v2 P4: Typed response models
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 36
- Forks
- 7
- Avg merge
- 4m
- Merged PRs (30d)
- 2
Description
Part of the v2 roadmap (pillar P4 — largest surface area).
Extends the discipline the endpoint classes already apply to GET responses (typed properties over raw dicts) to everywhere a dict[str, Any] still leaks through — request payload construction, feed items, receipt items, webhook bodies.
Scope
- Touches every endpoint's constructor and payload-building code.
- Recommend stdlib
dataclassesover adding a validation library (pydantic/attrs), to keephttpxas the only new dependency — worth confirming before implementation starts.
Flag: #90 (exposing Monzo's raw account_type string instead of the current incomplete enum) sits squarely inside this pillar's territory but has not been confirmed as in-scope. Needs an explicit yes/no before this starts, since typed-model work on Account will touch that field regardless.
Breaking: yes
Effort: L
Phase: beta
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the endpoint constructors and payload-building code described in the issue, then confirm whether stdlib dataclasses are appropriate and whether #90 is in scope. The work is done when the listed request payloads, feed and receipt items, webhook bodies, and remaining dict[str, Any] leaks use typed models, with the breaking changes accounted for.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, backend-api-design
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100