cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
anon1m0us
Frequent Visitor

Group Membership

I created a flow that add a user to a security group. Based on group membership it adds a O365 license to the user (E3 or F1).

The issue is, if there are no licenses available, I need it to error and send an email to the Admin to buy additional licenses.

 

How would I do that?Capture.JPG

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @anon1m0us ,

 

Sorry for there is no any way to check if there is a enough licenses in Microsoft flow currently.

 

Best Regards,

Alice

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
DeepakS
Resident Rockstar
Resident Rockstar

Hi @anon1m0us ,

 

If you are getting an error on "Add user to E3 group" then you can configure run after action on error and send the email. 

RunAfter.jpg

If you are not getting an error you can check user membership and if it does not changed to E3 your send email

 

Regards,

Adding to a group is not an issue. In Azure AD I assigned licenses to the group. Any user that gets added to the group gets a license. The issue I have is how do I check if I have enough licenses? If I used up all my licenses, Flow will still complete successfully but Azure won't add another license since there are none available. 

I need to check available licenses prior to adding a user in a group.

 

Isaac

Hi @anon1m0us ,

 

Sorry for there is no any way to check if there is a enough licenses in Microsoft flow currently.

 

Best Regards,

Alice

 

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Is there a way to just order a license? 

Hi @anon1m0us ,

 

Sorry for there is no any way to achieve it with Microsoft flow.

 

Best regards,

Alice   

Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

You could do it using this approach:

https://janbakker.tech/use-power-automate-or-logic-apps-to-keep-an-eye-on-your-licenses/ 

 

That gives you a way of checking license status using MS Graph. You could then use the calculations used in the link to test for available licenses, before deploying, and the sending email if you lack licenses.

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Users online (3,124)