external help file | Module Name | online version | schema |
---|---|---|---|
PSIGEL-help.xml |
PSIGEL |
2.0.0 |
Updates properties of a device.
Update-UMSDevice [-Computername] <String> [[-TCPPort] <Int32>] [[-ApiVersion] <Int32>]
[[-SecurityProtocol] <String[]>] [-WebSession] <Object> [-Id] <Int32> [[-Name] <String>] [[-Site] <String>]
[[-Department] <String>] [[-CostCenter] <String>] [[-LastIP] <String>] [[-Comment] <String>]
[[-AssetId] <String>] [[-InserviceDate] <String>] [[-SerialNumber] <String>] [[-DeviceAttributes] <Hashtable>] [-WhatIf] [-Confirm]
[<CommonParameters>]
Updates properties of a device via API.
Update property name of the device with ID 195 to 'NewName':
Update-UMSDevice -Computername 'igelrmserver' -WebSession $WebSession -Id 195 -Name 'NewName'
Message Id
------- --
Update successful. 195
Update property name to 'Dev[MacAddress]' for all devices which name starts with 'V':
$PSDefaultParameterValues = @{
'*-UMS*:Credential' = (Get-Credential)
'*-UMS*:Computername' = 'igelrmserver'
'*-UMS*:Confirm' = $false
}
$PSDefaultParameterValues += @{
'*-UMS*:WebSession' = New-UMSAPICookie
}
(Get-UMSDevice -Filter details).where{$_.Name -match '^V'} |
ForEach-Object {
$_ | Update-UMSDevice -Name ('Dev{0}' -f $_.Mac)
}
Message Id
------- --
Update successful. 58
Update successful. 195
Update the Value of the DeviceAttribute with the Identifier 'devattr1' on the device with ID 195 to 'NewValue' and remove the Value of the DeviceAttribute with the Identifier 'devattr2' from the device with ID 195:
Update-UMSDevice -Computername 'igelrmserver' -WebSession $WebSession -Id 195 -DeviceAttributes @{'devattr1' = 'NewValue'; 'devattr2' = ''}
Message Id
------- --
Update successful. 195
API Version to use
Type: Int32
Parameter Sets: (All)
Aliases:
Accepted values: 3
Required: False
Position: Benannt
Default value: 3
Accept pipeline input: False
Accept wildcard characters: False
Device property asset ID
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Device property comment
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Computername of the UMS Server
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Prompts you for confirmation before running the cmdlet.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Device property cost center
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Device property department
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
ID of the device
Type: Int32
Parameter Sets: (All)
Aliases:
Required: True
Position: Benannt
Default value: None
Accept pipeline input: True (ByPropertyName, ByValue)
Accept wildcard characters: False
Device property inservice date
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Device property last known IP address
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Device property name
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Set SSL/TLS protocol
Type: String[]
Parameter Sets: (All)
Aliases:
Accepted values: Tls12, Tls11, Tls, Ssl3
Required: False
Position: Benannt
Default value: Tls12
Accept pipeline input: False
Accept wildcard characters: False
Device property serial number
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Device property site
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Custom Device Attributes
Type: Hashtable
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
TCP Port API
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: Benannt
Default value: 8443
Accept pipeline input: False
Accept wildcard characters: False
Websession Cookie
Type: Object
Parameter Sets: (All)
Aliases:
Required: True
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi
Required: False
Position: Benannt
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.