Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tools4everbv/helloid-task-sa-source-activedirectory-groupgetaccountmemberships
Active Directory - Group get account memberships
https://github.com/tools4everbv/helloid-task-sa-source-activedirectory-groupgetaccountmemberships
active-directory data-source powershell service-automation
Last synced: about 1 month ago
JSON representation
Active Directory - Group get account memberships
- Host: GitHub
- URL: https://github.com/tools4everbv/helloid-task-sa-source-activedirectory-groupgetaccountmemberships
- Owner: Tools4everBV
- Created: 2024-01-31T09:13:59.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-01-31T09:27:59.000Z (11 months ago)
- Last Synced: 2024-02-01T10:43:15.785Z (11 months ago)
- Topics: active-directory, data-source, powershell, service-automation
- Language: PowerShell
- Homepage:
- Size: 26.4 KB
- Stars: 0
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# HelloID-Task-SA-Source-ActiveDirectory-GroupGetAccountMemberships
## Prerequisites
- [ ] The HelloID SA on-premises agent installed
- [ ] The ActiveDirectory module is installed on the server where the HelloID SA on-premises agent is running.
- [ ] Data source input parameter (required parameter) named `selectedGroup`. The linked form-element should at least return a model containing the `name` property## Description
This code snippet executes the following tasks:
1. Define `$groupName` based on the `selectedGroup` data source input `$datasource.selectedGroup.name`
2. Imports the ActiveDirectory module.
3. Retrieve the AD group using the `Get-ADgroup` cmdlet.
4. Get the AD account memberships of the AD group using the `Get-ADGroupMember` cmdlet.
5. Return a hash table for each account membership using the `Write-Output` cmdlet.> To view an example of the data source output, please refer to the JSON code pasted below and select the `Interpreted as JSON` option in HelloID
```json
{
"name": "All Managers"
}
```