chrome dev tools copy as curl - doesn't copy HTTP method

Viewed 2425

In the network tab - > filter by XHR requests, when I copy a HTTP request with ' copy as curl. It doesn't appear to copy the HTTP method. However this doesn't seem to cause a problem when testing an external api. (verified on GET and POST requests as specified in chrome). I'm not that familar with curl, but does anyone else see the same lack of HTTP method when copying?

eg:

$ curl 'https://api.somedomain.com' -H 'origin: https://www.somedomain.com' -H 'accept-encoding: gzip, deflate' -H 'accept-language: en-GB,en-US;q=0.8,en;q=0.6' -H 'user-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.116 Safari/537.36' -H 'content-type: application/json' -H 'accept: */*' -H 'referer: https://www.somedomain.com/path/path2' -H 'authority: api.theenergyshop.co.uk' --data-binary '{'somepayload: 'test'}' --compressed
1 Answers
Related