May 25th, 2020 13:00

Please, use the "-v" parameter:

curl -v -k -X 'POST' --header 'Content-Type: application/json' --header 'Accept: application/json' -d '{ "auth_info": {"username":"sysadmin", "password":"***" } }' 'https://:3009/rest/v1.0/auth'

 

5 Posts

May 25th, 2020 13:00

Luiz, thanks, that's it (-v), I managed this today morning, but forgot to mention this here

November 14th, 2022 06:00

This absolutely does NOT work. not even close.   The API guide is wrong, all references to this are wrong.  None of the curl executions work, none of the python executions work.  So far no way to get x-auth-token.  Completely broken process or no one really uses the API.  

November 16th, 2022 11:00

Finally got something to actually work

curl -i -s -k -X POST -H  "Content-Type: application/json" -d @omviewcred.json https://yourservername/api/SessionService/Sessions 

 

curl -i -s -k -X POST -H  "Content-Type: application/json" -d @omviewcred.json https://yourservername/api/SessionService/Sessions -v |grep -P "X-Auth-Token" | awk '{print$2}'

 

 

cat omveiewcred.json

  {
"UserName": "omview_svc",
"Password": "mysecrutz2",
"SessionType": "API"
}

 

No Events found!

Top