Elasticsearch 9 · Documents

Index a document with a generated ID

Let Elasticsearch choose the ID.

curl -u elastic:$ELASTIC_PASSWORD --cacert http_ca.crt -X POST "https://localhost:9200/products/_doc" -H "Content-Type: application/json" -d '{"name":"Mouse","price":25.0}'

Official Elasticsearch 9 documentation

More documents commands

All documents commands · Elasticsearch 9 cheatsheet

Was this page helpful?