Skip to content

EmailStr

faststream.asyncapi.schema.info.EmailStr #

Bases: str

validate classmethod #

validate(v: Any) -> str
Source code in faststream/asyncapi/schema/info.py
@classmethod
def validate(cls, v: Any) -> str:
    logger.warning(
        "email-validator bot installed, email fields will be treated as str.\n"
        "To install, run: pip install email-validator"
    )
    return str(v)

Last update: 2023-11-13