curl / Mailing Lists / curl-users / Single Mail


Curl on Windows has issues with JSON parameters on command line?

From: Ayotunde Itayemi <>
Date: Fri, 11 May 2018 00:33:14 -0600

Hi All,
New to the list. I have been testing various Windows build of curl (7.42,
7.53, 7.59, 7.55 on cygwin) but none seems to work well when the
credentials are supplied in JSON form on the command line (they do work if
you put the JSON credentials in a file and then supply it to curl using the
form @filename).

Sample command that fails with response {"message": "Bad Request"}:

curl -i -X POST -H "Content-Type: application/json" -d

The same command succeeds if I store the credentials in JSON format in a
file and then execute:

curl -i -X POST -H "Content-Type: application/json" -d @file

In contrast 7.29.0 (and 7.59) on Linux works fine. For some reason curl on
cygwin won't connect at all and keeps giving "connection timed out." Is it
something Windows is doing to the parameters (thinking parameter expansion)
or some other issue that's actual just peculiar to the Windows version of



Received on 2018-05-11