Hi @Em, Alexandra , One possible reason for this issue is that the memberOf API may not be returning the role/group information because the user account you are using to authenticate does not have the necessary permissions to access this information. To retrieve the role/group information, the user account must have the "Directory.Read.All" or "Directory.ReadWrite.All" permission.
To resolve this issue, you can try the following steps:
- Check if the user account you are using to authenticate has the necessary permissions to access the role/group information. You can check this by going to the Azure portal, selecting the user account, and checking the "Directory role" or "Assigned roles" section to see if the user has the "Directory.Read.All" or "Directory.ReadWrite.All" permission.
- If the user account does not have the necessary permissions, you can grant the "Directory.Read.All" or "Directory.ReadWrite.All" permission to the user account by assigning the appropriate role to the user. You can do this by going to the Azure portal, selecting the user account, and assigning the "Directory Readers" or "Directory Writers" role to the user.
- Once the user account has the necessary permissions, you can try retrieving the role/group information again using the memberOf API in your Android mobile application.
If you are still having issues, you can try using the Microsoft Authentication Library (MSAL) for Android to authenticate the user and retrieve the role/group information. If this still doesn't work let me know and we can open a free support ticket for you.
Please let me know if you have any questions and I can help you further.
If this answer helps you please mark "Accept Answer" so other users can reference it.
Thank you,
James