Accessing Graph.microsoft.com on behalf of a customer tennant
-
First, if this isn't the right forum, my apologies, and please direct me to the correct one... I have read, and searched for a week now, and I just don't seem to get it. I have a Microsoft Partner Center Global Admin User; "SvcUser" Using the Partner Center API with this user, I can list all our customers, and get their tennantIds. Using a TennantId, I gan get the customers users and subscriptions, and all is well. The App registered in Azure have all the permissions set up... Now I need to get all domains of a specific tennant... The Partner Center API does not support this, so I turn to Microsoft Graph. The concept, as I understand it, is to use the "common" endpoint to log in with my "SvcUser" and get a Autherntication code. Then connect to the specific tennant endpoint, supplying the code from the previous step, to get an Authorization token. Once I have this "Authorization token", I should be home free... A.) Can anyone provide me with a clear example on how to implement the Authentication and Authorization calls (C# preferably :rolleyes: ) ? B.) secondary; straighten me out, if all of the above is completely rubbish ? Thanks! :)
-
First, if this isn't the right forum, my apologies, and please direct me to the correct one... I have read, and searched for a week now, and I just don't seem to get it. I have a Microsoft Partner Center Global Admin User; "SvcUser" Using the Partner Center API with this user, I can list all our customers, and get their tennantIds. Using a TennantId, I gan get the customers users and subscriptions, and all is well. The App registered in Azure have all the permissions set up... Now I need to get all domains of a specific tennant... The Partner Center API does not support this, so I turn to Microsoft Graph. The concept, as I understand it, is to use the "common" endpoint to log in with my "SvcUser" and get a Autherntication code. Then connect to the specific tennant endpoint, supplying the code from the previous step, to get an Authorization token. Once I have this "Authorization token", I should be home free... A.) Can anyone provide me with a clear example on how to implement the Authentication and Authorization calls (C# preferably :rolleyes: ) ? B.) secondary; straighten me out, if all of the above is completely rubbish ? Thanks! :)
We do not have a specific Microsoft Graph forum, neither a Partner Center one, so this one sounds good enough. :-) The thing is, as far as I remember, we needed to do a project similar to this one, and we realized that most of the auth was done using Azure AD. That step you are talking about is the steps for Azure AD. For the Partner Center, check the following links for reference to see how you authenticate, [Partner Center authentication | Microsoft Docs](https://docs.microsoft.com/en-us/partner-center/develop/partner-center-authentication). Once done with the authentication, you can use the same token and authenticate yourself against that token, see the headers for reference [Partner Center REST headers | Microsoft Docs](https://docs.microsoft.com/en-us/partner-center/develop/headers). The domains for the account can be checked, [List domains - Documentation - Microsoft Graph](https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/domain\_list) and as I briefed you a bit earlier, the tokens are mostly captured using the Azure AD and so did Microsoft do that read the complete documentation here, [Get auth tokens - Documentation - Microsoft Graph](https://developer.microsoft.com/en-us/graph/docs/concepts/auth\_overview). Most of the scenarios that revolve around the Partner Center are mentioned here, check if you can find your scenario here as well: [Scenarios | Microsoft Docs](https://docs.microsoft.com/en-us/partner-center/develop/scenarios)
The shit I complain about It's like there ain't a cloud in the sky and it's raining out - Eminem ~! Firewall !~
-
First, if this isn't the right forum, my apologies, and please direct me to the correct one... I have read, and searched for a week now, and I just don't seem to get it. I have a Microsoft Partner Center Global Admin User; "SvcUser" Using the Partner Center API with this user, I can list all our customers, and get their tennantIds. Using a TennantId, I gan get the customers users and subscriptions, and all is well. The App registered in Azure have all the permissions set up... Now I need to get all domains of a specific tennant... The Partner Center API does not support this, so I turn to Microsoft Graph. The concept, as I understand it, is to use the "common" endpoint to log in with my "SvcUser" and get a Autherntication code. Then connect to the specific tennant endpoint, supplying the code from the previous step, to get an Authorization token. Once I have this "Authorization token", I should be home free... A.) Can anyone provide me with a clear example on how to implement the Authentication and Authorization calls (C# preferably :rolleyes: ) ? B.) secondary; straighten me out, if all of the above is completely rubbish ? Thanks! :)