%3CLINGO-SUB%20id%3D%22lingo-sub-2112199%22%20slang%3D%22en-US%22%3EAzure%20Active%20Directory%20IDs%20now%20in%20Yammer%20Data%20Export%20API%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2112199%22%20slang%3D%22en-US%22%3E%3CP%3EWe%E2%80%99re%20happy%20to%20announce%20an%20update%20to%20the%20Yammer%20Data%20Export%20API!%20Yammer%20Data%20Exports%20now%20include%20new%20columns%20that%20map%20Azure%20Active%20Directory%20IDs%20for%20Users%20and%20Groups%20with%20their%20corresponding%20Yammer%20Users%20and%20Groups%20IDs.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20new%20columns%20%E2%80%9COffice%20User%20ID%E2%80%9D%20and%20%E2%80%9COffice%20Group%20ID%E2%80%9D%20are%20added%20to%20Users.csv%20and%20Groups.csv%20files.%20This%20update%20aims%20to%20make%20it%20easy%20for%20our%20customers%20and%20partners%20to%20use%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Foverview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EMicrosoft%20Graph%20API%3C%2FA%3E%20and%20correlate%20Azure%20Active%20Directory%26nbsp%3Busers%20and%20groups%20IDs%20with%20their%20Yammer%20IDs%20for%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fyammer%2Fconfigure-your-yammer-network%2Foverview-native-mode%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Enetworks%20in%20Native%20Mode%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20this%20blog%20we%E2%80%99re%20sharing%20steps%20on%20how%20to%20list%20Azure%20Active%20Directory%20Group%20Members%20through%20Microsoft%20Graph%20and%20easily%20correlate%20them%20with%20Yammer%20Users.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EFirst%2C%26nbsp%3Bget%20Azure%20Active%20Directory%20User%20and%20Group%20IDs%20with%20the%20Yammer%20Data%20Export%20API.%3C%2FSTRONG%3E%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3EUse%20the%20Yammer%20Data%20Export%20API%20to%20incrementally%20export%20content%20from%20Yammer.%20%3CA%20href%3D%22https%3A%2F%2Fdeveloper.yammer.com%2Fdocs%2Fdata-export-api%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3Ehttps%3A%2F%2Fdeveloper.yammer.com%2Fdocs%2Fdata-export-api%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FLI%3E%0A%3CLI%3EIn%20the%20export%2C%20the%20Users.csv%20file%20now%20has%20a%20new%20field%20%E2%80%9C%3CEM%3EOffice_user_id%3C%2FEM%3E%E2%80%9D%20that%20contains%20the%20Azure%20Active%20Directory%20User%20ID%20which%20is%20mapped%20to%20its%20corresponding%20Yammer%20User%20ID.%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Users.png%22%20style%3D%22width%3A%20700px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F251679iD058B477CDCF1A0B%2Fimage-dimensions%2F700x131%3Fv%3D1.0%22%20width%3D%22700%22%20height%3D%22131%22%20role%3D%22button%22%20title%3D%22Users.png%22%20alt%3D%22Users.png%22%20%2F%3E%3C%2FSPAN%3E%3CP%3E%E2%80%83%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3EAlso%2C%20the%20Groups.csv%20file%20now%20has%20a%20new%20column%20%E2%80%9C%3CEM%3EOffice_group_id%3C%2FEM%3E%E2%80%9D%20that%20contains%20the%20Azure%20Active%20Directory%20Group%20ID%20which%20mapped%20its%20Yammer%20Group%20ID.%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-left%22%20image-alt%3D%22Groups%20CSV.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F251688i957AEAD281962505%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22Groups%20CSV.png%22%20alt%3D%22Groups%20CSV.png%22%20%2F%3E%3C%2FSPAN%3E%3CP%3E%E2%80%83%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3EUse%20the%20Office_user_id%20and%20Office_group_id%20fields%20to%20correlate%20Azure%20Active%20Directory%20Users%20and%20Groups%20with%20their%20corresponding%20Yammer%20Users%20and%20Group%20IDs.%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3E%3CSTRONG%3ENext%2C%20use%20the%20List%20Members%20API%20to%20get%20a%20group's%20direct%20members.%3C%2FSTRONG%3E%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3ECreate%20or%20update%20your%20Azure%20Active%20Directory%20Application.%20See%20this%20quick%20start%20guide%20for%20more%20information%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Factive-directory%2Fdevelop%2Fquickstart-register-app%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Factive-directory%2Fdevelop%2Fquickstart-register-app%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FLI%3E%0A%3CLI%3EEnable%20the%20permissions%20%3CEM%3E%3CSTRONG%3EGroup.Read.All%3C%2FSTRONG%3E%3C%2FEM%3E%20in%20the%20Azure%20Active%20Directory%20App%20Registrations%20section.%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22API%20Permissions.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F251687iECA325276EA76411%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22API%20Permissions.png%22%20alt%3D%22API%20Permissions.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FLI%3E%0A%3CLI%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3EFollow%20the%20Microsoft%20Graph%20guidelines%20to%20support%20authentication%20in%20your%20application%2Fservice.%20For%20more%20info%2C%20please%20see%20%3C%2FSPAN%3E%3CA%20style%3D%22font-family%3A%20inherit%3B%20background-color%3A%20%23ffffff%3B%22%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth%2F%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FLI%3E%0A%3CLI%3EGet%20a%20List%20of%20Members%20in%20a%20Group%20using%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fgroup-list-members%3Fview%3Dgraph-rest-1.0%26amp%3Btabs%3Dhttp%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EMicrosoft%20Graph%20List%20Members%20API%3C%2FA%3E%26nbsp%3B%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-left%22%20image-alt%3D%22Screen%20Shot%202021-02-02%20at%2011.24.28%20PM.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F251681iB796EB4A3C9B98E9%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22Screen%20Shot%202021-02-02%20at%2011.24.28%20PM.png%22%20alt%3D%22Screen%20Shot%202021-02-02%20at%2011.24.28%20PM.png%22%20%2F%3E%3C%2FSPAN%3E%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Postman.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F251683iAAD6C1440E55F20D%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20role%3D%22button%22%20title%3D%22Postman.png%22%20alt%3D%22Postman.png%22%20%2F%3E%3C%2FSPAN%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20response%20displays%20the%20list%20of%20Group%20members%20with%20many%20attributes%20such%20as%20the%20user%E2%80%99s%20%E2%80%9Cid%E2%80%9D%2C%20%E2%80%9CuserPrincipalName%E2%80%9D%2C%20%E2%80%9CdisplayName%E2%80%9D%2C%20etc.%3C%2FP%3E%0A%3CP%3EMake%20a%20note%20of%20the%20%E2%80%9Cid%E2%80%9D%20value%20%E2%80%93%20this%20value%20is%20now%20mapped%20in%20the%20Users.csv%20and%20Groups.csv%20files%20from%20the%20Yammer%20Data%20Export%20API.%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FP%3E%0A%3CP%3EIf%20there%20are%20more%20than%20100%20members%2C%20then%20Microsoft%20Graph%20returns%20a%20%40odata.nextLink%20property%20in%20the%20response%20that%20contains%20a%20URL%20to%20the%20next%20page%20of%20results.%20Learn%20more%20about%20the%20List%20Members%20API%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fgroup-list-members%3Fview%3Dgraph-rest-1.0%26amp%3Btabs%3Dhttp%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehere%3C%2FA%3E.%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3E%3CSTRONG%3EAnd%20that's%20it!%3C%2FSTRONG%3E%26nbsp%3BNow%20you%20can%20easily%20correlate%20Azure%20Active%20Directory%20User%20IDs%20from%20the%20Microsoft%20Graph%20API%20with%20their%20corresponding%20Yammer%20User%20and%20Group%20IDs%20from%20the%20Yammer%20Data%20Export%20API.%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EResources%3A%3C%2FSTRONG%3E%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3EMicrosoft%20Graph%20Explorer%3A%20%3CA%20href%3D%22https%3A%2F%2Fdeveloper.microsoft.com%2Fen-us%2Fgraph%2Fgraph-explorer%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdeveloper.microsoft.com%2Fen-us%2Fgraph%2Fgraph-explorer%3C%2FA%3E%3C%2FLI%3E%0A%3CLI%3EMicrosoft%20Graph%20API%3A%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Foverview%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Foverview%3C%2FA%3E%3C%2FLI%3E%0A%3CLI%3EList%20Members%20API%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fgroup-list-members%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fgroup-list-members%3C%2FA%3E%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3EYammer%20Native%20Mode%3A%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fyammer%2Fconfigure-your-yammer-network%2Foverview-native-mode%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fyammer%2Fconfigure-your-yammer-network%2Foverview-native-mode%3C%2FA%3E%3C%2FLI%3E%0A%3CLI%3EYammer%20Data%20Export%20API%3A%20%3CA%20href%3D%22https%3A%2F%2Fdeveloper.yammer.com%2Fdocs%2Fdata-export-api%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3Ehttps%3A%2F%2Fdeveloper.yammer.com%2Fdocs%2Fdata-export-api%3C%2FA%3E%3C%2FLI%3E%0A%3C%2FOL%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-2112199%22%20slang%3D%22en-US%22%3E%3CP%3EYammer%20Data%20Exports%20now%20include%20a%20column%20that%20maps%20the%20Azure%20Active%20Directory%20IDs%20for%20Users%20and%20Groups%20with%20their%20corresponding%20Yammer%20Users%20and%20Groups%20IDs.%3C%2FP%3E%3C%2FLINGO-TEASER%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2112199%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAzure%20Active%20Directory%20IDs%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EGroups%20and%20Users%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EYammer%20Data%20Export%20API%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Microsoft

We’re happy to announce an update to the Yammer Data Export API! Yammer Data Exports now include new columns that map Azure Active Directory IDs for Users and Groups with their corresponding Yammer Users and Groups IDs.

 

The new columns “Office User ID” and “Office Group ID” are added to Users.csv and Groups.csv files. This update aims to make it easy for our customers and partners to use the Microsoft Graph API and correlate Azure Active Directory users and groups IDs with their Yammer IDs for networks in Native Mode.

 

In this blog we’re sharing steps on how to list Azure Active Directory Group Members through Microsoft Graph and easily correlate them with Yammer Users.

 

First, get Azure Active Directory User and Group IDs with the Yammer Data Export API.

  1. Use the Yammer Data Export API to incrementally export content from Yammer. https://developer.yammer.com/docs/data-export-api

  2. In the export, the Users.csv file now has a new field “Office_user_id” that contains the Azure Active Directory User ID which is mapped to its corresponding Yammer User ID.
    Users.png

  3. Also, the Groups.csv file now has a new column “Office_group_id” that contains the Azure Active Directory Group ID which mapped its Yammer Group ID.
    Groups CSV.png

  4. Use the Office_user_id and Office_group_id fields to correlate Azure Active Directory Users and Groups with their corresponding Yammer Users and Group IDs.

Next, use the List Members API to get a group's direct members.

  1. Create or update your Azure Active Directory Application. See this quick start guide for more information https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app

  2. Enable the permissions Group.Read.All in the Azure Active Directory App Registrations section.
    API Permissions.png
  3. Follow the Microsoft Graph guidelines to support authentication in your application/service. For more info, please see https://docs.microsoft.com/en-us/graph/auth/

  4. Get a List of Members in a Group using the Microsoft Graph List Members API 
    Screen Shot 2021-02-02 at 11.24.28 PM.png
    Postman.png

     

    The response displays the list of Group members with many attributes such as the user’s “id”, “userPrincipalName”, “displayName”, etc.

    Make a note of the “id” value – this value is now mapped in the Users.csv and Groups.csv files from the Yammer Data Export API.

    If there are more than 100 members, then Microsoft Graph returns a @odata.nextLink property in the response that contains a URL to the next page of results. Learn more about the List Members API here

And that's it! Now you can easily correlate Azure Active Directory User IDs from the Microsoft Graph API with their corresponding Yammer User and Group IDs from the Yammer Data Export API.

Resources:

  1. Microsoft Graph Explorer: https://developer.microsoft.com/en-us/graph/graph-explorer
  2. Microsoft Graph API: https://docs.microsoft.com/en-us/graph/overview
  3. List Members API: https://docs.microsoft.com/en-us/graph/api/group-list-members 
  4. Yammer Native Mode: https://docs.microsoft.com/en-us/yammer/configure-your-yammer-network/overview-native-mode
  5. Yammer Data Export API: https://developer.yammer.com/docs/data-export-api