Home > database >  ElasticSearch REST API to use
ElasticSearch REST API to use

Time:10-01

Windows installed elasticsearch 5.4.0, in the command window type:
The curl - XPOST "localhost: 9200/twitter/tweet/1?" - d '{" user ":" Tom "}'

Always quote the content-type header is not supported, the status: 406, the great god help

CodePudding user response:

The curl - H the content-type: application/json - XPOST localhost: 9200/twitter/tweet/1? Pretty - d {\ "user " : \ "Tom \} - & gt; Perfect!
  • Related