Glossary: Building APIs with FastAPI
model_dump
Also written: model_dump(exclude_none=True), model_validate, sqlmodel_update
The Pydantic method that turns a model into a dict. `exclude_none=True` leaves out fields that are `None`, which is how PATCH changes only what was sent; `model_validate` and `sqlmodel_update` copy data into table objects.