# Shelved alarms counter filter

**URL:** <https://forum.inductiveautomation.com/t/shelved-alarms-counter-filter/40254>\
**Category:** Ignition\
**Created:** [November 3, 2020, 6:41pm UTC](https://forum.inductiveautomation.com/t/shelved-alarms-counter-filter/40254 "2020-11-03T18:41:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![lachguerabdallah](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lachguerabdallah/32/25558_2.png) [@lachguerabdallah](https://forum.inductiveautomation.com/u/lachguerabdallah)\
**Post date:** [November 3, 2020, 6:41pm UTC](https://forum.inductiveautomation.com/t/shelved-alarms-counter-filter/40254/1 "2020-11-03T18:41:45Z")

</div>

hello, is there any way to use system.alarms.getShelvedPath with filters ?

I wanted to know the number of shelved alarms with different priorities.

thanks you

---

<div class="post-metadata">

**Author:** ![MMaynard](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mmaynard/32/3366_2.png) [@MMaynard](https://forum.inductiveautomation.com/u/MMaynard)\
**Post date:** [November 3, 2020, 7:08pm UTC](https://forum.inductiveautomation.com/t/shelved-alarms-counter-filter/40254/2 "2020-11-03T19:08:03Z")

</div>

Not built in to the call but it returns a list.  
You can loop the list and filter it that way.

```auto
paths = system.alarm.getShelvedPaths()
for p in paths:
   print "Path: %s, Shelved by: %s, expires: %s, is expired? %s, Shelved Time: %s" % (p.getPath(), p.getUser(), p.getExpiration(), p.isExpired(), p.getShelveTime())

```

---

<div class="post-metadata">

**Author:** ![lachguerabdallah](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lachguerabdallah/32/25558_2.png) [@lachguerabdallah](https://forum.inductiveautomation.com/u/lachguerabdallah)\
**Post date:** [November 5, 2020, 10:17am UTC](https://forum.inductiveautomation.com/t/shelved-alarms-counter-filter/40254/3 "2020-11-05T10:17:42Z")

</div>

```auto
for p in system.alarm.getShelvedPaths():
		
		alarmPath=p.getPath() 
		path=str(alarmPath).rsplit(':',3)[1] 
	
		tagConfig = system.tag.getConfiguration(path)
	
		print tagConfig[0]['alarms'][0]['priority'])

```
