Option Profile Count

[GET]  [POST] /qps/rest/3.0/count/was/optionprofile

Returns the total number of option profiles in the user’s scope. Input elements are optional and are used to filter the number of option profiles included in the count.

Permissions required - User must have WAS module enabled. User account must have these permissions: Access Permission “API Access”. The count includes web applications in the user's scope.

Input ParametersInput Parameters

These elements are optional and act as filters. When multiple elements are specified, parameters are combined using a logical AND.

Click here for available operators

Parameter

Mandatory

/Optional

Data Type

Description

id

Optional

integer

The ID of the option profile.

name

Optional

text

The name given to the option profile.

tags

Optional

 

Filter by tags applied.

tags.id

Optional

integer

ID of the tag assigned to option profile.

tags.name

Optional

text

Tag name assigned 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.

owner.id

Optional

Long with operator: EQUALS, IN, NOT EQUALS, GREATER or LESSER

ID of the owner who created the option profile.

owner.name

Optional

text

Full name of the user who created the option profile.

owner.username  Optional  text

Username of the owner who created the option profile. (like user_ab3).

Sample - Count - no criteria (GET)Sample - Count - no criteria (GET)

API request

      
curl -u "USERNAME:PASSWORD" "<qualys_base_url>/qps/rest/3.0/count/was/optionprofile/"    

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>30</count>
</ServiceResponse>      
    

Sample -  Count - criteria (POST)Sample -  Count - criteria (POST)

API request

curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" --data-binary@-
"<qualys_base_url>/qps/rest/3.0/count/was/optionprofile/" < file.xml
Note: “file.xml” contains the request POST data.      
    

Request POST data

<ServiceRequest>
    <filters>
        <Criteria field="id" operator="IN">832265669,832295669,832285669</Criteria>
        <Criteria field="name" operator="CONTAINS">OP</Criteria>
        <Criteria field="tags" operator="NONE"></Criteria>
        <Criteria field="createdDate" operator="LESSER">2017-09-09</Criteria>
        <Criteria field="updatedDate" operator="LESSER">2017-09-09</Criteria>
    </filters>
</ServiceRequest>      
    

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>
</ServiceResponse>      
    

XSD

<platform API server>/qps/xsd/3.0/was/optionprofile.xsd