# Adding Field Data By Api Call

**URL:** <https://discuss.elastic.co/t/adding-field-data-by-api-call/216211>\
**Category:** Beats\
**Created:** [January 23, 2020, 10:05am UTC](https://discuss.elastic.co/t/adding-field-data-by-api-call/216211 "2020-01-23T10:05:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![benedery](https://avatars.discourse-cdn.com/v4/letter/b/f19dbf/32.png) [@benedery](https://discuss.elastic.co/u/benedery)\
**Post date:** [January 23, 2020, 10:05am UTC](https://discuss.elastic.co/t/adding-field-data-by-api-call/216211/1 "2020-01-23T10:05:00Z")

</div>

Hey, im using elastic,kibana,logstash, metricbeat  
and i want to add to EVERY document i get from metricbeat, a field  
that will be set by making an api call from server and fetching data.

from my searches, i see i can set static fields and values, by using the add\_fields  
processor, or the fields in the metricbeat.yml

but i dont want static value,  
i want to add to every document a field like "timestamp" that his data  
will come from api call?  
how should i achieve this?

thank you.

---

<div class="post-metadata">

**Author:** ![jsoriano](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jsoriano/32/27920_2.png) [@jsoriano](https://discuss.elastic.co/u/jsoriano)\
**Post date:** [January 23, 2020, 4:01pm UTC](https://discuss.elastic.co/t/adding-field-data-by-api-call/216211/2 "2020-01-23T16:01:38Z")

</div>

Hey @benedery, welcome to discuss 🙂

I don't think this is possible with metricbeat, but have you tried with the [http filter plugin](https://github.com/logstash-plugins/logstash-filter-http) for Logstash?

---

<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 20, 2020, 6:04pm UTC](https://discuss.elastic.co/t/adding-field-data-by-api-call/216211/3 "2020-02-20T18:04:31Z")

</div>

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