Share via

Policy CSP - LocalUsersAndGroups through powershell graph

Barak Peley 0 Reputation points
2024-10-21T08:27:14.9666667+00:00

To manage the Policy CSP - LocalUsersAndGroups, I am working on creating PowerShell API calls that can be executed on any device within the tenant.

I would like to implement a policy for each device that allows me to designate or remove a user as an admin. While I aim to create this policy, I am encountering an issue: when I utilize the Intune UI, I am required to upload an XML file to the string (xml).

To achieve this using Microsoft Graph API calls and PowerShell, the question is: how can I implement it effectively?

Microsoft Security | Intune | Other
Microsoft Security | Microsoft Graph
0 comments No comments

1 answer

Sort by: Most helpful
  1. Anonymous
    2024-10-22T01:25:58.3933333+00:00

    @Barak Peley Thanks for posting in our Q&A.

    Based on my research, I didn't find such graph API. However, there is a built-in setting can designate or remove a user as an admin in intune. It is not needed to upload an XML file. Please Select Endpoint security > Account protection. Select Create Policy and choose Windows 10 and later as the platform and Local user group membership. For more details, please refer to the following article:

    https://techcommunity.microsoft.com/t5/intune-customer-success/new-settings-available-to-configure-local-user-group-membership/ba-p/3093207

    Hope it will give you some ideas.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.