AnsweredAssumed Answered

Error accessing option_profile API

Question asked by Sachindra Narayan on May 8, 2020

I am trying to use option_profile API. i am getting an error while I hit the end point.

The error says "curl: (6) Could not resolve host: action=export"

 

my curl input is 

curl -u "USERID/PASSWORD" -H "X-Requested-With:curl" -X GET "action=export" "https://qualysapi.qualys.com/api/2.0/fo/subscription/option_profile/?action=export"

 

This is something on the terminal, while on the python code level implementation the error says:

HTTPError: 400 Client Error: Bad Request for url: https://qualysapi.qualys.com/api/2.0/fo/subscription/option_profile/?action=export

 

<SIMPLE_RETURN>
<RESPONSE>
<DATETIME>2020-05-08T13:10:46Z</DATETIME>
<CODE>1908</CODE>
<TEXT>Request method POST is incompatible with specified parameter(s): action=export</TEXT>
</RESPONSE>
</SIMPLE_RETURN>

Outcomes