Skip to content

New-LMRecipientGroup

Terminal window
New-LMRecipientGroup [-Name] <string> [[-Description] <string>] [-Recipients] <array> [-WhatIf]
[-Confirm] [<CommonParameters>]

The New-LMRecipientGroup function creates a new LogicMonitor recipient group with the specified parameters.

Terminal window
$recipients = @(
New-LMRecipient -Type 'ADMIN' -Addr 'user@domain.com' -Method 'email'
New-LMRecipient -Type 'ADMIN' -Addr 'user@domain.com' -Method 'sms'
New-LMRecipient -Type 'ADMIN' -Addr 'user@domain.com' -Method 'voice'
New-LMRecipient -Type 'ADMIN' -Addr 'user@domain.com' -Method 'smsemail'
New-LMRecipient -Type 'ADMIN' -Addr 'user@domain.com' -Method '<name_of_existing_integration>'
New-LMRecipient -Type 'ARBITRARY' -Addr 'someone@other.com' -Method 'email'
New-LMRecipient -Type 'GROUP' -Addr 'Helpdesk'
)
New-LMRecipientGroup -Name "MyRecipientGroup" -Description "This is a test recipient group" -Recipients $recipients

This example creates a new LogicMonitor recipient group named “MyRecipientGroup” with a description and recipients built using the New-LMRecipient function.

Prompts you for confirmation before running the cmdlet.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases:
- cf
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

The description of the recipient group.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: 1
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

The name of the recipient group. This parameter is mandatory.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: 0
IsRequired: true
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

A object containing the recipients for the recipient group. The object must contain a “method”, “type” and “addr” key.

Type: System.Array
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: 2
IsRequired: true
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

Runs the command in a mode that only reports what would happen without performing the actions.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases:
- wi
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

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