getNetworkInventoryItems
This method returns network inventory items.
Services
This method requires you to place the {service}
name in the API URL. The allowed services are:
computers
, for "Computers and Virtual Machines"virtualmachines
, for "Virtual Machines"
For example, the request URL for the virtual machines
service is:
https://YOUR-HOSTNAME/api/v1.0/jsonrpc/network/virtualmachines
The details member
Some network inventory items contain a details
member. This member exposes more information regarding the item. The information depends on the item type.
Item type | Details |
---|---|
|
|
Example
Request:
{ "params": { "parentId": "5c373e1a1da1974a678b456d", "perPage": 100, "filters": { "type": { "groups": true }, "depth": { "allItemsRecursively": true } } }, "jsonrpc": "2.0", "method": "getNetworkInventoryItems", "id": "tracking" }
Response:
{ "id":"103d7b05-ec02-481b-9ed6-c07b97de2b7a", "jsonrpc":"2.0", "result": { page: 2, pagesCount: 11, perPage: 1, total: 11 items[ { "id" : "21a295eeb1a43d8b497b24b7", "name" : "Computer", "type" : 5, "parentId": "21a295eeb1a43d8b497b24b7", "companyId": "21a295eeb1a43d8b497b24b7", "details" : { "label" : "endpoint 2", "fqdn": "endpoint2.local", "groupId": "5a5f4d36b1a43d5f097b23bb", "isManaged": true, "machineType": 2, "operatingSystemVersion": "Windows Server", "ip": "60.40.10.220", "macs": [ "324935237346" ], "modules": { "advancedThreatControl": False, "antimalware": True, "contentControl": False, "deviceControl": False, "firewall": False, "powerUser": False, "networkAttackDefense": False }, "ssid": "", } } ] } }
Parameters
Parameter | Type | Optional | Description |
---|---|---|---|
| String | Yes | The ID of the target company or group. If not specified, the method returns items that are in the targets of the company linked to the API key. |
| Object | Yes | The filters to be used when querying the endpoints list. For information regarding the available filters and how to use them, refer to Available Filters. |
| Number | Yes | The ID of the view type. Each virtualization platform displays the inventory in specific views. In VMWare integrations, the available options are:
In Citrix XenServer integrations, the available options are:
|
| Number | Yes | The results page number. Default page number is 1. |
| Number | Yes | Number of items per page to be returned. The upper limit is 100 items per page. Default value: 30 items per page. |
Available filters
Section | Subsection | Filtering Options |
---|---|---|
|
| |
| management |
|
|
| |
|
|
Important
Some filters require a specific license to be active, otherwise they are ignored, resulting in an inaccurate API response.
The field name
works with partial matching.
The filter returns the items whose names are exact match or start with the specified value. To use the specified value as a suffix, use the asterisk symbol (*).
For example:
If name
is computer
, the API returns all items whose names start with computer
.
If name
is *puter
, then the API returns a list of all items that contain puter
in their names.
Return value
This method returns an Object containing information about the network items. The returned object contains:
page
- the current pagepagesCount
- the total number of pagesperPage
- the total number of items returned per pagetotal
- the total number of itemsitems
- an array containing the list of items. Each entry in the list has the following fields:id
, the ID of the network item,name
, the name of the network item,parentId
, the ID of the parent container,type
, the type of network item:1
- Company,2
- Root Container (Companies and Network containers),3
- Company Folder,4
- Group,5
- Computer,6
- Virtual Machine,7
- EC2 Instance,14
- Containers Group,15
- Container Host Folder,16
- Container.details
, more information about the item. This field is available for1
- Companies,5
- Computers,6
- Virtual Machines,7
- EC2 Instances and16
- Containers. For information regarding the content of the details member please refer to The details member.
The details member
Some network inventory items contain a details
member. This member exposes more information regarding the item. The information depends on the item type.
Item type | Details |
---|---|
|
|
Example
Request:
{ "params": { "parentId": "5c373e1a1da1974a678b456d", "perPage": 100, "filters": { "type": { "groups": true }, "depth": { "allItemsRecursively": true } } }, "jsonrpc": "2.0", "method": "getNetworkInventoryItems", "id": "tracking" }
Response:
{ "id":"103d7b05-ec02-481b-9ed6-c07b97de2b7a", "jsonrpc":"2.0", "result": { page: 2, pagesCount: 11, perPage: 1, total: 11 items[ { "id" : "21a295eeb1a43d8b497b24b7", "name" : "Computer", "type" : 5, "parentId": "21a295eeb1a43d8b497b24b7", "companyId": "21a295eeb1a43d8b497b24b7", "details" : { "label" : "endpoint 2", "fqdn": "endpoint2.local", "groupId": "5a5f4d36b1a43d5f097b23bb", "isManaged": true, "machineType": 2, "operatingSystemVersion": "Windows Server", "ip": "60.40.10.220", "macs": [ "324935237346" ], "modules": { "advancedThreatControl": False, "antimalware": True, "contentControl": False, "deviceControl": False, "firewall": False, "powerUser": False, "networkAttackDefense": False }, "ssid": "", } } ] } }