6.5 Get Group By Id

The getGroupById returns details of a group. Details include groupId, name, type, groupMembers. Any existing member of the group can retrieve details of the group, including the list of all the group members.

The function takes the following parameters :

  • sessionId : Unique SessionId which is received in the registration/login function response.

  • groupId : Group Id of the Group.

#include "BayunCore.h"

Bayun::ShGroupByIdResponse response = bayunCore->groupById("<sessionId>", "<groupId>");
if (response != nullptr) {
    std::string groupId  = response->getGroupId();
    std::string name = response->getName();
    Bayun::GroupType type = response->getType();
    std::vector<Bayun::ShGroupMember> groupMembers = response->getGroupMembers();
 }

Last updated

Was this helpful?