Delete an option profile that is in the user’s scope. Upon success, the output is a list of IDs for the option profiles that were deleted.
Permissions required - User must have WAS module enabled. User account must have these permissions: Access Permission “API Access” and "Delete Option Profile".
Optional elements are used to retrieve option profiles to delete. When multiple elements are specified, parameters are combined using a logical AND. All dates must be entered in UTC date/time format.
Click here for available operators
Parameter |
Mandatory /Optional |
Data Type |
Description |
---|---|---|---|
name |
Optional |
text |
The name given to the option profile. |
owner |
Optional |
text |
Username of the owner who created the option profile. (like user_ab3). |
tags |
Optional |
text |
Filter by tags applied to option profile. |
createdDate |
Optional |
date |
The date when the option profile was created in WAS, in UTC date/time format. |
updatedDate |
Optional |
date |
The date when the option profile was updated in WAS, in UTC date/time format. |
usedByWebApps |
Optional |
boolean |
Web applications used/not used by the option profile. |
usedBySchedules |
Optional |
boolean |
Scan schedules used/not used by the option profile. |
API request
curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" --data-binary @- "<qualys_base_url>/qps/rest/3.0/delete/was/optionprofile/834275669"
XML response
<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="<qualys_base_url>/qps/xsd/3.0/was/optionprofile.xsd">
<responseCode>SUCCESS</responseCode>
<count>1</count>
<data>
<OptionProfile>
<id>834275669</id>
</OptionProfile>
</data>
</ServiceResponse>
API request
curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" --data-binary@-
"<qualys_base_url>/qps/rest/3.0/delete/was/optionprofile/" < file.xml
Note: “file.xml” contains the request POST data.
Request POST data
<ServiceRequest>
<filters>
<Criteria field="name" operator="CONTAINS">OP</Criteria>
<Criteria field="updatedDate" operator="LESSER">2017-09-09</Criteria>
</filters>
</ServiceRequest>
XML response
<ServiceResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="<qualys_base_url>/qps/xsd/3.0/was/optionprofile.xsd">
<responseCode>SUCCESS</responseCode>
<count>10</count>
<data>
<OptionProfile>
<id>712265669</id>
</OptionProfile>
<OptionProfile>
<id>752265669</id>
</OptionProfile>
<OptionProfile>
<id>752275669</id>
</OptionProfile>
<OptionProfile>
<id>754265669</id>
</OptionProfile>
<OptionProfile>
<id>812685669</id>
</OptionProfile>
<OptionProfile>
<id>824295669</id>
</OptionProfile>
<OptionProfile>
<id>824305669</id>
</OptionProfile>
<OptionProfile>
<id>830265669</id>
</OptionProfile>
<OptionProfile>
<id>830275669</id>
</OptionProfile>
<OptionProfile>
<id>830285669</id>
</OptionProfile>
</data>
</ServiceResponse>
<platform API server>/qps/xsd/3.0/was/optionprofile.xsd