# Need to execute watcher alert based on each element of array

**URL:** <https://discuss.elastic.co/t/need-to-execute-watcher-alert-based-on-each-element-of-array/262592>\
**Category:** Kibana\
**Created:** [January 29, 2021, 5:24am UTC](https://discuss.elastic.co/t/need-to-execute-watcher-alert-based-on-each-element-of-array/262592 "2021-01-29T05:24:58Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sumit\_Kumar1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sumit_kumar1/32/43471_2.png) [@Sumit\_Kumar1](https://discuss.elastic.co/u/Sumit_Kumar1)\
**Post date:** [January 29, 2021, 5:24am UTC](https://discuss.elastic.co/t/need-to-execute-watcher-alert-based-on-each-element-of-array/262592/1 "2021-01-29T05:24:59Z")

</div>

Need to execute watcher alert based on each element of array.

I am using chain input . First search provides me list of array . So, for each element of the array i need to make a search on each iteration .  
My result of first search -

` "type" : "transform", "status" : "success", "payload" : { "_value" : [202101250153300972, 202101250210130121, 202101250245310739, 202101250251420866, 202101250251530386, 202101250252030474, 202101250317200938, 202101250429130705, 202101250627000149, 202101250650530483, 202101250708140261, 202101250821180950, 202101250915430122, 202101250915430934, 202101250957000827, 202101250957060145, 202101250957060989, 202101250957070139, 202101251009390352, 202101251014560961, 202101251041290577, 202101251043380386, 202101251052570813, 202101251106280277, 202101251120080434]`

Now using these elements one by one how should i use them .

---

<div class="post-metadata">

**Author:** ![mattkime](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mattkime/32/43522_2.png) [@mattkime](https://discuss.elastic.co/u/mattkime)\
**Post date:** [January 29, 2021, 3:39pm UTC](https://discuss.elastic.co/t/need-to-execute-watcher-alert-based-on-each-element-of-array/262592/2 "2021-01-29T15:39:34Z")

</div>

Hello @Sumit_Kumar1

The data you posted - is that an elasticsearch document? Can you make an alert based on that document or do you need to perform further processing?

Thanks,  
Matt

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [February 26, 2021, 3:40pm UTC](https://discuss.elastic.co/t/need-to-execute-watcher-alert-based-on-each-element-of-array/262592/3 "2021-02-26T15:40:15Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
