from dataclasses import dataclass from enum import Enum class Gender(Enum): MALE = "Male" FEMALE = "Female" @dataclass(frozen=True) class PeopleRequest: id: int | str name: str @dataclass(frozen=True) class GenderResponse: id: int | str gender: Gender