Add Primary Users Of Devices To Group Scheduled
Sync primary users of Intune managed devices by platform into an Entra ID group
Last updated
Was this helpful?
Sync primary users of Intune managed devices by platform into an Entra ID group
This runbook collects the primary users of all Intune managed devices matching the selected platform(s) and synchronizes them into a target Entra ID group. Users no longer assigned as primary user on any matching device are removed from the group. An optional include group restricts which users are eligible, and an optional exclude group prevents specific users from being added or keeps them removed.
Organization → General → Add Primary Users Of Devices To Group (Scheduled)
Full Runbook name
rjgit-org_general_add-primary-users-of-devices-to-group_scheduled
Type: Microsoft Graph
DeviceManagementManagedDevices.Read.All
Group.Read.All
GroupMember.ReadWrite.All
User.Read.All
The Entra ID group to synchronize primary users into. Members of this group will be managed exclusively by this runbook.
Required
true
Default Value
Type
String
Include primary users of Windows devices. (OData Filter used "operatingSystem eq 'Windows'")
Required
false
Default Value
False
Type
Boolean
Include primary users of macOS devices. (OData Filter used "operatingSystem eq 'macOS'")
Required
false
Default Value
False
Type
Boolean
Include primary users of iOS and iPadOS devices. (OData Filter used "operatingSystem eq 'iOS'")
Required
false
Default Value
False
Type
Boolean
Include primary users of Android devices. (OData Filter used "operatingSystem eq 'Android'")
Required
false
Default Value
False
Type
Boolean
Optional. Custom OData filter to apply when retrieving devices. Overrides the platform-based filters if provided. Example: startsWith(deviceName,'FWP-') and operatingSystem eq 'Windows' .
Required
false
Default Value
Type
String
When enabled (default), users who no longer have a primary device matching the selected platform(s) are removed from the target group. Disable to add-only mode — existing members are never removed.
Required
false
Default Value
True
Type
Boolean
Optional. Only users who are members of this group are eligible to be added to the target group. Leave empty to consider all primary users.
Required
false
Default Value
Type
String
Optional. Users who are members of this group will not be added and will be removed from the target group if already present.
Required
false
Default Value
Type
String
Last updated
Was this helpful?
Was this helpful?