Add to Subscription

[POST] /qps/rest/3.0/addToSubscription/was/catalog/{id}

Adds a web application entry to a subscription to create a web application.

Permissions required -  You must have the WAS module enabled. You must have the "API access" and "Access WAS module" permissions. You must have the "WAS.CATALOG.ACCESS"  and "WAS.CATALOG.ENTRY.ADD_TO_SUBSCRIPTION" permissions.

Input ParametersInput Parameters

The element “id” (integer) is required, where “id” identifies the catalog entry.

Sample - Add a catalog entry to the subscriptionSample - Add a catalog entry to the subscription

Let us add the catalog entry with id 306904 to the subscription.

API request

curl -u "USERNAME:PASSWORD" -H "content-type: text/xml" -X "POST" "<qualys_base_url>/qps/rest/3.0/addToSubscription/was/catalog/306904"      
    
     

XML response

<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://qualysapi.qualys.com/qps/xsd/version.xsd">
    <responseCode>SUCCESS</responseCode>
    <count>1</count>
    <data>
        <success>
            <ids>413904,413906</ids>
            <count>1</count>
        </success>
        <duplicate>
            <count>1</count>
            <ids>413905</ids>
        </duplicate>
        <error>
            <count>2</count>
            <errorMessage>Invalid URL for web application catalog
              entries: 413907Some error occurred for web application
              catalog entries:413908
             </errorMessage>
        </error>
    </data>
</ServiceResponse>