# How to query an index pattern from a Kibana's scripted fields? (Curl Command)

**URL:** <https://discuss.elastic.co/t/how-to-query-an-index-pattern-from-a-kibanas-scripted-fields-curl-command/252900>\
**Category:** Kibana\
**Created:** [October 21, 2020, 9:08pm UTC](https://discuss.elastic.co/t/how-to-query-an-index-pattern-from-a-kibanas-scripted-fields-curl-command/252900 "2020-10-21T21:08:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mr\_searchng](https://avatars.discourse-cdn.com/v4/letter/m/d07c76/32.png) [@mr\_searchng](https://discuss.elastic.co/u/mr_searchng)\
**Post date:** [October 21, 2020, 9:08pm UTC](https://discuss.elastic.co/t/how-to-query-an-index-pattern-from-a-kibanas-scripted-fields-curl-command/252900/1 "2020-10-21T21:08:19Z")

</div>

I want to add scripted fields into index with the curl command, not from the interface.  
How can I do it?

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/7/0/70abd8bec5d5237387635f00e110b27b4bd0d0c5.png)

I want it to automatically occur on this screen.

---

<div class="post-metadata">

**Author:** ![myasonik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/myasonik/32/62369_2.png) [@myasonik](https://discuss.elastic.co/u/myasonik)\
**Post date:** [October 22, 2020, 2:10pm UTC](https://discuss.elastic.co/t/how-to-query-an-index-pattern-from-a-kibanas-scripted-fields-curl-command/252900/2 "2020-10-22T14:10:29Z")

</div>

There's no officially supported way to interact with scripted fields through any sort of API. The UI is the only official way of creating on.

That said, if you really want to, a workaround is laid out in this thread: [Scripted field with curl](https://discuss.elastic.co/t/scripted-field-with-curl/106837/5)

If you'd like us to consider this feature, please file a [feature request on Github](https://github.com/elastic/kibana/issues/new?template=Feature_request.md). We do use community feedback to inform our roadmaps.

---

<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:** [November 19, 2020, 2:10pm UTC](https://discuss.elastic.co/t/how-to-query-an-index-pattern-from-a-kibanas-scripted-fields-curl-command/252900/3 "2020-11-19T14:10:47Z")

</div>

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