Skip to content

Update-IvantiTask

SYNOPSIS

Update a task in Ivanti ITSM.

SYNTAX

RecID (Default)

Update-IvantiTask -recID <String> -body <Hashtable> [<CommonParameters>]

taskNumber

Update-IvantiTask -taskNumber <Int32> -body <Hashtable> [<CommonParameters>]

DESCRIPTION

The `Update-Task` function allows you to update a task in Ivanti ITSM. You can specify the task using either the task number or the record ID. The function also accepts a hashtable containing the fields to be updated.

EXAMPLES

EXAMPLE 1

Update-Task -taskNumber 12345 -body @{ 'Status' = 'Completed' }

Updates the task with the task number 12345 and sets the status to 'Completed'.

EXAMPLE 2

Update-Task -recID 'abc123' -body @{ 'Priority' = 'High' }

Updates the task with the record ID 'abc123' and sets the priority to 'High'.

PARAMETERS

-taskNumber

The task number of the task to update. This parameter is mandatory when using the 'taskNumber' parameter set.

Type: Int32
Parameter Sets: taskNumber
Aliases: task

Required: True
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False

-recID

The record ID of the task to update. This parameter is mandatory when using the 'RecID' parameter set.

Type: String
Parameter Sets: RecID
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-body

A hashtable containing the fields to be updated. This parameter is mandatory.

Type: Hashtable
Parameter Sets: (All)
Aliases:

Required: True
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

OUTPUTS

NOTES

This function is useful for updating tasks in Ivanti ITSM.

https://help.ivanti.com/ht/help/en_US/ISM/2022/admin/Content/Configure/API/Update-a-Business-Object.htm