Endpoint API not returning "online" field

According to the Endpoint API documentation, GET endpoint should return a field named "online" that indicates if a device is online.

https://developer.sophos.com/docs/endpoint-v1/1/routes/endpoints/get )

However, when I pull endpoint info, I only get the following fields:

id
type
tenant
hostname
health
os
ipv4Addresses
macAddresses
associatedPerson
tamperProtectionEnabled
assignedProducts
lastSeenAt
isolation

What do I need to do? My API call is as follows:

$devicesUrlTemplate = "https://api-us01.central.sophos.com/endpoint/v1/endpoints?hostnameContains=$Hostname"

$devicesResponse = Invoke-RestMethod -Uri $devicesUrlTemplate -Method Get -Headers @{
    "Authorization" = "Bearer $Token"
    "Content-Type"  = "application/json"
    "X-Tenant-ID" = $tenantID.id
    }    

$tenantDevices = $devicesResponse.items
$tenantDevices



Move code to code box
[edited by: David Thatcher at 2:46 PM (GMT -8) on 12 Dec 2024]