Edit

Share via


Set-CsTeamsRemoteLogCollectionDevice

This cmdlet allows you to edit the properties of an existing TeamsRemoteLogCollectionDevice instance.

Syntax

Default (Default)

Set-CsTeamsRemoteLogCollectionDevice
    [-Identity <Guid>]
    [-UserId <String>]
    [-DeviceId <String>]
    [-ExpireAfter <String>]
    [-WhatIf]
    [-Confirm]
    [<CommonParameters>]

Description

This cmdlet allows you to edit a TeamsRemoteLogCollectionDevice instance.

Remote log collection is a feature in Microsoft Teams that allows IT administrators to remotely trigger the collection of diagnostic logs from user devices through the Teams Admin Center (TAC). Instead of relying on manual user intervention, admins can initiate log collection for troubleshooting directly from the TAC portal.

TeamsRemoteLogCollectionConfiguration is updated with a list of devices when an administrator wants to initiate a request for remote log collection for a user's device. Each device has a unique GUID identity, userId, deviceId and expiry date.

Examples

Example

In this example, the expiry date parameter is changed and set.

PS C:\> New-CsTeamsRemoteLogCollectionDevice -ExpireAfter "06/07/2025 15:30:45"

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:cf

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DeviceId

Applicable: Microsoft Teams

Indicates the deviceId of the device for which an admin is requesting logs for. This deviceId must be a valid GUID.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ExpireAfter

Applicable: Microsoft Teams

Indicates the expiry date after which the remote log collection request will expire. This expire after date should be set to now() + 3 days. This expiry date should be in ISO 8601 UTC format.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Identity

Applicable: Microsoft Teams

Policy instance name.

Parameter properties

Type:Guid
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:1
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UserId

Applicable: Microsoft Teams

Indicates the userId of the user for which an admin is requesting logs for. This userId must be a valid GUID.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:wi

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

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.