Get details of a specific asset by providing an asset Id.
Parameter |
Mandatory /Optional |
Data Type |
Description |
---|---|---|---|
excludeFields |
Optional |
string |
Comma-separated list of fields to be excluded from the asset object in the response. The default is None. You can choose from the list of fields specified in the Limit your results section. For example, to exclude openPort and software from the response: excludeFields=openPort,software |
includeFields |
Optional |
string |
Comma-separated list of fields to be included in the asset object in the response. The default is All. You can choose from the list of fields specified in the Limit your results section. For example, to include only operatingSystem and hardware in the response: includeFields=operatingSystem,hardware |
assetId |
Mandatory |
integer |
Use to specify theAssetId for which you want to retrieve the details. |
softwareType |
Optional |
string |
Specify the software type to get the host details for specified software type. Available values for softwareType parameter are Application, Unknown, and Others. |
Authorization |
Mandatory |
string |
Authorization token to authenticate to the Qualys Cloud Platform. Prepend token with "Bearer" and one space. For example - Bearer authToken |
API Request
curl -X GET -H "Accept: */*" -H "Authorization: Bearer <JWTToken>" -H "Content-Type: application/json" -i "<qualys_base_url>/rest/2.0/get/am/asset?assetId=8194990"
Response
{
"responseMessage":"Valid API Access",
"responseCode":"SUCCESS",
"assetListData":{
"asset":[
{
"assetId":6920718,
"assetUUID":"50d20290-c66a-42e7-8c0a-ba6e92b6324c",
"hostId":1437386,
"lastModifiedDate":"2021-04-06T10:02:33.000Z",
"agentId":null,
"createdDate":"2020-11-25T12:49:25.000Z",
"sensorLastUpdatedDate":"2021-04-06T10:02:33.000Z",
"assetType":"HOST",
"address":"10.115.110.95",
"dnsName":"localhost.localdomain",
"assetName":"localhost.localdomain",
"netbiosName":null,
"timeZone":"IST",
"biosDescription":null,
"lastBoot":null,
"totalMemory":5806,
"cpuCount":null,
"lastLoggedOnUser":"root",
"hwUUID":"422a2b16-4c8b-588a-a20c-c1851ad7e376",
"biosSerialNumber":"VMware-42 2a 2b 16 4c 8b 58 8a-a2 0c c1 85 1a d7 e3 76",
"biosAssetTag":"No Asset Tag",
"isContainerHost":false,
"operatingSystem":{
"osName":"The CentOS Project CentOS 7 (1810)",
"fullName":"The CentOS Project CentOS 7 (1810)",
"category":"Linux / Server",
"category1":"Linux",
"category2":"Server",
"productName":"CentOS",
"publisher":"The CentOS Project",
"edition":null,
"marketVersion":"7",
"version":"1810",
"update":null,
"architecture":null,
"lifecycle":{
"gaDate":"2018-12-03T00:00:00.000Z",
"eolDate":"2020-12-31T00:00:00.000Z",
"eosDate":"2024-06-30T00:00:00.000Z",
"stage":"EOL",
"lifeCycleConfidence":"Exact",
"eolSupportStage":"Full updates",
"eosSupportStage":"Maintenance Updates"
},
"taxonomy":{
"id":null,
"name":"Linux / Server",
"category1":"Linux",
"category2":"Server"
},
"productUrl":"https://www.centos.org/,https://en.wikipedia.org/wiki/CentOS,",
"productFamily":null,
"installDate":null,
"release":"7.4.1708"
},
"hardware":{
"fullName":"VMware VMware Virtual Platform VMware Virtual Platform",
"category":"Virtualized / Virtual Machine",
"category1":"Virtualized",
"category2":"Virtual Machine",
"manufacturer":"VMware",
"productName":"VMware Virtual Platform",
"model":"VMware Virtual Platform",
"lifecycle":{
"introDate":null,
"gaDate":null,
"eosDate":null,
"obsoleteDate":null,
"stage":"Unknown",
"lifeCycleConfidence":" "
},
"taxonomy":{
"id":null,
"name":"Virtualized / Virtual Machine",
"category1":"Virtualized",
"category2":"Virtual Machine"
},
"productUrl":"https://www.linuxjournal.com/article/3458,,",
"productFamily":null
},
"userAccountListData":null,
"openPortListData":{
"openPort":[
{
"port":709,
"description":"",
"protocol":"UDP",
"detectedService":"portmap/rpcbind",
"firstFound":"2020-11-25T12:46:42.000Z",
"lastUpdated":"2020-11-25T12:46:42.000Z"
},
{
"port":50000,
"description":"",
"protocol":"TCP",
"detectedService":"IBM_DB2_Universal_Database",
"firstFound":"2020-11-25T12:46:42.000Z",
"lastUpdated":"2020-11-25T12:46:42.000Z"
},
{
"port":6000,
"description":"",
"protocol":"TCP",
"detectedService":"x11",
"firstFound":"2020-11-25T12:46:42.000Z",
"lastUpdated":"2020-11-25T12:46:42.000Z"
},
{
"port":22,
"description":"",
"protocol":"TCP",
"detectedService":"ssh",
"firstFound":"2020-11-25T12:46:41.000Z",
"lastUpdated":"2020-11-25T12:46:41.000Z"
},
{
"port":3389,
"description":"",
"protocol":"TCP",
"detectedService":null,
"firstFound":"2020-11-25T12:46:42.000Z",
"lastUpdated":"2020-11-25T12:46:42.000Z"
},
{
"port":111,
"description":"",
"protocol":"UDP",
"detectedService":"rpc_udp",
"firstFound":"2020-11-25T12:46:42.000Z",
"lastUpdated":"2020-11-25T12:46:42.000Z"
},
{
"port":111,
"description":"",
"protocol":"TCP",
"detectedService":"rpc",
"firstFound":"2020-11-25T12:46:41.000Z",
"lastUpdated":"2020-11-25T12:46:41.000Z"
}
]
},
"volumeListData":{
"volume":[
{
"name":"tmpfs",
"free":2737078272,
"size":3043934208
},
{
"name":"/dev/mapper/centos-home",
"free":18629619712,
"size":18700304384
},
{
"name":"devtmpfs",
"free":3026444288,
"size":3026444288
},
{
"name":"/dev/mapper/centos-root",
"free":19672580096,
"size":38304645120
},
{
"name":"/dev/sda1",
"free":876040192,
"size":1063256064
}
]
},
"networkInterfaceListData":{
"networkInterface":[
{
"hostname":"localhost.localdomain",
"addressIpV4":"192.168.122.1",
"addressIpV6":null,
"macAddress":"52:54:00:77:e1:71",
"interfaceName":"virbr0",
"dnsAddress":null,
"gatewayAddress":"",
"manufacturer":null,
"macVendorIntroDate":null,
"addresses":null
},
{
"hostname":"localhost.localdomain",
"addressIpV4":"10.115.110.95",
"addressIpV6":"fe80:0:0:0:250:56ff:feaa:e2da",
"macAddress":"00:50:56:aa:e2:da",
"interfaceName":"ens192",
"dnsAddress":null,
"gatewayAddress":"",
"manufacturer":"VMware",
"macVendorIntroDate":946944000000,
"addresses":null
}
]
},
"softwareListData":{
"software":[
{
"id":-5698725809391962787,
"fullName":"Python 2.7.5 64-Bit",
"softwareType":"Application",
"isIgnored":false,
"ignoredReason":null,
"category":"Application Development / Programming Languages",
"category1":"Application Development",
"category2":"Programming Languages",
"productName":"Python",
"component":null,
"publisher":"Python",
"edition":null,
"marketVersion":"2",
"version":"2.7",
"update":"2.7.5",
"architecture":"64-Bit",
"installDate":"2020-03-27T16:11:47.000Z",
"installPath":null,
"lastUpdated":"2020-11-25T12:46:46.000Z",
"lastUseDate":null,
"language":null,
"formerlyKnownAs":null,
"isPackage":false,
"isPackageComponent":false,
"packageName":null,
"productUrl":"https://en.wikipedia.org/wiki/History_of_Python,,",
"lifecycle":{
"gaDate":"2010-07-03T00:00:00.000Z",
"eolDate":"2020-01-01T00:00:00.000Z",
"eosDate":"2020-01-01T00:00:00.000Z",
"stage":"EOL/EOS",
"lifeCycleConfidence":"Exact",
"eolSupportStage":"End-of-life",
"eosSupportStage":"End-of-life"
},
"supportStageDesc":"Python's policy is to drop support major versions once they reach their end of life",
"license":{
"category":"Open Source",
"subcategory":"Python License (Python-2.0)"
},
"authorization":"Authorized"
},
{
"id":9136542396418607016,
"fullName":"OpenBSD OpenSSH Server 7.4p1",
"softwareType":"Application",
"isIgnored":false,
"ignoredReason":null,
"category":"Networking / Access Software",
"category1":"Networking",
"category2":"Access Software",
"productName":"OpenSSH",
"component":"Server",
"publisher":"OpenBSD",
"edition":null,
"marketVersion":"7",
"version":"7.4",
"update":"7.4p1",
"architecture":null,
"installDate":"2020-03-05T14:23:53.000Z",
"installPath":null,
"lastUpdated":"2020-11-25T12:46:53.000Z",
"lastUseDate":null,
"language":null,
"formerlyKnownAs":"OpenBSD Secure Shell",
"isPackage":true,
"isPackageComponent":false,
"packageName":null,
"productUrl":"https://en.wikipedia.org/wiki/OpenSSH,,",
"lifecycle":{
"gaDate":"2016-12-19T00:00:00.000Z",
"eolDate":null,
"eosDate":null,
"stage":"EOL",
"lifeCycleConfidence":"Calculated",
"eolSupportStage":" ",
"eosSupportStage":" "
},
"supportStageDesc":null,
"license":{
"category":"Open Source",
"subcategory":"BSD 2-Clause License (FreeBSD/Simplified)"
},
"authorization":"Authorized"
}
]
},
"provider":null,
"cloudProvider":null,
"agent":null,
"sensor":{
"activatedForModules":[
"VM"
],
"pendingActivationForModules":[
],
"lastVMScan":1606306572000,
"lastComplianceScan":0,
"lastFullScan":1606306572000
},
"container":null,
"inventory":{
"source":"IP",
"created":1606308565000,
"lastUpdated":1617703353000
},
"activity":null,
"tagList":{
"tag":[
{
"tagId":14151022,
"tagName":"static split",
"foregroundColor":0,
"backgroundColor":-65536,
"businessImpact":null,
"criticalityScore":2
}
]
},
"serviceList":null,
"lastLocation":null,
"criticality":{
"score":2,
"isDefault":true,
"lastUpdated":"2021-06-30T09:43:27.000Z"
},
"businessInformation":{
"company":"Qualys",
"department":"Engineering",
"ownedBy":"Paul",
"environment":"QA",
"managedBy":"Amit",
"supportedBy":"Nick",
"supportGroup":"ABC_01",
"operationalStatus":"Blocked"
},
"assignedLocation":{
"name":"4492 Camino De La Plaza, Pune,IN",
"city":"Pune",
"state":"MH",
"country":"IN"
},
"businessAppListData":{
"businessApp":[
{
"id":"BARCODE283904",
"name":"Quoting App",
"environment":"Production",
"businessCriticality":"2 - Less Critical",
"managedBy":"Amit",
"ownedBy":"Narendra",
"supportedBy":"Rishabh",
"supportGroup":"SME Operations",
"operationalStatus":"Mended",
"status":"Installed",
"usedFor":"Production"
},
{
"id":"BARCODE2839067gfh",
"name":"HRA",
"environment":"Production",
"businessCriticality":"1 - Most Critical",
"managedBy":"Amit",
"ownedBy":"Narendra",
"supportedBy":"Rishabh",
"supportGroup":"SME Operations",
"operationalStatus":"broken",
"status":"Installed",
"usedFor":"Production"
}
]
},
"riskScore":690,
"passiveSensor":null,
"asn":"AS27385",
"isp":"Qualys, Inc.",
"domain":[
"qualys.com",
"qualys.in"
],
"subdomain":[
"docs.qualys.com",
"www.qualys.com"
],
"whois":[
{
"domain":"vulnerability-management.com",
"createdDate":null,
"dnssec":null,
"domainStatus":"clientTransferProhibited",
"registrantOrganization":"Qualys, Inc.",
"registrantName":null,
"registrantEmail":"6d229c2ef8870a654745766aab8e6ace-49101@contact.gandi.net",
"registrantContact":null,
"registrar":"Gandi SAS",
"organizationName":"Qualys, Inc.",
"updatedDate":null
}"missingSoftware":null,
"customAttributes":[
{
"key":"Media State4",
"value":"Media disconnected",
"connectorName":"Qualys"
},
{
"key":"Default Gateway11",
"value":"192.168.1.1",
"connectorName":"Qualys"
},
"..."{
"key":"Subnet Mask",
"value":"255.255.255.0",
"connectorName":"Qualys"
},
"..."
],
"processor":null
}
]
}
API Request
curl --location --request GET
'<qualys_base_url>/rest/2.0/get/am/asset?assetId=19605572
--header 'Content-Type: application/json'
--header 'Authorization: Bearer <JWT Token>'
--header 'Content-Type: application/xml'
--data-raw
'<FilterRequest>'
Filter in XML
<FilterRequest>
<filters>
<Criteria field="missingSoftware.product"
operator="EQUALS"><value>Windows Defender</value></Criteria>
</filters>
</FilterRequest>
Filter in JSON
{
"filters": [
{
"field": "missingSoftware.product",
"operator": "EQUALS",
"value": " Windows Defender "
}
]
}
Response
{
"responseMessage":"Valid API Access",
"count":1,
"responseCode":"SUCCESS",
"lastSeenAssetId":null,
"hasMore":0,
"assetListData":{
"asset":[
{
"assetId":19605572,
"assetUUID":"3eb82cb6-1026-465f-a68c-94e4a95a921b",
"hostId":999990762,
"...""businessInformation":null,
"assignedLocation":null,
"businessAppListData":null,
"riskScore":null,
"passiveSensor":null,
"domain":null,
"subdomain":null,
"missingSoftware":[
{
"name":"Microsoft Windows Defender",
"category1":"Security",
"category2":"Endpoint Protection",
"publisher":"Microsoft",
"product":"Windows Defender",
"rule":"regression_14",
"criteria":[
{
"criteria":"ANY Version ",
"release":[
"ANY"
]
}
]
},
{
"name":"Microsoft Defender Advanced Threat
Protection",
"category1":"Security",
"category2":"Endpoint Protection",
"publisher":"Microsoft",
"product":"Microsoft Defender Advanced Threat
Protection",
"rule":"regression_14",
"criteria":[
{
"criteria":"ANY Version ",
"release":[
"ANY"
]
}
]
},
"..."
],
"whois":null,
"isp":null,
"asn":null,
"easmTags":null,
"..."
}
]
}
}
API Request
curl --location
'<qualys_base_url>/rest/2.0/get/am/asset?assetId=16587699' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <JWT_Token>'
API Response
{ "responseMessage": "Valid API Access", "count": 1, "responseCode": "SUCCESS", "lastSeenAssetId": null, "hasMore": 0, "assetListData": { "asset": [ { "assetId": 16587699, "assetUUID": "b516ea66-6921-9451-e053-2a4f2c0a1522", "hostId": null, "lastModifiedDate": "2024-09-17T05:27:06.000Z", "agentId": null, "createdDate": "2020-11-27T12:36:55.000Z", "sensorLastUpdatedDate": "2024-09-17T05:27:06.000Z", "assetType": "SCANNER", "address": null, "dnsName": null, "assetName": "POD04-Scanner", "netbiosName": null, "timeZone": null, "biosDescription": null, "lastBoot": null, "totalMemory": null, "cpuCount": null, "lastLoggedOnUser": null, "domainRole": null, "hwUUID": null, "biosSerialNumber": null, "biosAssetTag": null, "isContainerHost": null, "operatingSystem": null, "hardware": null, "userAccountListData": null, "openPortListData": null, "volumeListData": null, "networkInterfaceListData": null, "softwareListData": null, "softwareComponent": null, "provider": null, "cloudProvider": null, "agent": null, "sensor": null, "container": null, "inventory": null, "activity": null, "tagList": { "tag": [ { "tagId": 134046247, "tagName": "BU-specAG11", "foregroundColor": 0, "backgroundColor": 0, "businessImpact": null, "criticalityScore": null }, { "tagId": 142628002, "tagName": "testscan1", "foregroundColor": 0, "backgroundColor": 0, "businessImpact": null, "criticalityScore": null }, ] }, "serviceList": null, "lastLocation": null, "criticality": null, "businessInformation": null, "assignedLocation": null, "businessAppListData": null, "riskScore": null, "passiveSensor": null, "domain": null, "subdomain": null, "missingSoftware": null, "whois": null, "organizationName": null, "isp": null, "asn": null, "easmTags": null, "hostingCategory1": null, "customAttributes": null, "processor": null } ] } }
API Request
curl --location --request GET
'<qualys_base_url>/rest/2.0/get/am/asset?assetId=22303276'
--header'Content-Type: application/json'
--header 'Authorization: Bearer <JWT Token>'
Response
"responseMessage":"Valid API Access",
"count":1,
"responseCode":"SUCCESS",
"lastSeenAssetId":null,
"hasMore":0,
"assetListData":{
"asset":[
{
"assetId":22303276,
"assetUUID":"383c0696-0ac9-42f8-8189-28b7e81f4bb0",
"hostId":null,
"...""missingSoftware":null,
"whois":[
{
"domain":"blujaysolutions.com",
"createdDate":"2016-11-30T00:00:00.000Z",
"..."
}
],
"isp":"Amazon.com, Inc.",
"asn":"AS16509",
"easmTags":[
"cloud"
],
"hostingCategory1":"ThirdParty",
"customAttributes":null,
"processor":null
}
]
}
}
We also support this for includeFields and excludeFields. See the following example.
API Request
curl --location --request GET
'<qualys_base_url>/rest/2.0/get/am/asset?
assetId=22303276&includeFields=hostingCategory1'
--header 'Content-Type: application/json'
--header 'Authorization: Bearer <JWT Token>'
Response
{
"responseMessage":"Valid API Access",
"count":1,
"responseCode":"SUCCESS",
"lastSeenAssetId":null,
"hasMore":0,
"assetListData":{
"asset":[
{
"assetId":22303276,
"assetUUID":"383c0696-0ac9-42f8-8189-28b7e81f4bb0",
"hostId":null,
"...""missingSoftware":null,
"whois":null,
"isp":null,
"asn":null,
"easmTags":null,
"hostingCategory1":"ThirdParty",
"customAttributes":null,
"processor":null
}
]
}
API Request
curl --location --request GET
'<qualys_base_url>/rest/2.0/get/am/asset?assetId=22303132'
--header 'Content-Type: application/json'
--header 'Authorization: Bearer <JWT Token>'
Response
{
"responseMessage": "Valid API Access",
"count": 1,
"responseCode": "SUCCESS",
"lastSeenAssetId": null,
"hasMore": 0,
"assetListData": {
"asset": [
{
"assetId": 22303132,
"assetUUID": "xxx69134-dcxx-4e65-xxce-74f3e60caxxx",
"hostId": null,
...
"missingSoftware": null,
"whois": [
{
"domain": "totalcloud.io",
...
"registrar": "GoDaddy.com, LLC",
"organizationName": null,
"updatedDate": null
}
],
"isp": "Amazon.com, Inc.",
"asn": "AS16509",
"easmTags": [
"cloud",
"cdn"
],
"hostingCategory1": "Unknown",
"customAttributes": null,
"processor": null
}
]
}
}
We also support this for includeFields and excludeFields. See the following example.
API Request
curl --location --request GET
'<qualys_base_url>/rest/2.0/get/am/asset?assetId=22303132&includeFields=easmTags'
--header 'Content-Type: application/json'
--header 'Authorization: Bearer <JWT Token>'
Response
{
"responseMessage": "Valid API Access",
"count": 1,
"responseCode": "SUCCESS",
"lastSeenAssetId": null,
"hasMore": 0,
"assetListData": {
"asset": [
{
"assetId": 22303132,
"assetUUID": "c9669134-dcb4-4e65-94ce-74f3e60ca697",
"hostId": null,
...
"riskScore": null,
"passiveSensor": null,
"domain": null,
"subdomain": null,
"missingSoftware": null,
"whois": null,
"isp": null,
"asn": null,
"easmTags": [
"cloud",
"cdn"
],
"hostingCategory1": null,
"customAttributes": null,
"processor": null
}
]
}
}