MambuPy.rest1to2.mambugroup

Classes

MambuGroup(*args, **kwargs)

MambuGroups(*args, **kwargs)

class MambuPy.rest1to2.mambugroup.MambuGroup(*args, **kwargs)[source]

Bases: MambuStruct, MambuGroup

__init__(*args, **kwargs)[source]

Tasks done here:

Just initializes the MambuStruct.

__module__ = 'MambuPy.rest1to2.mambugroup'
addMembers(newMembers=[], *args, **kwargs)[source]

Adds a list of members to the group

Parameters:

newMembers (list) – list with encoded keys of the members to add to group

preprocess()[source]
setActivities(*args, **kwargs)[source]

Adds the activities for this group to a ‘activities’ field.

Activities are MambuActivity objects.

Activities get sorted by activity timestamp.

Returns the number of requests done to Mambu.

setClients(*args, **kwargs)[source]

Adds the clients for this group to a ‘clients’ field.

The ‘groupMembers’ field of the group holds the encodedKeys of the member clients of the group. Since Mambu REST API accepts both ids or encodedKeys to retrieve entities, we use that here.

You may wish to get the full details of each client by passing a fullDetails=True argument here.

Returns the number of requests done to Mambu.

updatePatch(data, *args, **kwargs)[source]
class MambuPy.rest1to2.mambugroup.MambuGroups(*args, **kwargs)[source]

Bases: MambuStruct, MambuGroups

__init__(*args, **kwargs)[source]

By default, entid argument is empty. That makes perfect sense: you want several groups, not just one

__iter__()[source]
__module__ = 'MambuPy.rest1to2.mambugroup'
__repr__()[source]

Mambu object repr tells the class name and the usual ‘id’ for it.

If an iterable, it instead gives its length.