Click HERE to see how Saviynt Intelligence is transforming the industry. |
08/19/2024 09:50 AM
Hello All, we want send a ticketing email to ticket@company.com in case of the entitlement removal except "xyz group", how is that possible? I am thinking of using a condition on TO address of the email template but didn't find any close resource, any leads?
08/19/2024 09:57 AM
Please validate supported variables.
Purpose :
To get what variables are present to use in the email template.
Email Template steps :
keep Advanced HTML CSS flag is checked
Keep your email Address in TO
TO /CC/BCC & Subject - Don't use any dynamic variables
Add only below code in Email Body
${this.binding.variables.each {k,v -> println "$k = $v" + "" + "br" + ">"}}
Output : using the below expression. By putting it in the email body, it will print all variable names with values, and then accordingly, you can use it:
08/19/2024 10:05 AM
This is what i got based on above body, is it expected?
entitlement_endpoint_list = []br> manager = Donald.Duckbr> createdBy = adminbr> service_accounts_list = []br> ownerOnTerminate = Donald.Duckbr> serviceaccount_endpoints_list = []br> baseUrlForEmail = https://release-n-plus-one.saviyntcloud.com/ECMbr> user = Savtester.Thursdaybr> requestor = Santosh.Nepalbr> entitlement_value_list = []br> out = java.io.PrintWriter@2addee66br> [entitlement_endpoint_list:[], manager:Donald.Duck, createdBy:admin, service_accounts_list:[], ownerOnTerminate:Donald.Duck, serviceaccount_endpoints_list:[], baseUrlForEmail:https://release-n-plus-one.saviyntcloud.com/ECM, user:Savtester.Thursday, requestor:Santosh.Nepal, entitlement_value_list:[], out:java.io.PrintWriter@2addee66]
08/19/2024 10:10 AM
Since entitlement_value_list is blank you can't filter on specific entitlement
08/19/2024 10:14 AM
Also, can we not utilize the entitlement_vlauekey !=108 or something like that on ars.task?
08/19/2024 10:16 AM
There is no task object also,
Where did you attached template ?
08/19/2024 10:24 AM
I have not attached the email template yet but was thinking on towards endpoint (access removal==task complete). the test earlier I did was from user update rule.
08/19/2024 10:36 AM - edited 08/19/2024 10:17 PM
Variables varies where you attached. Hence if variable is exposed you can add conditional logic
<%if (task?.entitlementValueKey=='100') print "${user.email},${requestor.email}" else print "" %>
08/19/2024 09:40 PM
Hi @Santosh , for remove access if you attach the email in endpoint .. you will get an entitlement variable which you can use.
08/20/2024 07:57 AM
tried this,
<%if (task?.entitlementValueKey!='63175') print "hardcoded my email" else print "" %>,
attached the template to endpoint---remove Access---> Task complete
but it does not seem to be working, was I supposed to save the template in CSS/HTML format?
08/20/2024 08:31 AM
Did you validated variables exposed ?
08/20/2024 09:35 AM
This is what i got on testing
resourceOwners = Person1, Person2br> tasktype = Remove Accessbr> manager = Donald.Duckbr> accountOwners = []br> randompassword = nullbr> entitlement = [Test Access]br> provisioningOwners = br> users = Frank.Costanzabr> requestor = Santosh.Nepalbr> out = java.io.PrintWriter@e7db16dbr> account_password = XXXXXXXbr> task = com.saviynt.ecm.task.ArsTasks : 41649br> accountname = frank.costanzabr> requestid = 2940126br> endpointDisplayName = ENDPOINTNAMEbr> account_name = frank.costanzabr> endpointOwners = br> requestormanager = Person1> baseUrlForEmail = https://release-n-plus-one.saviyntcloud.com/ECMbr> user = Frank.Costanzabr> taskaction = Remove Accessbr> account = frank.costanzabr> [resourceOwners:Person1, Person2, tasktype:Remove Access, manager:Donald.Duck, accountOwners:[], randompassword:null, entitlement:[Test Access], provisioningOwners:, users:Frank.Costanza, requestor:Santosh.Nepal, out:java.io.PrintWriter@e7db16d, account_password:XXXXXXX, task:com.saviynt.ecm.task.ArsTasks : 41649, accountname:frank.costanza, requestid:2940126, endpointDisplayName:ENDPOINTNAME, account_name:frank.costanza, endpointOwners:, requestormanager:Person1, baseUrlForEmail:https://release-n-plus-one.saviyntcloud.com/ECM, user:Frank.Costanza, taskaction:Remove Access, account:frank.costanza]
08/20/2024 09:41 AM - edited 08/20/2024 09:42 AM
<%if (entitlement?.toString()?.contains('Test Access')) print "hardcoded my email" else print "" %>
08/20/2024 10:37 AM
I used above script on TO address and saved the email template as Advanced HTML CSS. It failed to fetch following attribute values. The name of the test entitlement was "Test Access". Also the condition would be when the entitlement is not Test Access, so the query to use be (<%if (!entitlement?.toString()?.contains('Test Access')) print "hardcoded my email" else print "" %>)?
This email is auto-generated by Saviynt system. It is not a security awareness training exercise. An access removal request is pending your review and approval. Please review the request and provide a response by logging into Saviynt at the following internal location: Review Link Full Name: ${user.firstname} ${user.lastname} Email Address: ${user.email} Job Title: ${user.title} Department: ${user.departmentname} Manager: ${manager.firstname} ${manager.lastname} Company:${user.companyname} Location:${user.location} Application Access Requested: ${endpoint} Application Role/Profile Requested:${entitlements}
08/20/2024 10:41 AM
08/22/2024 01:11 PM
So, it works on TO address for me to receive an email but does not work on the body to get that dynamic variable information?
08/22/2024 01:17 PM
What is working ? ${entitements} ?
08/22/2024 02:11 PM
<%if (!entitlement?.toString()?.contains('Test Access')) print "hardcoded my email" else print "" %>
this one is working.
08/22/2024 03:52 PM
You can use same in email body ${entitlement?.toString()}