def parse_interval_string(time_interval: str) -> int:
    """Return minutes from interval string

    Args:
        time_interval (str): time interval string

    Returns:
        int: minutes in interval
    """
    # append stop char
    time_interval = f"{time_interval}!"
    interval_minutes = 0
    if "d" in time_interval:
        days, time_interval = time_interval.split("d")
        interval_minutes += int(days) * 60 * 24
    if "h" in time_interval:
        hours, time_interval = time_interval.split("h")
        interval_minutes += int(hours) * 60
    if "m" in time_interval:
        minutes, time_interval = time_interval.split("m")
        interval_minutes += int(minutes)
    assert time_interval == "!"
    return interval_minutes