An API that connects multiple Microsoft services, enabling data access and automation across platforms
Hi @d6
Once the global administrator of the target tenant approves your multi-tenant application, it will be added as an enterprise application to the target tenant. At this time, you will be able to request tokens to access the contacts of users in the target tenant.
Please note that when requesting tokens, you need to change the tenant ID to the target tenant’s ID.
POST /{id of the target tenant}/oauth2/v2.0/token HTTP/1.1 //Line breaks for clarity
Host: login.microsoftonline.com:443
Content-Type: application/x-www-form-urlencoded
client_id=00001111-aaaa-2222-bbbb-3333cccc4444
&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default
&client_secret=qWgdYAmab0YSkuL1qKv5bPX
&grant_type=client_credentials
Additionally, you need to ensure that the users in the target tenant have MS 365 licenses.
Hope this helps.
If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.