Is there a way to return contacts in GET /groups/{id}/transitiveMembers reponse?

Thanos Terzis 20 Reputation points
2023-04-21T11:38:49.0033333+00:00

Let 's assume that we have added some users through Contacts using M365 admin center. We decide to add these contacts in our distribution list through M365 admin center. Is there a way for these contacts to be returned using /groups/{id}/transitiveMembers api call?

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
12,455 questions
0 comments No comments
{count} votes

Accepted answer
  1. TH-4749-MSFT 3,305 Reputation points
    2023-04-21T14:26:14.14+00:00

    Hi Thanos Terzis, Thanks for reaching out. The /groups/{id}/transitiveMembers api call does return mail contacts. If you would like the api call to return just the mail contacts then you use OData cast in the api call like below: https://graph.microsoft.com/beta/groups/(Group-Id)/transitiveMembers/microsoft.graph.orgContact Thanks.

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.