# Scheduling data import into elasticsearch from a api resource?

**URL:** <https://discuss.elastic.co/t/scheduling-data-import-into-elasticsearch-from-a-api-resource/32713>\
**Category:** Elasticsearch\
**Created:** [October 21, 2015, 6:19pm UTC](https://discuss.elastic.co/t/scheduling-data-import-into-elasticsearch-from-a-api-resource/32713 "2015-10-21T18:19:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![abdulbasitkay](https://avatars.discourse-cdn.com/v4/letter/a/df788c/32.png) [@abdulbasitkay](https://discuss.elastic.co/u/abdulbasitkay)\
**Post date:** [October 21, 2015, 6:19pm UTC](https://discuss.elastic.co/t/scheduling-data-import-into-elasticsearch-from-a-api-resource/32713/1 "2015-10-21T18:19:15Z")

</div>

Am working on a project where I would like to use elasticsearch to implement the search.  
But the data to be searched is gotten from an API path, So how would I index the API resource into elasticsearch and how do I auto schedule it to re-index at some intervals?

For example, I want to index ALL the documents gotten for this path [https://api.github.com/gists/public](https://api.github.com/gists/public) into elasticsearch and I want elasticsearch to automatically check and update any changes to the documents after every 48hrs.

Your help would really be appreciated.

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [October 21, 2015, 8:14pm UTC](https://discuss.elastic.co/t/scheduling-data-import-into-elasticsearch-from-a-api-resource/32713/2 "2015-10-21T20:14:19Z")

</div>

Have a look at Logstash and its [http\_poller](https://www.elastic.co/guide/en/logstash/current/plugins-inputs-http_poller.html) plugin.

---

<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 5, 2017, 11:43pm UTC](https://discuss.elastic.co/t/scheduling-data-import-into-elasticsearch-from-a-api-resource/32713/3 "2017-07-05T23:43:27Z")

</div>


