# Get informations of one field via API

**URL:** <https://discuss.elastic.co/t/get-informations-of-one-field-via-api/78321>\
**Category:** Elasticsearch\
**Created:** [March 13, 2017, 9:54am UTC](https://discuss.elastic.co/t/get-informations-of-one-field-via-api/78321 "2017-03-13T09:54:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![froto](https://avatars.discourse-cdn.com/v4/letter/f/85f322/32.png) [@froto](https://discuss.elastic.co/u/froto)\
**Post date:** [March 13, 2017, 9:54am UTC](https://discuss.elastic.co/t/get-informations-of-one-field-via-api/78321/1 "2017-03-13T09:54:14Z")

</div>

Hey there!

I need to get all the ip addresses of the clients which are logging into the cluster via the elasticsearch api.  
Is there a way to get only the output of the "host.keyword" field?

Greetings,  
Toni

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [March 13, 2017, 9:10pm UTC](https://discuss.elastic.co/t/get-informations-of-one-field-via-api/78321/2 "2017-03-13T21:10:49Z")

</div>

Hey,

you might want to take a look at the [terms aggregation](https://www.elastic.co/guide/en/elasticsearch/reference/5.2/search-aggregations-bucket-terms-aggregation.html).

Note this might only make sense if you dont have an insane high amount of hosts to aggregate on.

--Alex

---

<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:** [April 10, 2017, 9:10pm UTC](https://discuss.elastic.co/t/get-informations-of-one-field-via-api/78321/3 "2017-04-10T21:10:52Z")

</div>

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