Set-LMServiceGroup
Syntax
Id-ParentGroupId (Default)
Set-LMServiceGroup -Id <String> [-NewName <String>] [-Description <String>] [-Properties <Hashtable>] [-PropertiesMethod <String>] [-DisableAlerting <Boolean>] [-ParentGroupId <Int32>] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]
Id-ParentGroupName
Set-LMServiceGroup -Id <String> [-NewName <String>] [-Description <String>] [-Properties <Hashtable>] [-PropertiesMethod <String>] [-DisableAlerting <Boolean>] [-ParentGroupName <String>] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]
Name-ParentGroupName
Set-LMServiceGroup -Name <String> [-NewName <String>] [-Description <String>] [-Properties <Hashtable>] [-PropertiesMethod <String>] [-DisableAlerting <Boolean>] [-ParentGroupName <String>] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]
Name-ParentGroupId
Set-LMServiceGroup -Name <String> [-NewName <String>] [-Description <String>] [-Properties <Hashtable>] [-PropertiesMethod <String>] [-DisableAlerting <Boolean>] [-ParentGroupId <Int32>] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]
Description
The Set-LMServiceGroup function modifies an existing Service group in LogicMonitor, allowing updates to its name, description, properties, and various other settings.
Examples
Example 1
Set-LMServiceGroup -Id 123 -NewName "Updated Group" -Description "New description"Updates the Service group with ID 123 with a new name and description.
Parameters
-Id
Specifies the ID of the Service group to modify.
Type: StringParameter Sets: Id-ParentGroupIdAliases:
Required: TruePosition: NamedDefault value: NoneAccept pipeline input: True (ByPropertyName)Accept wildcard characters: False
Type: StringParameter Sets: Id-ParentGroupNameAliases:
Required: TruePosition: NamedDefault value: NoneAccept pipeline input: True (ByPropertyName)Accept wildcard characters: False
-Name
Specifies the current name of the Service group.
Type: StringParameter Sets: Name-ParentGroupName, Name-ParentGroupIdAliases:
Required: TruePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-NewName
Specifies the new name for the Service group.
Type: StringParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-Description
Specifies the new description for the Service group.
Type: StringParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-Properties
Specifies a hashtable of custom properties for the Service group.
Type: HashtableParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-PropertiesMethod
Specifies how to handle existing properties. Valid values are “Add”, “Replace”, or “Refresh”. Default is “Replace”.
Type: StringParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: ReplaceAccept pipeline input: FalseAccept wildcard characters: False
-DisableAlerting
Specifies whether to disable alerting for the Service group.
Type: BooleanParameter Sets: (All)Aliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-ParentGroupId
Specifies the ID of the parent group.
Type: Int32Parameter Sets: Id-ParentGroupId, Name-ParentGroupIdAliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-ParentGroupName
Specifies the name of the parent group.
Type: StringParameter Sets: Id-ParentGroupName, Name-ParentGroupNameAliases:
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: SwitchParameterParameter Sets: (All)Aliases: wi
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: SwitchParameterParameter Sets: (All)Aliases: cf
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept wildcard characters: False
-ProgressAction
Fill ProgressAction Description
Type: ActionPreferenceParameter Sets: (All)Aliases: proga
Required: FalsePosition: NamedDefault value: NoneAccept pipeline input: FalseAccept 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
You can pipe objects containing Id properties to this function.
Outputs
Returns a LogicMonitor.DeviceGroup object containing the updated group information.
Notes
This function requires a valid LogicMonitor API authentication.