Power shell Automation - Add/Update users to AD account
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-07-2023 02:25 AM
Hi all,
I have 2 requirements in PowerShell automation for a catalog item related to AD account, where users are Added/Updated through workflow using run script.
1st requirement:
- If User Exists → Task is Closed Complete → Go to Task 2
- If User does not Exist → Task is Rejected → Parent request is Closed → Cancelled.
- IM Serve needs to send notification to both Manager and the submitter with message: “User does not exist in X4A. Please submit ‘New X4A User’ Request instead with requested Roles and Country assignment” .
I need help in an emil to trigger to manger and requestor for when the task is closed complete/Rejected.
How can I trigger email in workflow through script. Please guide me on this this
2nd requirement for adding users in AD account:
- In case user already exists:
- Mention user already existed.
- Task is Closed Complete.
- Go to Task 2.
I had already worked on adding using to AD account using PS automation but did not work on querying the AD account and check whether the user is available or not and update users accordingly. But did not query the AD account table and validate users already existing or not.
Here is the script which I used for adding users to AD account:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-07-2023 04:36 AM
Hi,
Are you using integration hub or orchestration?
Thanks and Regards,
Saurabh Gupta
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-07-2023 07:46 PM
@Hi @Saurabh Gupta
I am using workflow editor to run this automation. Could you please help me to achieve this requirement?
Thanks,
saran.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-07-2023 08:55 PM
Hi,
Use the Remove User from AD group activity and achieve it.
Thanks and Regards,
Saurabh Gupta