Need a TRANSFORM that can create user dn(employees and contractor) in different OU in ACTIVE dIRECTORY as per their unique id attribute

hey guys,

I want to create the TRANSFORM that can create the users (employees and contractors) in different OUs in AD in create AD that are coming from different sources (workday for emp and beeline for contracotrs) .

1) Workday (For Employees) :

if the attrbute "unique_id = M001,M002,M003 then create the user in ou=employees

image

and if unique_id = M008 THEN make user in OU = CNTRACTORS LIKE THIS
CN=$(lastname),$(firstname)(initialoffirstname),OU=Contractors,OU= Users,DC=XYZ ,DC=com

2) Beeline : (for contractors)

if the attribute master id = M001,M002,M003,M004 for the user then make the account in OU = contractor like below

image

Kindly give me full logic OF TRANSFORM and kindly give me the logic as well to create CN like this CN=$(lastname),$(firstname)(initialoffirstname),

image

thanks

For the DN, you likely won’t be able to accomplish this with a transform, you’ll need a cloud rule:

Account Profile Attribute Generator | SailPoint Developer Community

For CN, you can use a pattern similar to what you have above, but you’ll likely need to create an identity attribute to store the first initial and add that to the template.

BUT WE need the user CN like this with backslash and , and after that firstinitial in brackets

image

  1. Map the unique_Id to userCode identity attribute in Workday Identity Profile
  2. Map the master_Id to userCode identity attribute in Beeline Identity Profile
  3. Create another identity attribute calculatedOu
  4. Create a different transform in each identity profile to calculate the OU
{
        "name": "AD OU Calculation",
        "type": "lookup",
        "attributes": {
            "input": {
                "attributes": {
                    "values": [
                        {
                            "attributes": {
                                "name": "userCode"
                            },
                            "type": "identityAttribute"
                        },
                        "none"
                    ]
                },
                "type": "firstValid"
            },
            "table": {
                "default": "ou=default,DC=xyz,DC=com",
                "M001": "ou=employees,DC=xyz,DC=com",
                "M002": "ou=employees,DC=xyz,DC=com",
				"M008": "ou=Contractors,DC=xyz,DC=com",
				"none": "ou=default,DC=xyz,DC=com"
            }
        },
        "internal": false
    }
  1. Map the transform to calculatedOu
  2. Refer the calculatedOu in Provisioning plan to set the OU
  3. Similarly, you can either create one more identity attribute to concatenate the firstName and initial with brackets or do it in the create profile. Refer (Concatenation | SailPoint Developer Community) or (Static | SailPoint Developer Community)

This is one way of doing it, but not limited. So you can explore other ways based on your need.

thanks for the response @suresh4iam i have one doubt
3, Create another identity attribute calculatedOu . is this attribute we need to make in both identity prifiles as well ? (wd and beeline) and after creating this calcultedou attribute do we need to map it with userCode AND THEN apply transform ?

Create the attribute in any one of the Identiy profiles it will be populated to another then you can apply the transforms.

1 Like

ok but on which attrobute we have to select one attribute as well from source to map right ?

is this attribute we need to make in both identity prifiles as well ?
Creating an identity attribute in one identity profile will automatically shows in other identity profiles.

do we need to map it with userCode AND THEN apply transform ? Yes, but it doesn’t have any impact since the input is taken from transform itself.

Mapping in Workday:
Identity Attribute: userCode
Source: Workday Account attribute: unique_id
Identity attribute: calculatedOU
Source: Workday Account Attribute: unique_id Transform: OU calculation
Mapping in Beeline:
Identity Attribute: userCode
Source: Beeline Account attribute: master_id
Identity attribute: calculatedOU
Source: Workday Account Attribute: master_id Transform: OU calculation

Hope this gives you a clear idea.

1 Like

thanks a lot @suresh4iam its working as expected one more thing i just need to append my displayName attribute at prefix in the OU as CN so that the output shud be CN=(DISPLAYNAME),ou=employees,DC=xyz,DC=com" CAN WE ACHIVE THIS IN SAME LOGIC ?

Yes, you can.

Also please mark the reply as a solution which helped you to resolve the issue.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.