How to retrieve Container ID from sharePoint through Microsoft Graph API

Nikita Debroux 5 Points de réputation
2025-04-24T14:08:44.6666667+00:00

Hello,

I am trying to access the members of a sharePoint group through Microsoft Graph API. To do this, I am suppose to use the following beta route: https://learn.microsoft.com/en-us/graph/api/sharepointgroup-get?view=graph-rest-beta&tabs=http

This route requires to know the fileStorageContainerId associated to the sharePoint group. My issue is to retrieve this id.

I have tried to use this route: https://learn.microsoft.com/en-us/graph/api/filestorage-list-containers?view=graph-rest-1.0&tabs=http that is supposed to list all containers. But, again, this route requires to filter based on the containerTypeId. I have then found no way to retrieve such containerTypeId.

In this documentation (https://learn.microsoft.com/en-us/sharepoint/dev/embedded/getting-started/containertypes#standard-container-types-non-trial), it explain how to create a container type with a specific type id but that's not my goal. I just want to be able to retrieve the member of my sharePoint groups through the API.

I also have seen this command from SharePoint Online Shell that could maybe be useful: https://learn.microsoft.com/en-us/powershell/module/sharepoint-online/get-spocontainer?view=sharepoint-ps. But unfortunately I am working an a Mac.

At this point, I have absolutely no idea on how I can proceed further. It seems impossible to retrieve this container id. Do you have any way to help me ? I find it astonishing (in a really bad way) that such easy task as the one I describe (retrieving member of a sharePoint group) is so difficult to put in place. The documentation of Microsoft needs a serious rework.

Thanks for your answer,

Nikita de Broux

Développement SharePoint
Développement SharePoint
SharePoint: Groupe de produits et technologies Microsoft utilisés pour le partage et la gestion du contenu, des connaissances et des applications.Développement: Processus de recherche, de productisation et d’affinement de technologies nouvelles ou existantes.
12 questions
0 commentaires Aucun commentaire
{count} votes

Votre réponse

Les réponses peuvent être marquées comme Réponses acceptées par l’auteur de la question, ce qui permet aux utilisateurs de connaître la réponse qui a résolu le problème de l’auteur.