Get a List of Assets
Use this API to get a list of assets enabled for your Patch Management within your scope.
Input ParametersInput Parameters
|
Parameter |
Mandatory/Optional |
Data Type |
Description |
|---|---|---|---|
|
havingQuery |
Optional |
string |
Specify a QQL to filter assets based on patch catalog search criteria. For example, appFamily:Firefox |
|
pageNumber |
Optional |
string |
The page to be returned. Default value: 0 |
|
pageSize |
Optional |
string |
Limit number of rows to be returned per page. Default value: 10 |
|
platform |
Optional |
string |
The platform type. - Available values: Linux, Windows - Default value: Windows |
|
query |
Optional |
string |
Specify a QQL to filter assets based on asset search criteria. For example, name:'Asset-windowsmachine1' Append the QQL (patchStatus:[Missing,Installed] and isSuperseded:false) to filter the latest missing and installed patches. |
|
sort |
Optional |
string |
Sort the patch values by certain data. For example, [{"name":"asc"}] |
Sample - Get List of Linux AssetsSample - Get List of Linux Assets
API Request
curl -X 'GET' \
'<qualys_base_url>/pm/v1/assets?platform=Linux’ \
-H 'accept: application/json' \
-H 'Authorization: Bearer <<jwt token>>’
API Response
[
{
"name": "rhel8r6-vm-live",
"id": "968fa80c-df51-4e6a-9279-b26653cec986",
"operatingSystem": "Red Hat Enterprise Linux 8.6",
"lastLoggedOnUser": "root",
"assetStatus": "Failed",
"scanStatus": "Scanned",
"statusCode": 20212,
"statusDateTime": 1753435366000,
"scanDateTime": 1753425259261,
"hardware": {
"model": "VMware7,1",
"manufacturer": "VMware, Inc."
},
"tags": [
{
"id": "909075bb-a86b-4bfc-8936-2644f5b66ff6"
},
{
"id": "1f49f584-6881-4408-b139-01149e730bdb"
}
],
"interfaces": [
{
"interfaceName": "ens192",
"macAddress": "00:50:56:aa:e0:e6",
"ipv6Address": null,
"address": "10.115.127.59",
"gatewayAddress": null
},
{
"interfaceName": "virbr0",
"macAddress": "52:54:00:06:68:83",
"ipv6Address": null,
"address": "192.168.122.1",
"gatewayAddress": null
},
{
"interfaceName": "ens192",
"macAddress": "00:50:56:aa:e0:e6",
"ipv6Address": "fe80:0:0:0:250:56ff:feaa:e0e6",
"address": null,
"gatewayAddress": null
}
],
"installedPatches": [],
"missingPatches": [
{
"id": "4a230d59-259a-3598-9ef3-0c36765683ae"
},
{
"id": "3ebbbc04-8c60-387a-9bc3-d79261440ea6"
},
.............
{
"id": "864fb9d2-bffe-3da8-92c8-3a1263b39c70"
}
],
"version": "8.6",
"architecture": "x86_64",
"osIdentifier": "RHEL8",
"platform": "Linux",
"agentVersion": "007.002.000.038",
"isolation": null,
"activatedModules": [
"MTG",
"PM"
],
"osNotSupportedForModules": [],
"missingCount": 110,
"installedCount": 0
}
]