Add individual managed items to groups using the groups web service. The item ID for each item is required.
Start by using the devices web service to get a list of managed items in the database and their IDs. The get id names method returns a list of identifiers that can be used in other methods to identify devices. A submethod, get interfaces, returns a list of device interfaces. You can filter the results by item subtype.
Checking is performed to avoid item duplication and make sure the group is valid. If any of these steps fail, then the service will exit out with an error:
Each item that is specified in the list is also validated according to the following criteria:
The XML that is returned shows the results of the validation. They include a report of the items that were added and the items that were not added.
Follow these steps:
http://CA Performance Center Server IP Address:8181/pc/center/webservice/devices/idNames
http://CA Performance Center Server IP Address:8181/pc/center/webservice/groups /idName/idValue/items
A supported ID name for specifying a group. Possible values can be retrieved by performing a GET operation on the following URL:
http://CA Performance Center Server IP Address:8181/pc/center/webservice/groups/idNames. Use one of the following parameters for the idName:
groupItemId - The internally assigned ID of the group.
groupPath - The path of the group, with each group delimited by encoded front slashes (%F2).
The value that is used to specify a group, based on the nature of the ID name. Dependent on the value of the idName field, as follows:
groupItemId - The ID of the group is expected.
groupPath - The path of the group, with each group delimited by encoded front slashes (%20) is expected.
<items>
<item id=”value”/>
</items>
<items>
<item id=”684”/>
</items>
You can also submit a list of managed items to add to a single group.
<items>
<item id=”123”/>
<item id=”234”/>
<item id=”345”/>
<item id=”456”/>
<item id=”567”/>
</items>
|
Copyright © 2015 CA Technologies.
All rights reserved.
|
|