elastic-search

getting started queries

List indices

GET /_cat/indices

Confirm index exists

GET /my-test-index

Add document to index

POST my-test-index/_doc/
{
  "message": "my test message"
}

Get all documents from index

GET my-test-index/_search
{
    "query": {
        "match_all": {}
    }
}

Set index replicas

Use this to make single node clusters have green health in aws

PUT my-test-index/_settings
{
  "index": {
    "number_of_replicas" : 0
  }
}

The rest

Elasticsearch Query DSL: query