RESTful API login failure

When I try and connect to my server, which returns “OK” with the command
curl http://localhost:9047/apiv2/server_status
but when I try and login using
curl --header "Content-Type:application/json" --request POST --data ‘{“userName”:”dremio”,”password”:”dremio123”}’ http://localhost:9047/apiv2/login
I get the following error:
curl: (6) Could not resolve host: xn--password-1o3dxbi; Unknown error
Furthermore the corresponding query in access.log is
0:0:0:0:0:0:0:1 - - [04/Dec/2020:10:41:23 +0000] "POST /apiv2/login HTTP/1.1" 403 66 "-" "curl/7.29.0"
and I keep getting the message
127.0.0.1 - - [04/Dec/2020:10:43:56 +0000] "GET /apiv2/socket HTTP/1.1" 403 0 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36"
in the access.log file.

@maxjpowers

Seems like your ordering is a little mixed up, can you please try the below?

curl --location --request POST 'http://localhost:9047/apiv2/login' \
--header 'Content-Type: application/json' \
--data-raw '{
"userName": "dremio",
"password": "dremio123"
}'

I still get this error

{"errorMessage":"No User Available","moreInfo":"","stackTrace":[]}curl: (6) Could not resolve host:  --header; Unknown error
curl: (6) Could not resolve host: Content-Type; Unknown error
curl: (6) Could not resolve host:  --data; Unknown error

[1/2]:  "userName": "dremio" --> <stdout>
--_curl_-- "userName": "dremio"
curl: (6) Could not resolve host:  "userName"; Unknown error

[2/2]:  "password": "dremio123"  --> <stdout>
--_curl_-- "password": "dremio123" 
curl: (6) Could not resolve host:  "password"; Unknown error