Skip to content

Set-LMSDT

Syntax

OneTime (Default)

Terminal window
Set-LMSDT -Id <String> [-Comment <String>] [-StartDate <DateTime>] [-EndDate <DateTime>]
[-ProgressAction <ActionPreference>] [<CommonParameters>]

Recurring

Terminal window
Set-LMSDT -Id <String> [-Comment <String>] [-StartHour <Int32>] [-StartMinute <Int32>] [-EndHour <Int32>]
[-EndMinute <Int32>] [-WeekDay <String>] [-WeekOfMonth <String>] [-DayOfMonth <Int32>]
[-ProgressAction <ActionPreference>] [<CommonParameters>]

Description

The Set-LMSDT function modifies an existing SDT entry in LogicMonitor, allowing updates to both one-time and recurring schedules.

Examples

Example 1

Terminal window
Set-LMSDT -Id 123 -StartDate "2024-01-01 00:00" -EndDate "2024-01-02 00:00" -Comment "Extended maintenance"
Updates a one-time SDT entry with new dates and comment.

Parameters

-Id

Specifies the ID of the SDT entry to modify.

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

-Comment

Specifies a comment for the SDT entry.

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

-StartDate

Specifies the start date and time for one-time SDT.

Type: DateTime
Parameter Sets: OneTime
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-EndDate

Specifies the end date and time for one-time SDT.

Type: DateTime
Parameter Sets: OneTime
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-StartHour

Specifies the start hour (0-23) for recurring SDT.

Type: Int32
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-StartMinute

Specifies the start minute (0-59) for recurring SDT.

Type: Int32
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-EndHour

Specifies the end hour (0-23) for recurring SDT.

Type: Int32
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-EndMinute

Specifies the end minute (0-59) for recurring SDT.

Type: Int32
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-WeekDay

Specifies the day of the week for recurring SDT.

Type: String
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-WeekOfMonth

Specifies which week of the month for recurring SDT. Valid values: “First”, “Second”, “Third”, “Fourth”, “Last”.

Type: String
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-DayOfMonth

Specifies the day of the month (1-31) for recurring SDT.

Type: Int32
Parameter Sets: Recurring
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ProgressAction

Fill ProgressAction Description

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga
Required: False
Position: Named
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

Returns the response from the API containing the updated SDT configuration.

Notes

This function requires a valid LogicMonitor API authentication.