> For the complete documentation index, see [llms.txt](https://docs.trustlogix.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.trustlogix.io/integrations/single-sign-on/azure-active-directory-ms-entra/user-deprovisioning-from-azure-ad.md).

# User Deprovisioning from Azure AD

### Enable User Deprovisioning

To enable automatic user deprovisioning from Azure AD to TrustLogix, follow these steps:

#### Step 1: Enable Auto Deprovisioning in TrustLogix

1. Navigate to existing Azure AD SSO Integration item.&#x20;
2. Click the **Enable Auto Deprovisioning** button in TrustLogix.
3. There are three fields that you need to populate in the TrustLogix UI
   1. Azure Tenant ID
   2. Client ID
   3. Client Secret Value
4. To retrieve these values, go to Azure and search for "App registrations" and then search for the SSO application that has been created under the "All applications"
5. Click on the SSO application and on the main page you will find the following values
   1. Directory (tenant) ID
   2. Application (client) ID&#x20;
6. You will have to generate a new client secret by going to the "Certifications & secrets" option under "Manage" option&#x20;
   1. Click on <img src="/files/GUpfaitb5rySrjWPbnZw" alt="" data-size="line">to generate a new client secret.
7. Now populate the values in the TrustLogix UI with the tenant ID, client ID and client secret Azure values and save them.
8. For the User Deprovisioning to happen in TrustLogix, the SSO application should be provided with the Microsoft Graph service Read API permissions.
   1. Go to "API permissions" option under "Manage" option.
   2. Click on <img src="/files/ApyIlYPEs98PdZZ7oJP8" alt="" data-size="line"> button and select "Microsoft Graph" service.
   3. Then click on the "Application permissions" button and search for "DelegatedPermissionGrant" as well as "User" permissions to select the Read permission e.g.  <img src="/files/ZCNhekI8cyJiqNt1Bn9x" alt="" data-size="line"> and click on the "Add permissions" button.
   4. Click on "Grant admin consent for Default Directory" button to provide the above Read permissions <img src="/files/TkysCubb3pxvMMH9UPIe" alt="" data-size="line">

***

### Notes

* If **Auto User Deprovisioning is disabled**, customers must manually remove users in the TrustLogix application.
* If **Auto User Deprovisioning is enabled**, users removed in Azure AD will be automatically be removed from the TrustLogix application.

By following these steps, TrustLogix will be successfully integrated with Azure AD for automatic user deprovisioning.


---

# 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.trustlogix.io/integrations/single-sign-on/azure-active-directory-ms-entra/user-deprovisioning-from-azure-ad.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.
