Reputation: 201
I'm running a curl script for HTML document conversion with a HTML file config. Below is the code:
curl -x POST -u "Username":"Password" -F "[email protected]" -F "[email protected];type=text/html" "https://gateway.watsonplatform.net/document-conversion/api/v1/index_document?version=2015-12-15"
I'm getting error - Could not resolve proxy: POST
. If anyone could help on this please?
Note - I have curl 7.46
installed
Upvotes: 18
Views: 45422
Reputation: 11
curl -X POST "yourwebsite.js"
Upvotes: -3
Reputation: 733
I am learning curl recently and encountered this as well. Actually, the reason is that the -x
should be replaced by -X
.
Upvotes: 73
Reputation: 5330
You error seems like one proxy config problem.
Try use --noproxy
flag:
Example:
curl --noproxy 127.0.0.1 +your POST
Or try set your proxy, like my example:
curl --proxy <[protocol://][user:password@]proxyhost[:port]> +your POST
Obs.: Use the specified HTTP proxy. If the port number isn't specified, will be 1080 for default.
Upvotes: 0