Curl JSON Request Example

An example of sending JSON data using Curl. JSON is passed with the -d command-line option. Double quotes in JSON are escaped with \ ". When sending JSON using Curl, the -H "Content-Type: application/json" command line parameter is important and tells the server the media type of the resource in the request body.
Curl JSON Request Example Run
curl -X POST https://reqbin.com/echo/post/json
     -H "Content-Type: application/json"
     -H "Accept: application/json" 
     -d "{\"Id\": 78912,\"Customer\": \"Jason Sweet\",\"Quantity\": 1,\"Price\": 18.00}"