Yammer API - Can we get list of groups from yammer API for a current user?

为君一笑 提交于 2019-12-06 10:15:42

We can get list of groups using following REST API:

https://www.yammer.com/api/v1/groups.json?mine=1

This is the documented call to get the groups for the current user: https://www.yammer.com/api/v1/users/current.json?include_group_memberships=true.

you can use bellow code. if you want all the groups of your network then remove "?mine=1" from url.

yam.platform.request({
                // yam.request({
                url: "groups.json?mine=1",
                method: "GET",
                data: {},
                success: function (group) {
                    myGroups = group;
                    getCurrentGroups();

                },

                error: function (group) {
                    console.error("There was an error with the request.");
                }
            });
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!