Sep 20 2018 01:57 AM
Hi All
Hope everyone is well. Can someone perhaps assist me please?
I need to get list of all the mobiles devices that is currently syncing with my Office 365 tenant.
I found some scripts online but I am bit reluctant to use those.
Appreciate any advice...
Sep 20 2018 04:47 AM
You can try this script
$credential = Get-Credential
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell -Credential $credential -Authentication Basic -AllowRedirection
Import-PSSession $Session
$mdevices = Get-MobileDevice -ResultSize Unlimited
$mdevices | Foreach-Object{
$mdevice = $_
$mstats = $mdevice | Get-MobileDeviceStatistics
New-Object -TypeName PSObject -Property @{
UserDisplayName = $mdevice.UserDisplayName
DeviceFriendlyName = $mdevice.FriendlyName
DeviceId = $mdevice.DeviceId
DeviceImei = $mdevice.DeviceImei
DeviceFirstSyncTime = $mdevice.FirstSyncTime
DeviceAdminDisplayName = $mdevice.AdminDisplayName
DeviceName = $mdevice.Name
DeviceLastSuccessSync = $mstats.LastSuccessSync
DevicePhoneNumber = $mstats.DevicePhoneNumber
Status = $mstats.Status
}
}|Export-csv -Path C:\result.csv -NoTypeInformation
Sep 20 2018 08:10 AM
If you don't want to use PowerShell, simply use the Exchange Online Admin Center? There is also an report in the O365 admin portal: https://portal.office.com/adminportal/home#/reportsUsage/EmailClients