Retrieving the list of devices
The devices API uses the GET method to obtain the list of devices. The devices returned in the JSON response are determined by the permissions specified by the authToken. This API returns only those devices accessible to the user specified by the authToken.
APIs that use the POST method
API | Description |
---|---|
Obtains the authToken required to perform all other operations | |
Retrieves configuration data of monitor instances | |
Retrieves performance data of monitor instances |
APIs that use the GET method
API | Description |
---|---|
Retrieves a list of monitored devices | |
Retrieves a list of monitored instances | |
Retrieves a list of monitor types | |
Retrieves a list of tenants |
Before you begin
You must have used the login API to obtain the authToken, which authenticates the user performing the operation. For details, see TSWS-Web-service-authentication.
Request syntax
https://<PresentationServerHostName>/tsws/10.0/api/omprovider/devices
Request parameters
Element | Description |
---|---|
authToken | Value of authToken |
tenantId | Tenant name Example: BmcRealm |
deviceEntityType | Entry from the list of valid device entity types To get devices of all entity types, set the parameter value to all |
parentDeviceId | Device ID of the parent device.
|
Sample request with REST client
After you access the REST client, perform the following steps:
- Enter the URL for the device list API. The generic format is:
https://<PresentationServerHostName>/tsws/10.0/api/omprovider/devices - In the REST client, add the following request parameters:
- tenantId — the tenant name, for example "BmcRealm".
- deviceEntityType — device type as in the entitytype entry for the OS KM instance.
To get devices of all entity types, set the parameter value to all. - parentDeviceId — device ID of the parent device.
-1 ignores the parent device and displays all devices
0 displays all devices that do not have a parent device
- Add a new header row and select Authorization as the header type.
- Enter the text authToken followed by the authToken generated through the login API. See TSWS-Web-service-authentication.
JSON response content
Object | Description |
---|---|
deviceList | |
deviceId |
|
dnaName |
|
ipAddress |
|
deviceType |
|
parentDeviceId |
|
isMarkedForDelete | Either true or false |
tokenList |
|
Sample JSON response
The JSON response follows the standard HTTP response status codes.
Valid device entity types
The following table lists the valid device entity types:
VmWare.Host |
VmWare.Virtual_Machine |
VmWare.Virtual_Center |
Xen.Host |
Xen.Virtual_Machine |
Xen.Pool_Master |
vBlock.ESX |
vBlock.Virtual_Machine |
vBlock.Switch |
vBlock.Storage |
vBlock.Chassis |
vBlock.Blade |
vBlock.Env |
IBM.MG_SYS.Host |
IBM.Frame.Hard_Partition |
IBM.LPAR.Host |
IBM.WPAR.Virtual_Machine |
Sun.ZONE.Virtual_Machine |
Sun.LDOM.Host |
Sun.Zone.Host |
RedHat.KVM.Host |
RedHat.KVM.Virtual_Machine |
RedHat.Xen.Host |
RedHat.Xen.Virtual_Machine |
KVM.Host |
KVM.Virtual_Machine |
HP.NPAR.Hard_Partition |
HP.VPAR.Host |
HP.Integrity.Virtual_Machine |
HP.Integrity.Host |
Microsoft.Hyper-V.Host |
Microsoft.Hyper-V.Virtual_Machine |