SOLVED

Is it possible to get the external user's email in API Graph?

Copper Contributor

We are using Calls Record from api graph, but in the response it shows an external user, is it possible to get the email of this type of user?

 

Thank you very much in advance


https://graph.microsoft.com/v1.0/communications/callRecords/{id}?$expand=sessions($expand=segments)

AngelicaEnriquez88_0-1635792260705.png

 

1 Reply
best response confirmed by ChetanSharma-msft (Microsoft)
Solution

@AngelicaEnriquez88 

In teams, there's a difference between a guest user and an external user. A guest user is a user that someone has added to any team in your tenant and thus your azure ad tenant. An external user is a user already on teams or skype but not in your tenant, they are federated only and can only call and chat, cannot send files or join a team.
In order to have a user in your azure ad, that user must be added to a team or manually added as a guest in your azure ad. If you just chat or call an external federated user without adding them to your tenant, it's simply an federated chat/call with no relation whatsoever with your tenant.
Through graph API or any other means you won't be able to get very much information from those users that are externally federated, whereas you will be able to do basically full reporting on a guest users.
If you want to retrieve all the external users inside your tenant, all you should do is user the following API call: https://graph.microsoft.com/v1.0/users?$filter=userType eq ‘Guest’


Thanks, 

Prasad Das

-----------------------------------------------------------------------------------------------------

If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate. 

 

1 best response

Accepted Solutions
best response confirmed by ChetanSharma-msft (Microsoft)
Solution

@AngelicaEnriquez88 

In teams, there's a difference between a guest user and an external user. A guest user is a user that someone has added to any team in your tenant and thus your azure ad tenant. An external user is a user already on teams or skype but not in your tenant, they are federated only and can only call and chat, cannot send files or join a team.
In order to have a user in your azure ad, that user must be added to a team or manually added as a guest in your azure ad. If you just chat or call an external federated user without adding them to your tenant, it's simply an federated chat/call with no relation whatsoever with your tenant.
Through graph API or any other means you won't be able to get very much information from those users that are externally federated, whereas you will be able to do basically full reporting on a guest users.
If you want to retrieve all the external users inside your tenant, all you should do is user the following API call: https://graph.microsoft.com/v1.0/users?$filter=userType eq ‘Guest’


Thanks, 

Prasad Das

-----------------------------------------------------------------------------------------------------

If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate. 

 

View solution in original post