Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Modify a PHDC Configuration

    Use this API to modify a product health data collection (PHDC) configuration. While modifying a PHDC, devices can be added or removed from the PHDC configuration. Other parameters such as Collection Period, Upload PHD file to Juniper, Delete PHD files after upload, and Mask iP Addresses can also be modified.

    URI

    https://[host] /api/juniper/servicenow/phdc-management/phdcs/{id}}/modify (HTTP method = PUT)

    URI Parameters

    Parameter

    Type

    Required

    Description

    id

    Integer

    Yes

    ID of the PHDC configuration to be modified

    Consumes

    • application/vnd.juniper.servicenow.phd-management.modifyPHDC +json;version=1;charset=UTF-8
    • application/vnd.juniper.servicenow.phd-management.modifyPHDC +xml;version=1;charset=UTF-8

    Request Elements

    Element

    Type

    Description

    devicesToAdd

    devicesToAdd

    Collection of devices to be added to the PHDC configuration

    devices

    String

    Link to the devices to be added to the PHDC configuration

    devicesToRemove

    devicesToRemove

    Collection of devices to be removed from the PHDC configuration

    devices

    String

    Link to the devices to be removed from the PHDC configuration

    collectionPeriodInDays

    String

    Number of days product health data (PHD) is to be collected from devices

    domainId

    Integer

    ID of the domain in which the PHDC configuration is created.

    This is an optional element. The value provided in this element is ignored if the value is invalid or a domainId other than the current domainId is provided.

    Produces

    • application/vnd.juniper.servicenow.phd-management.phdStatusMsg+json;version=1
    • application/vnd.juniper.servicenow.phd-management.phdStatusMsg+xml;version=1

    Response Elements

    Element

    Type

    Description

    id

    String

    ID of the PHDC configuration modify job

    statusMessage

    String

    Status message of the modify PHDC job

    Sample Input

    Sample XML Input

    <modifyPHDC>
       <devicesToAdd>
          <device href="/api/juniper/servicenow/device-management/devices/34662" uri="/api/juniper/servicenow/device-management/devices/34662"/>
       </devicesToAdd>
       <devicesToRemove>
          <device href="/api/juniper/servicenow/device-management/devices/35584" uri="/api/juniper/servicenow/device-management/devices/35584"/>
       </devicesToRemove>
       <configuration>
          <collectionPeriodInDays>20</collectionPeriodInDays>
          
    	 <domainId>10</domainId>
       </configuration>
    </modifyPHDC>
    

    Sample JSON Input

    {
       "modifyPHDC": {
          "devicesToAdd": {
             "device": {
                "@href": "/api/juniper/servicenow/device-management/devices/34736",
                "@uri": "/api/juniper/servicenow/device-management/devices/34736"
             }
          },
          "devicesToRemove": {
             "device": {
                "@href": "/api/juniper/servicenow/device-management/devices/34740",
                "@uri": "/api/juniper/servicenow/device-management/devices/34740"
             }
          },
          "configuration": {
             "collectionPeriodInDays": "20"
          }
       }
    }

    Sample Output

    Sample XML Output

    <phdStatusMessage>
       <id>1081345</id>
       <statusMessage>Product Health Data Configuration modified successfully</status-message>
    </phdStatusMessage>
    

    Sample JSON Output

    {
      "phdStatusMessage": {
        "id": "1081345",
        "statusMessage": "Product Health Data Configuration modified successfully"
          }
    }
    

    Modified: 2017-07-19