Skip to main content

1E 23.7 (SaaS)

Device.GetDisks

Method

GetDisks

Module

Device

Library

Core

Action

Retrieves information about the hardware disk drives

Parameters

(None)

Return Values

DiskId (string): The identifier of the disk

DiskName (string): The vendor-defined name of this disk

DiskType (string): The media type of the disk (e.g. SSD, HDD, SCM or Unspecified if not known)

DiskSerialNumber (string): The serial number of the disk

DiskSizeGb (string): The size of the disk in GB

DiskStatus (string): The status of the disk.

For Windows this is one of the Status values of the Win32_DiskDrive WMI class (OK, Error, Degraded, Unknown, Pred Fail, Starting, Stopping, Service, Stressed, NonRecover, No Contact, or Lost Comm), or Not Available if it cannot be found.

Example

Device.GetDisks();

Platforms

  • Windows, but only from Windows 8 onwards

  • Linux

  • MacOS

Notes

Available from v8.0