add range and with_total parameters to alarms method