How to create custom generation tokens in Attribute Policies
Summary: Custom generation tokens enable the use of initiator attributes in Attribute Policies for creating Active Directory and Microsoft 365 objects. These tokens must be configured in the relevant Web Action form. This article provides step-by-step instructions for creating a team with a "Team_" prefix and the initiator's department name.
Applies to: Cayosoft Administrator 7.2.0 or later.
Configuration
In the Cayosoft Administrator Console, navigate to Configuration > Web Portal > Web Actions > Microsoft 365 > New Team.
Open the Custom Generation Tokens section.
-
Specify this script:
Copy{@{'InitiatorDepartment'=GetInitiatorProperty('department')}},where
InitiatorDepartmentis the token that will be used in the Attribute Policy to get the department value of Web Action initiator. Click Save changes.
Navigate to Configuration > Web Portal > Attribute Policies and create a new policy. For more information about Attribute Policies see this article: Attribute policies .
-
Add policy scope:
-
Select the team name attribute and configure the generation value for it:
On the Attribute Policy Setting for Name, select the Generation value.
Click ...
On the Expression Builder in the Tokens section, click Add.
Select Text as Token Type and set Team_.
Click OK.
Click Add to add one more token.
Click Set custom property.
-
Specify the InitiatorDepartment token name that you specified in the New Team Web Action:
Save changes in the Attribute Policy.
Sign-in to Web Portal.
Check that the user account you are using for sign-in has a value in the department attribute and has permission to create Teams.
Click New Team Web Action.
As a result, you will see that the team name is prefixed with the word “Team_” and also has the department name of the Web Action initiator.
Comments
0 comments
Please sign in to leave a comment.