How to send PUT request using Curl? [Curl/Bash Code]

To make a PUT request with Curl, you need to use the -X PUT command-line option. PUT request data is passed with the -d parameter. If you give -d and omit -X, Curl will automatically choose the HTTP POST method. The -X PUT option explicitly tells Curl to select the HTTP PUT method instead of POST. The data type for the Curl request is set using the -H command-line option. In this Curl PUT example, we send a request to the ReqBin echo URL. Click Run to execute the Curl PUT request online and see the results. The Curl/Bash code was automatically generated for the Curl PUT example.
Loading...