Here, we provide a few example usages of expedantic
features, especially ones that are based on pydantic
features.
discriminated_unions.py
demonstrates the use of 'discriminated unions' feature ofpydantic
. This feature is handy when a field can be one of multiple composite types.