Skip to content

update_firewall_group

Rename a firewall group or replace its members (read-modify-write).

Side effects:

  • Replaces the group’s name and/or members in place. The members list is replaced wholesale, not merged, so pass the full desired set. The group’s group_type is preserved (it is read first and written back unchanged); group type cannot be changed after creation, only members.
  • Every rule referencing this group immediately sees the new members.
  • Mutates controller state. Use dry_run=True to preview the before/ after diff without applying.

Read first: call get_firewall_group_details to see the current members.

update_firewall_group(group_id="65f...", members=["10.50.0.0/24", "10.70.0.0/24"])
ParameterTypeRequiredDefaultDescription
group_idstringyesThe _id from list_firewall_groups.
namestringno""New display name. Empty (default) keeps the current name.
members`arraynull`nonull
controllerstringno”default”Name of the UniFi controller to target. Defaults to "default".
dry_runbooleannofalsePreview the before/after diff without applying it.