AntiPattern

Leaking Internal Model Fields

openapi-schema-leaks-internal-fields

Public schema/serialization accidentally includes nested or non-input fields because FastAPI/Pydantic follow the declared model types for request validation and OpenAPI generation, producing unexpected JSON shape in clients and docs (e.g., unwanted StaffMember fields or full objects).