Azure Resources

Fetch all resources belonging to the specified type in your cloud environment and list them in the response.

Version 1 (v1)Version 1 (v1)

GET/rest/v1/resource/{resourceType}/Azure

Input ParametersInput Parameters

Parameter Mandatory/Optional Data Type Description
filter Optional String Filter resources using a Qualys query.

The following search tokens are supported.

List of tokens supported for Microsoft Azure Resources

Note: As of TC 2.13, Resources support tags.name token for tags applied to Connector (connector tag) and exception tag (tag applied to resources using Apply Tag API for Tag Exception creation).
pageNo Mandatory Integer The page to be returned.
pageSize Mandatory Integer The number of records per page to be included in the response.
sort Optional Keyword Sort the results using a Qualys token. Sorting is currently enabled with only one sort token: lastSyncedOn. The allowed values are asc or desc.
updated Optional String Use a date range or a specific date to define when the resource was last updated.

Examples:

Show resources updated within certain dates, updated: [2021-01-01 ... 2021-03-01]

Show resources updated starting 2018-10-01, ending 1 month ago, updated: [2021-01-01 ... now-1m]

Show resources updated starting 2 weeks ago, ending 1 second ago, updated: [now-2w ... now-1s]

Show resources updated on specific date, updated: 2021-01-08
resourceType Mandatory String Select the type of resource you want to fetch inventory for.

Azure Resource Types:
SQL_SERVER,
FUNCTION_APP,
SQL_SERVER_DATABASE,
RESOURCE_GROUP,
VIRTUAL_NETWORK,
VIRTUAL_MACHINE,
NETWORK_SECURITY_GROUP,
WEB_APP,
APPLICATION_GATEWAYS,
KUBERNETES_CLUSTER,
NETWORK_INTERFACES,
LOAD_BALANCER,
STORAGE_ACCOUNT,
COSMOS_DB,
AZURE_MYSQL_FLEXIBLE_SERVER,
MARIADB_SERVER,
FIREWALL,
NAT_GATEWAYS,
DISK,
PUBLIC_IP_ADDRESSES,
COGNITIVE_SERVICE,
PSQL_SERVER

Sample - Get the list of all Azure resources by typeSample - Get the list of all Azure resources by type

API request

    
      curl -X GET -u <username>:<password>
"<qualys_base_url>/cloudview-api/rest/v1/resource/VIRTUAL_MACHINE/Azure?filter=subscriptionName%3A%22s
amplesubscription%22&pageNo=0&pageSize=50"
      

JSON Response

    
      {
    "content": [
        {
            "controlsFailed": 2,
            "resourceId": "7de97440-93c5-4ced-9ef9-a3258d2c27da",
            "imageData": [
                {
                    "offer": "0001-com-ubuntu-server-focal",
                    "publisher": "canonical",
                    "id": null,
                    "sku": "20_04-lts-gen2",
                    "version": "latest"
                }
            ],
            "type": "Microsoft.Compute/virtualMachines",
            "uuid": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
            "remediationEnabled": null,
            "licenseType": null,
            "computerName": "Sample-vm-6",
            "cloudType": "AZURE",
            "customerId": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
            "osType": "Linux",
            "customers": [
                "b28e6859-9a15-fb81-833b-d20e458f7f7f"
            ],
            "networkSecurityGroupId": "Sample-vm-6-nsg",
            "connectorUuids": [
                "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
            ],
  
  
        
  ...
  
  
        
   "pageable": {
                "sort": {
                    "sorted": false,
                    "unsorted": true,
                    "empty": true
                },
                "pageNumber": 0,
                "pageSize": 5,
                "offset": 0,
                "paged": true,
                "unpaged": false
            },
            "last": true,
            "totalElements": 5,
            "totalPages": 1,
            "sort": {
                "sorted": false,
                "unsorted": true,
                "empty": true
            },
            "numberOfElements": 5,
            "first": true,
            "size": 5,
            "number": 0,
            "empty": false
        }
      

Version 2 (v2)Version 2 (v2)

GET/rest/v2/resource/{resourceType}/Azure

v2 is designed to efficiently handle large volumes of resource and evaluation data and to provide seamless pagination.

Key Features in v2:

  • Support for large evaluation result sets:
    The APIs now support retrieving more than 10,000 resource and evaluation records, removing the previous limit on result size.
  • Pagination using marker:
    A new response element, marker, is included in every API response. This marker allows continuation-based pagination across multiple API requests.

How this works:

  1. You can specify the size / pageSize parameter to control the number of records returned in a single response. The maximum allowable size is 1000.
  2. Each response includes a marker value.
  3. To retrieve subsequent records, you must pass the marker value from the previous response must be passed in the subsequent request.
  4. This process continues until no further marker is returned, indicating that all evaluation results have been retrieved.

Input ParametersInput Parameters

Parameter Mandatory/Optional Data Type Description
filter Optional String Filter resources using a Qualys query.
The following search tokens are supported.
List of tokens supported for Microsoft Azure Resources
Note: As of TC 2.13, Resources support tags.name token for tags applied to Connector (connector tag) and exception tag (tag applied to resources using Apply Tag API for Tag Exception creation).
pageSize Optional Integer The number of records to include per page in the response.
sort Optional Keyword Sort the results using a Qualys token. Sorting is currently enabled with only one sort token: lastSyncedOn. The allowed values are asc or desc.
updated Optional String Use a date range or a specific date to define when the resource was last updated.

Examples:

Show resources updated within certain dates, updated: [2021-01-01 ... 2021-03-01]

Show resources updated starting 2018-10-01, ending 1 month ago, updated: [2021-01-01 ... now-1m]

Show resources updated starting 2 weeks ago, ending 1 second ago, updated: [now-2w ... now-1s]

Show resources updated on specific date, updated: 2021-01-08
resourceType Mandatory String Select the type of resource you want to fetch inventory for.
marker Optional
(for first API call)
Mandatory
(for subsequent API calls)
Integer Use the marker value from the previous response to retrieve the next set of evaluation results.

Sample: Get the list of all AWS resources by type v2Sample: Get the list of all AWS resources by type v2

API request

    curl --location '<qualys_gateway>/cloudview-api/rest/v2/resource/VIRTUAL_MACHINE/azure?pageSize=2' \
--header 'accept: */*' \
--header 'Authorization: Bearer <JWT_token>

Response (JSON)

 {
    "currentPageSize": 2,
    "content": [
        {
            "uuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "connectorUuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "connectorUuids": [
                "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
            ],
            "cloudType": "AZURE",
            "customerId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "customers": [
                "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
            ],
            "subscriptionId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "subscriptionName": null,
            "resourceId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "resourceGroupName": "CDR-QA-ResourceGroup",
            "scanUuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "name": "QualysCDRVM-hp-qa2-euwst",
            "type": "Microsoft.Compute/virtualMachines",
            "region": "westeurope",
            "tags": [
                {
                    "name": "CreatedBy",
                    "value": "Qualys"
                }
            ],
            "remediationEnabled": null,
            "additionalDetails": null,
            "qualysTags": null,
            "isSnapshotScanEnabled": false,
            "controlsFailed": 0,
            "primaryPublicIPAddress": null,
            "primaryPublicIPAddressId": null,
            "primaryPrivateIPAddress": "10.13.10.4",
            "privateIpv6Address": null,
            "publicIpv6Address": null,
            "availabilitySetId": "",
            "provisioningState": "DELETED",
            "licenseType": null,
            "computerName": "QualysCDRVM-hp-qa2-euwst",
            "size": "Standard_D8s_v3",
            "osType": "Linux",
            "criticalityScore": null,
            "arsScore": null,
            "statuses": [
                {
                    "code": "PowerState/deleted",
                    "displayStatus": "Deleted",
                    "level": "info",
                    "message": null,
                    "time": "2026-01-12T11:47:43+0000"
                }
            ],
            "created": "2025-09-22T23:11:30+0000",
            "updated": "2026-01-12T11:47:43+0000",
            "networkSecurityGroupId": "",
            "imageData": [
                {
                    "id": null,
                    "offer": null,
                    "publisher": null,
                    "sku": null,
                    "version": null
                }
            ]
        },
        {
            "uuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "connectorUuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "connectorUuids": [
                "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
            ],
            "cloudType": "AZURE",
            "customerId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "customers": [
                "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
            ],
            "subscriptionId": "5xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "subscriptionName": null,
            "resourceId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "resourceGroupName": "AzureBlueHexagon",
            "scanUuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
            "name": "bh-acr-scanner-02",
            "type": "Microsoft.Compute/virtualMachines",
            "region": "westus2",
            "tags": [],
            "remediationEnabled": null,
            "additionalDetails": null,
            "qualysTags": null,
            "isSnapshotScanEnabled": false,
            "controlsFailed": 0,
            "primaryPublicIPAddress": null,
            "primaryPublicIPAddressId": "/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/AzureBlueHexagon/providers/Microsoft.Network/publicIPAddresses/bh-acr-scanner-02-ip",
            "primaryPrivateIPAddress": "10.1.0.14",
            "privateIpv6Address": null,
            "publicIpv6Address": null,
            "availabilitySetId": "",
            "provisioningState": null,
            "licenseType": null,
            "computerName": "bh-acr-scanner-02",
            "size": "Standard_DS1_v2",
            "osType": "Linux",
            "criticalityScore": null,
            "arsScore": null,
            "statuses": [
                {
                    "code": "ProvisioningState/succeeded",
                    "displayStatus": "Provisioning succeeded",
                    "level": "INFO",
                    "message": null,
                    "time": "2024-02-29T22:07:32+0000"
                },
                {
                    "code": "PowerState/deallocated",
                    "displayStatus": "VM deallocated",
                    "level": "INFO",
                    "message": null,
                    "time": null
                }
            ],
            "created": "2025-03-12T09:20:23+0000",
            "updated": "2026-01-27T10:12:13+0000",
            "networkSecurityGroupId": "bh-acr-scanner-02-nsg",
            "imageData": null
        }
    ],
    "hasNext": true,
    "totalHits": 67,
    "hasContent": true,
    "marker": "WzE3Njk1MDg3MzMwODEsIjNlNGFlNzI4LWQ5YzAtM2UwNS04Y2IzLTMwYjZmYmVhYzk0YiJd"
}