Add new asset group

/api/2.0/fo/asset/group/?action=add

[POST]

Add a new asset group in the user's account.

Click here to see the required permissions.

Input Parameters

Parameter

Description

action=add

(Required) The POST method must be used.

echo_request={0|1}

(Optional) Specify 1 to show (echo) the request’s input parameters (names, values) in the XML output. When unspecified, parameters are not included in the XML output.

title={value}

(Required) An asset group title. This name must be unique and can’t be “All”.

network_id={value}

(Optional) The network ID of the network you want to assign the asset group to.

{parameters)

See Asset Group parameters

 

Sample - Add new asset group

API request

curl -u "USERNAME:PASSWD" -H "X-Requested-With: Curl" -X "POST"

-d "title=MY DEMO AG&network_id=1220&comments=This is comment&division=this is divison&location=this is

location&business_impact=high&cvss_enviro_cdp=low&cvss_enviro_td=low&cvss_enviro_cr=medium&

cvss_enviro_ir=high&cvss_enviro_ar=medium&ips=10.1.1.1/31" "https://qualysapi.qualys.com/api/2.0/fo/asset/group/?action=add"

XML output

?xml version="1.0" encoding="UTF-8" ?>

<!DOCTYPE SIMPLE_RETURN SYSTEM "https://qualysapi.qualys.com/api/2.0/simple_return.dtd">

<SIMPLE_RETURN>

  <RESPONSE>

    <DATETIME>2018-03-28T22:57:50Z</DATETIME>

    <TEXT>Asset Group successfully added.</TEXT>

    <ITEM_LIST>

      <ITEM>

        <KEY>ID</KEY>

        <VALUE>395752377</VALUE>

      </ITEM>

    </ITEM_LIST>

  </RESPONSE>

</SIMPLE_RETURN>

DTD

<platform API server>/api/2.0/simple_return.dtd