# generated by datamodel-codegen:
#   filename:  read_only_write_only_ref_with_desc.yaml
#   timestamp: 2019-07-26T00:00:00+00:00

from __future__ import annotations

from pydantic import BaseModel, Field


class AddressRequest(BaseModel):
    street: str | None = None


class Address(BaseModel):
    street: str | None = None
    city: str | None = None


class Base(BaseModel):
    base_id: int | None = None


class UserRequest(BaseModel):
    base_id: int | None = None
    name: str
    home_address: Address | None = Field(None, description="User's home address")


class User(Base):
    name: str
    home_address: Address | None = Field(None, description="User's home address")
    work_address: Address | None = None
