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

from __future__ import annotations

from typing import Annotated, Any

from pydantic import BaseModel, Field
from typing_extensions import TypeAliasType

Model = TypeAliasType("Model", Any)


SimpleString = TypeAliasType("SimpleString", str)


UnionType = TypeAliasType("UnionType", str | int)


ArrayType = TypeAliasType("ArrayType", list[str])


AnnotatedType = TypeAliasType(
    "AnnotatedType",
    Annotated[
        str | bool,
        Field(..., description='An annotated union type', title='MyAnnotatedType'),
    ],
)


class ModelWithTypeAliasField(BaseModel):
    simple_field: SimpleString | None = None
    union_field: UnionType | None = None
    array_field: ArrayType | None = None
    annotated_field: AnnotatedType | None = None
