Inventory Services
Inventory Services
Administrators can extend the integration capabilities of Automation Platform by using Inventory Services. An Inventory Service consists of a PowerShell function that can be called to retrieve service ownership information for a given user or computer. The inventory information is dynamically retrieved from external (master) sources and shown in the My Services view. Actions can then be taken on the information retrieved
The function will be called with a Parent ID, and then a set of Inventory Keys should return a list of InventoryServiceInstance objects created through the New-InventoryServiceInstance function. A simple example function is created when a new Inventory Service is added.
Note
When copying and pasting PowerShell function text into an Inventory Service, incorrect row breaks may occur which will result in errors. To avoid this:
- Paste the function text into Notepad, and then save it in the UTF-8 format.
- Copy the text from the Notepad file, and then paste it into the Inventory Service.
Limitations: The function signature cannot be changed.
Setting the Service to be Inventoried
- Select Service Admin from the Administer Menu.
- Select the Service to be inventoried.
- Open the Instantiate Tab.
icon to add a new Service type. For example, Software. The Service type will be connected to the Inventory Service once it has been created.
Creating the Inventory Service
- Select Inventory Services from the Administer menu
- Select Add inventory service, and give the inventory service a Name and a Description.
- Click Save. The inventory service is created.
- Select View on the Inventory Service to open up the Function editor of the Inventory Service.
Note
The PowerShell script in the Function section is an example that requires minimal modifications before execution. Use this example as a guide to build your inventory service. It is recommended to edit the script in a PowerShell editor.
Key Terms:
- ParentId : user name, computer name are available by default.
- InventoryKeys : A unique identifier for a service. This is what connects the inventory service instance to a service.
- New-InventoryServiceInstance : The PowerShell function which return an Inventory Service Instance object.
- Add-InstanceAttribute : A PowerShell function that sets the attributes to the Inventory Service. These will be displayed under the Service Properties on the My Services page view.
- Select Save once the PowerShell script of the Inventory Service is complete.
Connecting the Inventory Service to the Service
-
Select Service Admin from the Administer Menu.
-
Select the Service that is to be Inventoried.
-
Open the Instantiate Tab.
-
Select
on the Service type. An Edit service type dialog box will appear.
-
Complete the Edit Service type dialog box.
a. Select Add inventory service.
b. Select the Service type from the Parent drop-down selection
c. Select the Inventory Service that has been created for this service.
d. Press the disk icon to save the selections made.
e. Press **Save.
The Inventory service is now connected to the service.