Curl get command not showing data but only header info


Am working on Elasticsearch server and using the curl command for posting, getting the data in Windows command line.

When I try to post the data using the curl -XPUT command the data appears getting inserted. But when I query the data back using curl-XGET I am not getting the data but only header information like Index name, _id numberetc. Please see the queries and results below. Please let me know where am I going wrong.

curl -XPUT "/megacorp/emp/1" -d "{""first_name"" : ""John"",""last_name"" : ""Smith"",""age"" : "25"}"


curl -XPUT "/megacorp/emp/2" -d "{""first_name"" : ""Jane"",""last_name"" : ""Cooper"",""age"" : "35"}"


curl -XPUT "/megacorp/emp/3" -d "{""first_name"" : ""Bradleey"",""last_name"" : ""Cooper"",""age"" : "40"}"


curl -XGET "/megacorp/emp/_search?q=last_name:Cooper"