contacts_update_group
Rename an existing iCloud contact group and/or add or remove members without touching contact cards. Use it to change a group's name or membership; create or delete groups and contacts elsewhere.
Instructions
Rename one existing contact group and/or add or remove its members, without touching any contact card.
Use when: the owner asks to rename a group or change who is in it. Not for creating a group (use contacts_create_group), deleting one (use contacts_delete_group), or deleting a person (use contacts_delete_contact). Parameters:
uid from contacts_list_groups.
Omit name to keep it; a new name is 1-100 characters.
add_members are person uids from contacts_search_contacts, each checked to exist; uids already in the group are skipped.
remove_members uids not in the group are ignored.
Pass any combination of the three. Behavior:
Removing someone from a group never deletes their contact; other data on the group card is kept.
The write is conditional on the version last read, so a group changed elsewhere since is not overwritten.
Repeating the same call changes nothing.
A rename to a name another group already has (ignoring case and accents) is refused.
Not available when the server runs READ_ONLY. Returns: {updated: true, uid, name, members (new count)} plus added and removed (the uids that actually changed); {updated: false, note: "Nothing to change."} when nothing differs. Errors: "No group with uid"; "Not contacts in this address book: ..." for unknown add_members (nothing is written); "This contact changed since it was read": read the group again and retry.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| uid | Yes | Group uid from contacts_list_groups. | |
| name | No | New name; omit to keep. | |
| add_members | No | Contact uids (from contacts_search_contacts). | |
| remove_members | No | Contact uids (from contacts_search_contacts). |