# How elasticsearch create rest api? Please explain?

**URL:** <https://discuss.elastic.co/t/how-elasticsearch-create-rest-api-please-explain/193676>\
**Category:** Elasticsearch\
**Created:** [August 4, 2019, 1:17pm UTC](https://discuss.elastic.co/t/how-elasticsearch-create-rest-api-please-explain/193676 "2019-08-04T13:17:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![talbehat](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/talbehat/32/84367_2.png) [@talbehat](https://discuss.elastic.co/u/talbehat)\
**Post date:** [August 4, 2019, 1:17pm UTC](https://discuss.elastic.co/t/how-elasticsearch-create-rest-api-please-explain/193676/1 "2019-08-04T13:17:51Z")

</div>

i am new to use elasticsearch rest api.

---

<div class="post-metadata">

**Author:** ![wangqinghuan](https://avatars.discourse-cdn.com/v4/letter/w/d26b3c/32.png) [@wangqinghuan](https://discuss.elastic.co/u/wangqinghuan)\
**Post date:** [August 4, 2019, 1:34pm UTC](https://discuss.elastic.co/t/how-elasticsearch-create-rest-api-please-explain/193676/2 "2019-08-04T13:34:22Z")

</div>

Yes, Elasticsearch provides REST API which allows user to manage and query indexed data. These APIs contains Document API, Search API, Indices API, cat API and Cluster API. You can use curl command to post request to Elasticsearch, for example:  
PUT twitter/\_doc/1  
{  
"user" : "kimchy",  
"post\_date" : "2009-11-15T14:12:12",  
"message" : "trying out Elasticsearch"  
}  
Moreover, Elastic provides diffrent clients for different languages: [https://www.elastic.co/guide/en/elasticsearch/client/index.html](https://www.elastic.co/guide/en/elasticsearch/client/index.html)

---

<div class="post-metadata">

**Author:** ![talbehat](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/talbehat/32/84367_2.png) [@talbehat](https://discuss.elastic.co/u/talbehat)\
**Post date:** [August 4, 2019, 1:52pm UTC](https://discuss.elastic.co/t/how-elasticsearch-create-rest-api-please-explain/193676/3 "2019-08-04T13:52:39Z")

</div>

Can you Please explain elasticsearch rest api as developer needed?

Points:

1. How es make rest api in code, is it using jax-rs?
2. Please explain with one example?

---

<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:** [September 1, 2019, 1:52pm UTC](https://discuss.elastic.co/t/how-elasticsearch-create-rest-api-please-explain/193676/4 "2019-09-01T13:52:42Z")

</div>

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