def METHOD_NAME(period: str = "today", plain: bool = False):
    """
    Return all events for the given period.
    Supported periods: all, today, yesterday, week, month
    Set plain to True to get the response as plain text.
    """
    journal = JournalManager.__get_journal()
    periods = [
        "all",
        "today",
        "yesterday",
        "week",
        "month",
    ]
    if period not in periods:
        period = "today"
    _journal = JournalManager.__filter_by_date(journal, period)
    if plain:
        _journal = yaml.dump(_journal, sort_keys=False, indent=4)
    return _journal