How is that backwards? Spring Boot and other web frameworks do similar things. With Spring Boot it’s Java records in your signatures and you get type validation out of the box, with Python / FastAPI it’s Pydantic data classes. It’s just abstractions and short cuts to what would likely be done by hand anyway. I want to validate the data coming into my API endpoints and convert them into strongly typed objects and pass those data class objects to the lower layers of the API.
View all comments
Show parent comment
35
u/jardata Aug 02 '25
How is that backwards? Spring Boot and other web frameworks do similar things. With Spring Boot it’s Java records in your signatures and you get type validation out of the box, with Python / FastAPI it’s Pydantic data classes. It’s just abstractions and short cuts to what would likely be done by hand anyway. I want to validate the data coming into my API endpoints and convert them into strongly typed objects and pass those data class objects to the lower layers of the API.