Description | Disable Accounts at 5PM in Local Timezone | |
Legal Agreement | By using this CoLabitem, you are agreeing to SailPoint’s Terms of Service for our developer community and open-source CoLab. | |
Repository Link | colab-transforms/transforms/Timezone at main · sailpoint-oss/colab-transforms · GitHub | |
New to Transforms in the CoLab? | Read the getting started guide for Transforms in the CoLab. | |
Supported by | Community Developed |
Overview
The Local Time Lookup Offset Transform looks at a user’s Country and Location attributes in the “External Users” Source and uses these values to perform date maths on the date and time now. The date maths do two things:
First:, they add 7 hours for every country or location, this is to ensure the account is disabled 7 hours early (5PM, rather than midnight).
Second: It adds or removes hours based on the users local Timezone, determined by a user’s Country and Location attributes in the “External Users” Source.
Location is used as well as Country because the difference in local time between San Francisco and New York is significant.
Requirements
To use this transform, replace all mentions of “External Users” with the name of the source you want to use. You will also need to replace Country and Location attribute names if the attribute names are different.
Guide
Use the Create Transform API to add this Transform to your environment: create-transform | SailPoint Developer Community
When creating your lifecyclestate rule or transform, rather than referencing now
to compare with a users end date, reference this transform.
It is likely that you will need to amend the Country and Location values, this is acheived by modifying the values in the table. For example USA / New York / San Francisco / CAN
. You can add more countries and locations and also remove as needed.
This transform runs off the UTC timezone, if your VAs are using a different timezone, the maths will be incorrect. Amend as neccessary.
This transform does not take into account time zone changes. When the clocks go forward by one hour for winter in some countries, for example, the UK, accounts will be disabled at 6PM rather than 5PM.