< Back

Set-NotificationTriggerProperty

Sun Jan 19, 2020 5:44 pm

NAME Set-NotificationTriggerProperty



SYNOPSIS

Modifies the value of a PRTG Notification Trigger property.





SYNTAX

Set-NotificationTriggerProperty [-Property] {State | Latency | OnNotificationAction | OffNotificationAction |

EscalationNotificationAction | EscalationLatency | RepeatInterval | Channel | Period | UnitSize | Condition |

Threshold | UnitTime} [[-Value] <object>] -Trigger <NotificationTrigger> [-PassThru <SwitchParameter>]

[<CommonParameters>]



Set-NotificationTriggerProperty -Trigger <NotificationTrigger> [-Channel <object>] [-Condition {Above | Below |

Equals | NotEquals | Change}] [-EscalationLatency <int>] [-EscalationNotificationAction <NameOrObject`1>]

[-Latency <int>] [-OffNotificationAction <NameOrObject`1>] [-OnNotificationAction <NameOrObject`1>] [-PassThru

<SwitchParameter>] [-Period {Hour | Day | Week | Month}] [-RepeatInterval <int>] [-State {Down | Warning | Unusual

| DownPartial | Up | Unknown}] [-Threshold <double>] [-UnitSize {Bit | Kbit | Mbit | Gbit | Tbit | Byte | KByte |

MByte | GByte | TByte}] [-UnitTime {Second | Minute | Hour | Day}] [<CommonParameters>]



Set-NotificationTriggerProperty [-Property] {State | Latency | OnNotificationAction | OffNotificationAction |

EscalationNotificationAction | EscalationLatency | RepeatInterval | Channel | Period | UnitSize | Condition |

Threshold | UnitTime} [[-Value] <object>] -ObjectId <int> -SubId <int> [-PassThru <SwitchParameter>]

[<CommonParameters>]



Set-NotificationTriggerProperty -ObjectId <int> -SubId <int> [-Channel <object>] [-Condition {Above | Below |

Equals | NotEquals | Change}] [-EscalationLatency <int>] [-EscalationNotificationAction <NameOrObject`1>]

[-Latency <int>] [-OffNotificationAction <NameOrObject`1>] [-OnNotificationAction <NameOrObject`1>] [-PassThru

<SwitchParameter>] [-Period {Hour | Day | Week | Month}] [-RepeatInterval <int>] [-State {Down | Warning | Unusual

| DownPartial | Up | Unknown}] [-Threshold <double>] [-UnitSize {Bit | Kbit | Mbit | Gbit | Tbit | Byte | KByte |

MByte | GByte | TByte}] [-UnitTime {Second | Minute | Hour | Day}] [<CommonParameters>]





DESCRIPTION

The Set-NotificationTriggerProperty cmdlet modifies properties and settings of PRTG Notification Triggers.



When a value is specified, Set-NotificationTriggerProperty will attempt to parse the value into its expected type.

If the type cannot be parsed, an exception will be thrown indicating the type of the object specified and the type

of value that was expected. In the case of enums, Set-NotificationTriggerProperty will list all valid values of

the target type so that you may know how exactly to interface with the specified property. In the event you wish

to modify multiple properties in a single request, Set-NotificationTriggerProperty provides dynamically generated

parameters for each property supported by PrtgAPI.





PARAMETERS

-Trigger <NotificationTrigger>

Notification Trigger to set the properties of.



Required? true

Position? named

Default value

Accept pipeline input? true (ByValue)

Accept wildcard characters? false



-ObjectId <int>

ID of the notification trigger's parent object.



Required? true

Position? named

Default value 0

Accept pipeline input? false

Accept wildcard characters? false



-SubId <int>

ID of the trigger to set the properties of.



Required? true

Position? named

Default value 0

Accept pipeline input? false

Accept wildcard characters? false



-Property <TriggerProperty>

Property of the trigger to set.



Possible values: State, Latency, OnNotificationAction, OffNotificationAction, EscalationNotificationAction,

EscalationLatency, RepeatInterval, Channel, Period, UnitSize, Condition, Threshold, UnitTime



Required? true

Position? 0

Default value State

Accept pipeline input? false

Accept wildcard characters? false



-Value <object>

Value to set the property to.



Required? false

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-PassThru <SwitchParameter>

Specifies whether to return the original IObject that was passed to this cmdlet, allowing the object to be

further piped into additional cmdlets.



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-State <TriggerSensorState>

Possible values: Down, Warning, Unusual, DownPartial, Up, Unknown



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Latency <int>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-OnNotificationAction <NameOrObject`1>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-OffNotificationAction <NameOrObject`1>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-EscalationNotificationAction <NameOrObject`1>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-EscalationLatency <int>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-RepeatInterval <int>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Channel <object>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Period <TriggerPeriod>

Possible values: Hour, Day, Week, Month



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-UnitSize <DataUnit>

Possible values: Bit, Kbit, Mbit, Gbit, Tbit, Byte, KByte, MByte, GByte, TByte



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Condition <TriggerCondition>

Possible values: Above, Below, Equals, NotEquals, Change



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Threshold <double>



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-UnitTime <TimeUnit>

Possible values: Second, Minute, Hour, Day



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

PrtgAPI.NotificationTrigger

Notification Trigger to set the properties of.





OUTPUTS



---------- EXAMPLE 1 ----------



Get-Sensor -Id 1001 | Get-Trigger | Set-TriggerProperty OnNotificationAction $null



Remove the OnNotificationAction of all triggers defined on the object with ID 1001.



---------- EXAMPLE 2 ----------



Get-Device -Id 2001 | Get-Trigger -Type Threshold | Set-TriggerProperty -Latency 40 -Channel Primary



Modify the Latency and Channel properties of all Threshold Triggers on the device with ID 2001.



RELATED LINKS

Online version: https://github.com/lordmilko/PrtgAPI/wi ... s#modify-1

Add-NotificationTrigger

Get-NotificationTrigger

New-NotificationTriggerParameters