Representation State Transfer (REST) API
- REST determines how API looks like.
- In REST API we send Requests from Client to Server.
- Anatomy of Request
- route or url for your request
- Method: GET, POST, PUT, DELETE
- Data (body): mostly json content
- Elastic search exposes well-designed REST API by using them we can perform CRUD (Create, Retrieve, Update and Delete)
- Refer Here for rest api documentation of elastic search
- Refer Here for official docs of index api
- Lets create a new request for a student by providing id
- Lets explore apis
- Get a document from students which has id 1
- Search all documents in an index
- Search for documents in multiple indexes
- Lets search for all documents of particular type in all indexes ![Preview](https://directdevops.blog/wp-content/uploads/2020/11/GET /_all/_doc/_search)