Forum Discussion

cdempsey-sonicules's avatar
cdempsey-sonicules
Copper Contributor
Nov 30, 2023
Solved

Best way to retrieve a list of all VE Communities via an API?

I am trying to retrieve the list of all VE Communities (Public and Private) in a network via an API.   Based on the documentation here About the Yammer REST API - Yammer | Microsoft Learn  I have ...
  • NicolasKheirallah's avatar
    NicolasKheirallah
    Dec 09, 2023
    You are correct! I was looking at an old script I had! So you've probably already solved this, but I'll post how to do it if anyone else get's stuck

    So what you need to do is query group and then filter out creationOption, as you can't filter out only Yammer in a single query due to creationOption not being visable 🙂

    This will return all groups and their creationOption:

    https://graph.microsoft.com/v1.0/groups?$filter=groupTypes/any(a:a eq 'unified')&$select=id,displayName,creationOptions,resourceProvisioningOptions&$top=999

Resources