Search AWS Connectors

[POST] /qps/rest/2.0/search/am/awsassetdataconnector

Returns a list of AWS connectors that match the provided criteria.

Limit your results - Use the optional “fields” parameter to limit the amount of information returned for each AWS connector. Learn more about limiting your results

Pagination - A maximum of 100 instances are returned by default. To customize this specify a “preferences” tag in the POST body of your request.



Permissions required - Managers with full scope.

Input ParametersInput Parameters

Click here for available operators

Parameter

Mandatory

/Optional

Data Type

Description

id

  integer

Primary key

name

 

text

 

description

 

text

 

lastSync

  Date

 

lastError

  Text

 

connectorState

  Keyword

(AssetDataConnectorState) PENDING, SUCCESS, ERROR, QUEUED, RUNNING, PROCESSING, FINISHED_SUCCESS, FINISHED_ERRORS, DISABLED, INCOMPLETE, not writeable

activation

  Keyword

VM, PC, SCA, CERTVIEW

defaultTags.name

  Text

The name of a tag in the defaultTags collection

defaultTag

  Integer

The ID of a tag in the defaultTags collection

allRegions

  Boolean

 

serviceType

  Keyword

EC2

endpoint.region

  Text

AWS region code

disabled

  Boolean

Whether execution of the connector is disabled (YES). If disabled the connector will not synchronize assets.

Sample 1 - Find all asset data connectors with tag name USASample 1 - Find all asset data connectors with tag name USA

API request

curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" --data-binary @- "<qualys_base_url>/qps/rest/2.0/search/am/awsassetdataconnector" < file.xml
Note: file.xml contains request POST data

Request POST data

<?xml version="1.0" encoding="UTF-8" ?>
<ServiceRequest>
    <filters>
        <Criteria field="defaultTags.name" operator="EQUALS">USA</Criteria>
    </filters>
</ServiceRequest>    
    

Response

<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="<qualys_base_url>/xsd/2.0/am/aws_asset_data_connector.xsd">
    <responseCode>SUCCESS</responseCode>
    <count>13</count>
    <hasMoreRecords>false</hasMoreRecords>
    <data>
        <AwsAssetDataConnector>
            <id>12345</id>
            <name>NEW Connector</name>
            <awsAccountId>205767712438</awsAccountId>
            <lastSync>2014-11-26T09:27:48Z</lastSync>
            <lastError>Invalid EC2 AuthRecord</lastError>
            <connectorState>ERROR</connectorState>
            <type>AWS</type>
            <defaultTags>
                <list>
                    <TagSimple>
                        <id>1</id>
                        <name>USA</name>
                    </TagSimple>
                </list>
            </defaultTags>
            <activation/>
            <arn>arn:aws:iam::205767712433:role/qualys-demo-account</arn>
            <externalId>pod13-xxxxxx-xxxxx</externalId>
            <endpoints>
                <list>
                    <AwsEndpointSimple>
                        <regionCode>us-east-1</regionCode>
                    </AwsEndpointSimple>
                </list>
            </endpoints>
            <allRegions>false</allRegions>
        </AwsAssetDataConnector>
    </data>
</ServiceResponse>
    

Sample 2 - Search AWS asset data connectors that are made available in the CloudView AppSample 2 - Search AWS asset data connectors that are made available in the CloudView App

API request

curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" --data-binary @- "<qualys_base_url>/qps/rest/2.0/search/am/awsassetdataconnector" < file.xml
Note: file.xml contains request POST data

curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" --data-binary @- "<qualys_base_url>/qps/rest/2.0/search/am/awsassetdataconnector" < file.xml

Note: file.xml contains request POST data

Request POST data

<?xml version="1.0" encoding="UTF-8" ?>
<ServiceRequest>
    <filters>
        <Criteria field="activation" operator="EQUALS">CLOUDVIEW</Criteria>
    </filters>
</ServiceRequest>   
    

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/2.0/am/aws_asset_data_connector.xsd">
    <responseCode>SUCCESS</responseCode>
    <count>1</count>
    <hasMoreRecords>false</hasMoreRecords>
    <data>
        <AwsAssetDataConnector>
            <id>266408</id>
            <name>conn1</name>
            <awsAccountId>205767712433</awsAccountId>
            <connectorState>QUEUED</connectorState>
            <type>AWS</type>
            <activation>
                <list>
                    <ActivationModule>CLOUDVIEW</ActivationModule>
                </list>
            </activation>
            <disabled>false</disabled>
            <isGovCloudConfigured>false</isGovCloudConfigured>
            <isChinaConfigured>false</isChinaConfigured>
            <arn> arn:aws:iam::205767712433:role/qualys-demo-account</arn>
            <externalId>pod13-xxxxxx-xxxxx</externalId>
            <qualysAwsAccountId>205767712438</qualysAwsAccountId>
            <endpoints>
                <list>
                    <AwsEndpointSimple>
                        <regionCode>us-west-1</regionCode>
                    </AwsEndpointSimple>
                    <AwsEndpointSimple>
                        <regionCode>ap-northeast-1</regionCode>
                    </AwsEndpointSimple>
                    <AwsEndpointSimple>
                    ...
                
                    </list>
                </endpoints>
                <allRegions>true</allRegions>
            </AwsAssetDataConnector>
        </data>
    </ServiceResponse>  
    

XSD

<platform API server>/qps/xsd/2.0/am/aws_asset_data_connector.xsd