Skip to main content
Rename a group, change its key or set who is in it, and return it with what changed in attribution_changes. Pass at least one of name, key or attributions. attributions is the group’s whole membership, not an addition to it: whoever the list leaves out is removed from the group. Read the group with get_group first and send back every member to keep. Omitting the argument leaves the membership untouched, so a rename alone is safe; passing an empty list empties the group. Re-sending what is stored changes nothing, so the same call can be sent twice. The call is refused when it would:
  • remove a member without the delete permission on groups;
  • change the membership of an archived group;
  • add a user who is archived or unknown;
  • cover one user over overlapping months;
  • set a key another group of the dimension already uses, archived groups included.
attribution_changes returns only what actually changed, each row saying whether it was created, moved or removed. A membership change recalculates, in the background, the statements of the users it affects on the live environment, wherever the group is attributed to a plan. A rename shows on every statement and in every report that breaks down by the group’s dimension. Every write to the live environment is recorded in the audit trail as the Qobra MCP agent; writes to a sandbox are not audited.

Parameters

Body

string
required
Id from list_groups or create_group.
string
New display name.
string
New key, in the format and with the uniqueness of create_group’s key.
object[]
The complete membership: every user to keep, each with the months they belong for. Anyone left out is removed; an empty list empties the group. One row per continuous stretch, no month covered twice for a user.

Response

Body

object
The group as it now stands.
object[]
Every membership the call changed, as created, moved or removed. Empty when it only renamed the group or the membership already matched.