Skip to content

Move-S1Agent

SYNOPSIS

Move agents that match the filter to a specified group.

SYNTAX

All (Default)

Move-S1Agent -Filter <String> -FilterValue <String[]> [<CommonParameters>]

GroupID

Move-S1Agent -GroupID <String[]> -Filter <String> -FilterValue <String[]> [<CommonParameters>]

DESCRIPTION

This function moves agents that match the specified filter to a group. The Group ID is required and there can only be one. The matched agents must be in the same site as the given group.

EXAMPLES

EXAMPLE 1

Move-S1Agent -GroupID "group123" -Filter "groupIds" -FilterValue @("group1", "group2")

Moves agents from the specified groups to the target group with ID "group123".

EXAMPLE 2

Move-S1Agent -GroupID "group123" -Filter "agentNamespace__contains" -FilterValue "exampleNamespace"

Moves agents matching the namespace filter to the target group with ID "group123".

EXAMPLE 3

Move-S1Agent -GroupID "group123" -Filter "uuids" -FilterValue @("uuid1", "uuid2")

Moves agents with the specified UUIDs to the target group with ID "group123".

PARAMETERS

-GroupID

The ID of the group to which the agents will be moved.

Type: String[]
Parameter Sets: GroupID
Aliases:

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

-Filter

The filter type to select agents. Valid values are "groupIds", "agentNamespace__contains", or "uuids".

Type: String
Parameter Sets: (All)
Aliases:

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

-FilterValue

The value(s) for the specified filter.

Type: String[]
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