# Advanced Insights Active Directory Group to Role Assignment

*Applies to: Patch My PC Advanced Insights*

Active Directory Group Authentication enables the Advanced Insights administrator to associate Advanced Insights Roles with AD Security Groups. This ensures that a new user is automatically granted the relevant rights in the portal without the need for manual user creation.

To use this feature, first enable Active Directory Authentication using Administration - Settings - User Management, more details [here](https://docs.patchmypc.com/installation-guides/advanced-insights/active-directory-integration).

Once this is configured, we can assign an existing role to an Active Directory Group, or create a new role for a group. **N.B. There is currently no support for nested groups.**

**Assigning a Role to an Active Directory Group**

Navigate to **Administration** > **Roles**.

1. Click Create new role
2. Enter a name for the role (in this example, "Helpdesk"
3. Type the name of the associated Active Directory Security Group, here, we are using "sg-Helpdesk". Ensure the group name is validated on save.

<figure><img src="/files/3Kj97w8lzA2VImWU4AOD" alt=""><figcaption><p>Role creation dialog</p></figcaption></figure>

Now click the Permissions tab and select the pages and permissions you want to grant to this role.

<figure><img src="/files/DXN3fomp2I22Hs8OLMcf" alt=""><figcaption><p>Role Permissions</p></figcaption></figure>

Logging on with an account in the helpdesk role, the user is granted only the access stated in the role configuration:

<figure><img src="/files/0JSmztNRGP4tBmse7cBI" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.patchmypc.com/patch-my-pc-insights/advanced-insights-active-directory-group-to-role-assignment.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
