# Logstash Subqueries

**URL:** https://discuss.elastic.co/t/logstash-subqueries/33327
**Category:** Logstash
**Created:** [October 30, 2015, 1:09am UTC](https://discuss.elastic.co/t/logstash-subqueries/33327 "2015-10-30T01:09:37Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![DefensiveDepth](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/defensivedepth/32/110034_2.png) [@DefensiveDepth](https://discuss.elastic.co/u/DefensiveDepth)
#### Post date: [October 30, 2015, 1:09am UTC](https://discuss.elastic.co/t/logstash-subqueries/33327/1 "2015-10-30T01:09:37Z")

</div>

I am working on a project that will be doing the following on a recurring basis:

1. Query an API for certain $IDs & associated metadata
2. For each $ID, hit 5 other APIs and Output each resultant dataset into ES

Trying to think through the best way to handle this, and looking for feedback--Is it possible to do all of this in Logstash or do I need to look at also using something like Python in with Logstash? (It doesn't appear that I can make a http call in a Filter plugin?....)

Thanks

---

<div class="post-metadata">

### Author: ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)
#### Post date: [October 30, 2015, 3:39am UTC](https://discuss.elastic.co/t/logstash-subqueries/33327/2 "2015-10-30T03:39:57Z")

</div>

Although it might be possible to do this using custom plugins in Logstash, it is not really what Logstash was designed to do, so I suspect it would be easier to implement in a scripting language outside Logstash.

---

<div class="post-metadata">

### Author: ![DefensiveDepth](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/defensivedepth/32/110034_2.png) [@DefensiveDepth](https://discuss.elastic.co/u/DefensiveDepth)
#### Post date: [October 30, 2015, 10:14am UTC](https://discuss.elastic.co/t/logstash-subqueries/33327/3 "2015-10-30T10:14:44Z")

</div>

@Christian_Dahlqvist This is what I figured, thanks for confirming....

---

<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: [July 6, 2017, 5:24am UTC](https://discuss.elastic.co/t/logstash-subqueries/33327/4 "2017-07-06T05:24:54Z")

</div>


