-
Notifications
You must be signed in to change notification settings - Fork 0
Elasticsearch REST APIs
Adrian Wilke edited this page Dec 7, 2020
·
6 revisions
- https://www.elastic.co/guide/en/elasticsearch/reference/current/rest-apis.html
- https://www.elastic.co/guide/en/elasticsearch/client/java-rest/master/java-rest-high.html
- https://www.elastic.co/guide/en/elasticsearch/client/java-rest/master/java-rest-high-java-builders.html
- https://www.elastic.co/guide/en/elasticsearch/reference/7.3/rest-apis.html
- https://www.elastic.co/guide/en/elasticsearch/client/java-rest/7.3/java-rest-high.html
- https://www.elastic.co/guide/en/elasticsearch/client/java-rest/7.3/java-rest-high-java-builders.html
curl -H'Content-Type: application/json' -XPOST 'localhost:9200/opal/_doc/_delete_by_query?conflicts=proceed' -d' { "query": { "match_all": {} }}'
Source: https://stackoverflow.com/a/49383660
curl -X DELETE "localhost:9200/opal?pretty"
Get the required mappings: https://github.com/projekt-opal/opaldata/blob/master/elasticsearch-initialization/mappings.json
curl -XPUT 'http://elastic:changeme@localhost:9200/opal'
curl -H 'Content-Type: application/json' -XPOST 'http://elastic:changeme@localhost:9200/opal/_mapping' -d @./mappings.json