Group

Get-IAMGroup

Synopsis

Get a group.

Syntax

Get-IAMGroup [[-GroupID] <Int32>] [-Actions] [-Flatten] [[-EdgeRCFile] <String>] [[-Section] <String>]
 [[-AccountSwitchKey] <String>] [-ProgressAction <ActionPreference>] [<CommonParameters>]

Description

Gets all groups or returns a specific group by its ID that you, as an admin, can manage for the current account and contract type or other managed accounts.

Note: It's different to how other APIs return the group data, that is, the IAM API nests groups inside their parents. If you want a flattened list of groups without nesting, use the -Flatten parameter.

Parameters

-AccountSwitchKey

Account switch key, for use when you have access to multiple accounts and need to specify which one to use. Run Get-AccountSwitchKey to list the account switch keys available to you.

Type: String
Parameter Sets: (All)
Aliases: None
Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Actions

Includes actions you can perform on the object.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: None
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-EdgeRCFile

EdgeRC file to authenticate your command. Defaults to ~/.edgerc.

Type: String
Parameter Sets: (All)
Aliases: None
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Flatten

Collapse the response so that child groups are not nested within parents and the response is a single-level array.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: None
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-GroupID

Unique identifier for each group.

Type: Int32
Parameter Sets: (All)
Aliases: None
Required: False
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Section

EdgeRC section to retrieve authentication credentials from. Defaults to default.

Type: String
Parameter Sets: (All)
Aliases: None
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

None

Outputs

System.Object

Related links