sp-dev-docs icon indicating copy to clipboard operation
sp-dev-docs copied to clipboard

Additional property on context: User's Tenant Id

Open weshackett opened this issue 10 years ago • 4 comments

Can we get the Office 365 tenancy Id (the Guid that the Graph would recognise).

This is super useful in the following scenarios.

  • Telemetry
  • Extranet scenarios in B2B so you know where the user originates
  • Using the MS Graph once it comes

weshackett avatar Aug 27 '16 19:08 weshackett

In what scenarios are the users tenant id and sites tenant id (#98) different?

wictorwilen avatar Aug 29 '16 09:08 wictorwilen

If the user is an 'extranet' user is B2B then they must have come from another tenant. I'm not sure MS Graph makes this available like this though.

weshackett avatar Aug 30 '16 14:08 weshackett

So the problem here is that pulling some user info into the context object is expensive. If we happen to have it already on the server, then it is cheap, but if we have to contact AD to get the information (which this one falls under), then it will slow down the request on the server a fair chunk.

patmill avatar Oct 24 '17 16:10 patmill

Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: Issue List: Our approach to locked issues

msft-github-bot avatar Jan 30 '20 12:01 msft-github-bot