groups > setGroupMembers

Use the setGroupMembers command in the groups namespace to replace the players in an existing group with a new set.


Endpoint

POST


Request Parameters

This command requires a groupId to determine the target of the command. See the Control documentation for details.

See the table below for descriptions of parameters in the body.

Parameter Type Value
playerIds array An array of player ID strings corresponding to the new set of players for the group.

Response

Returns a groupInfo object, which currently only includes a group object. The groupInfo object may include additional information in the future.

In the event of a failure, returns a globalError.


Example

Request

In the example below, the original group is PID0, PID1, and PID2.

Response