> For the complete documentation index, see [llms.txt](https://docs.nuvens.cloud/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nuvens.cloud/admin/appendices/ad-group-mapping.md).

# AD Group Mapping

Before you can map Active Directory (AD) groups to roles in WorkSpaces Manager, you first need to create and validate the AD groups. You can do this by following the instructions on the [Active Directory Groups](/admin/security-section/active-directory-groups.md) Page.

Now the Groups have been validated we can now map to Roles to create WSM Role. Go to **Security** > **Roles** and click **Create Role**, enter a Name and click **Create.**

<figure><img src="/files/6Q47xueoIcHfDHb7mMWL" alt=""><figcaption></figcaption></figure>

Once the role has been created, click on it to open the configuration page. In the top-left corner, you'll see the **"AD Group Mapping"** dropdown. From there, select the **Active Directory Group** you want to associate with this role.

Next, define the permissions for the role. For example, in this case, we're assigning the WSMTest AD Group and granting users access only to the Admin and WorkSpaces tabs. This ensures users in that group have restricted, role-specific access when using WorkSpaces Manager.

<figure><img src="/files/rDdl1TuH1ks36dfjn9cS" alt=""><figcaption></figcaption></figure>

Users who belong to the mapped Active Directory group will automatically have the assigned role applied to them in Portal Users within WorkSpaces Manager.

<figure><img src="/files/XrnTuWJF82QFpcQ3fbNN" alt=""><figcaption></figcaption></figure>

When users log in to the portal, they will authenticate using their Active Directory credentials (e.g., `Domain\username`). Once logged in they will only see the sections and functionality that correspond to the permissions assigned to their mapped role.

Refer to the example below to see how these role-based permissions are reflected in the user interface.

<figure><img src="/files/wyTTPahKBRE6iHMA8kI2" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.nuvens.cloud/admin/appendices/ad-group-mapping.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
