Doku durchsuchen
Menü
Geändert am Auf GitHub bearbeiten

Konsole: inventory

Als Markdown kopieren

Diese Routen liegen auf der Konsole, Port 3375. Sie nehmen ein API-Token als Authorization: Bearer ndt_...; siehe API-Tokens. Die Beschreibungen stehen auf Englisch, wie in der OpenAPI-Beschreibung.

Hardware and software inventory of devices.

GET /api/inventory

List the devices that reported their inventory, with their hardware in short.

The last report first. While no device has reported, the list holds the devices the server knows instead, with source peer_list and empty hardware. An account limited to some devices gets only those. Errors other than the sign-in and permission checks are {"error": "..."}.

Needs device.view. neodesk inventory list calls it.

Parameter In Type What it is
page query integer default 1, at least 1
limit query integer Devices per page; more than 100 counts as 100; default 50, at least 1, at most 100

200: Done (application/json)

Field Type Required What it is
devices array of object yes
devices[].collected_at string or null (date-time)
devices[].cpu string
devices[].cpu_cores integer
devices[].cpu_percent number or null
devices[].device_id string
devices[].disk_count integer
devices[].disk_max_free_bytes integer The free bytes of the fullest disk
devices[].disk_max_mount string The mount point of the fullest disk
devices[].disk_max_used_percent number Only when the report has disks: how full the fullest disk is, in percent
devices[].hostname string
devices[].last_seen string or null (date-time) When the server received the report
devices[].memory_total_bytes integer
devices[].memory_used_bytes integer
devices[].os string
devices[].os_name string
devices[].software_count integer
devices[].source string peer_list for a device from the server's list while no device has reported
limit integer yes
page integer yes
total integer yes
total_pages integer yes
Error When
400 page or limit is not a whole number from 1 up
401 No session or API token, or one that is not valid (code session_required or token_invalid)
403 The account or the token may not do this, or a write from a browser came without a good CSRF token

GET /api/inventory/{id}

Show one device's last inventory report with its last telemetry.

The report as the agent sent it. Errors other than the sign-in and permission checks are {"error": "..."}.

Needs device.view. neodesk inventory get calls it.

Parameter In Type Required What it is
id path string yes The device ID

200: Done (application/json)

Field Type What it is
collected_at string or null (date-time)
device_id string
hardware object
hardware.architecture string
hardware.cpu object
hardware.cpu.brand string
hardware.cpu.logical_cores integer
hardware.cpu.usage_percent number
hardware.disks array of object
hardware.disks[].device string
hardware.disks[].filesystem string
hardware.disks[].mount_point string
hardware.disks[].total_gb number
hardware.disks[].used_gb number
hardware.hostname string
hardware.kernel string
hardware.memory object
hardware.memory.total_bytes integer
hardware.memory.used_bytes integer
hardware.network_interfaces array of object
hardware.network_interfaces[].ip_addresses array of string
hardware.network_interfaces[].mac string
hardware.network_interfaces[].name string
hardware.os_name string
hardware.os_version string
received_at string or null (date-time)
software object
software.apps array of object
software.apps[].installed_at string or null (date-time)
software.apps[].name string
software.apps[].publisher string
software.apps[].version string
telemetry object or null The last telemetry, null when the device sent none
telemetry.cpu_usage_percent number
telemetry.device_id string
telemetry.memory_total_bytes integer
telemetry.memory_used_bytes integer
telemetry.received_at string or null (date-time)
telemetry.timestamp string or null (date-time)
telemetry.uptime_seconds integer
Error When
401 No session or API token, or one that is not valid (code session_required or token_invalid)
403 The account lacks device.view, or the device is outside its scope or unknown
404 No inventory data for this device

Durchsucht Seiten, Abschnitte, Befehle und Einstellungen.