0 votes

I'm trying to use "Before Modify Office 365" event to request approval for changes. It seems to be kicking off for the "After Create User" event.

How do I request approval for modifications to the Office365 licenses only after a user is created.

I want the automation to license for default settings but if admins want to make a change then it goes out for approval.

by (790 points)
edited by

1 Answer

0 votes
by (6k points)


As far as we understood, you need to assign a default Microsoft 365 (former Office 365) license in a Business Rule triggering After creating a user and this license assignment does not require an approval. At the same time, you need to submit for approval modifications of Microsoft 365 properties for existing accounts. If so, you can mark newly created users in the same Business Rule by setting, for example, a custom Boolean attribute to True. Then, to submit modifications of Microsoft 365 properties for approval, you can create another Business Rule triggering Before modifying Microsoft 365 properties of a user. The rule will submit the operation for approval if the custom Boolean attribute does not equal True. To omit the submission for approval of the default license assignment, the rule will have the Else if block where the custom Boolean attribute will be cleared if it equals True. The order of actions in the Business Rule triggering After creating a user is important, the Modify the user: set CustomAttributeBoolean1 to 'Yes' action should be executed before the license assignment. Finally, the Business Rules configuration should look like the following: image.png


Should you have any issues creating Business Rules, we will provide you with detailed instructions.


Thank you.

I think I wouldn't want to clear the customattribute since I want all requests after the initial create to be approved.

Let me know if I misunderstand.


The more I look at this solution I don't think it works.

After creating a user Boolean = TRUE Before office license if = TRUE then send for Approval If = anything else... do no allow...

I'm hung up on the do not allow.


Ah... Else "Do Nothing



The provided workflow will work as follows:

  1. A new user is created and the Business Rule configured to trigger After creating a user fires.
  2. The first action sets the custom Boolean attribute to True. A Microsoft 365 license is not assigned yet.
  3. The second action assigns a Microsoft 365 license. The custom Boolean attribute is already set to True.
  4. Before the license is assigned the second Business Rule triggers. It checks whether the custom Boolean attribute is set to True. For newly created users it is set to True, so the action in the Else if block is executed to clear the custom Boolean attribute. No approval request is submitted. All successfully created users will not have a value in the custom Boolean attribute.
  5. When attempting to modify Microsoft 365 properties of existing users the second Business Rule will check whether the custom Boolean attribute is set to True. It is already not set for existing users and the first action will send the operation for approval. All the subsequent attempts to modify Microsoft 365 properties will be sent for approval.

Back again.

I have the following business rules.

I am setting the boolean "after"


I then have


This seems to have the effect I want however now I don't want to have to approve the removal of licenses when deprovisioning a user.

Is there a way to check for another custom action and not run if that custom action is run?


If "Deprovision" then Do Nothing


I think I got it. On deprovsision clear the boolean value.

Related questions

0 votes
1 answer

Hi I'm trying to product a report to show the users with either E3, F3 or F5 licenses. If I add the Adaxes "Microsoft 365 Licenses" attribute directly to the report then ... from the user and show a nice "Microsoft E3" etc value. Is this possible? Thanks

asked Sep 27, 2021 by chappers77 (1k points)
0 votes
1 answer

I'm trying to retrive the Microsoft 365 License product name in a report as the 'Office 365 License' attribute in Adaxes shows each individual licensed product e.g. ... 365 F3"} } $productnames = $productnames -join ", " $Context.Value = $productnames

asked Jul 27, 2020 by richarddewis (220 points)
0 votes
0 answers

I'm trying to setup a quick automations to drop a notification into a Micrsoft Teams feed using their Webhook integration. I've managed to make Webhooks work ... -body $body -ContentType 'application/json' Any assistance with this would be gratefully received

asked Jan 20, 2020 by richarddewis (220 points)
0 votes
1 answer

Hi, I try to make a report for our SAM to show all users with a specific license. But I fail to even find anything. I tried, among many ... .DirectorySearcher.AppendFilter("(adm-O365AccountLicenses=POWER_BI_STANDARD)") But I get nothing. Please advice.

asked May 20, 2021 by KristofferJ (80 points)
0 votes
1 answer

Our Office 365 licenses are in a couple different SKU's E3, and E4 licenses. The E4 is an older set of licenses, and we purchased more and was assigned E3's. There are essentialy ... if the E3 licenses are all used, I'd like it to try to Assign the E4 instead.

asked Jun 30, 2017 by rurbaniak (1.4k points)
2,643 questions
2,377 answers
987,406 users