web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Scheduled disabling of...
Power Automate
Unanswered

Scheduled disabling of an account

(0) ShareShare
ReportReport
Posted on by

I'm trying to setup a flow that will allow me to disable an account at a specified time. I currently have it setup to use an adaptive card in Teams, which allows me to search for a user, then a date and a time field to specify the exact Delay until time before deactivating the account.

I have been using the HTTP connector to disable the account with Graph up to this point, but that connector is technically marked as Premium, so even though it working fine I'm just waiting on MS to kill it for me.

I tried using the standard 'Send an HTTP request' from the Office 365 Users connector, but this doesn't seem to work as the URI treats the user ID as part of the resource (users/[ID])/[Expected Object] and not as the object I am trying to modify (users)/[ID as Object]. This seems to be intentional for whatever reason, from the documentation.

I then looked at the Entra ID connector and the Update user action. This has a nice looking toggle for disabling the account, which errors out saying I have insufficient privileges when I attempt to use it. I can change the other values just fine when testing. Documentation for this one says I need Group, User, and Directory permissions - ReadWrite.All all round. I have these and Global admin but still get rejected on live accounts.

When I create a test account I can enable and disable it just fine, but accounts that have been signed into previously and are 'active' I guess you'd say, just don't seem to work. Using the Graph Explorer site works just fine as well with my account when testing for privileges if that helps, although the current HTTP connector is using AD OAuth and a Client ID/secret.

I'm all ears for ideas on why this doesn't want to play ball. Cheers

Categories:
I have the same question (1)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 507 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 267 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard