Deprovision of users using REST API (MS Graph)

Alfio Gennaio 21 Reputation points

I am reaching out seeking developer support for Microsoft 365 / Graph API. Specifically, I need to write some Python code that automates the deprovision of a user. Bottom line, I want to avoid the manual steps and use the API to handle the process.

What I cannot figure out or neither find in the documentation are the following two major tasks.

1) Referring to Exchange Admin Center => User’s Mailbox => Email Apps => Manage email apps settings
Does the Graph API allow the management of the email apps?
Can I disable all the apps for a specific user?

2) Referring to Microsoft 365 Admin Center => Delete user => Giving another user access to [first] [last]’s email.
Does the Graph API allow to delete a user while giving another user access to its email?

Would you please let me know if I can automate steps (1) and (2) below exclusively through REST API calls and where the API references are?


Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
10,468 questions
{count} votes

Accepted answer
  1. Vasil Michev 94,206 Reputation points MVP

    1) No, the Graph API currently doesnt cover any Exchange Online admin operations. If you need automation, use PowerShell:
    2) As above, no Graph API endpoints for this, use PowerShell.

0 additional answers

Sort by: Most helpful