创建多租户 OAuth 客户端应用程序

Creating a Mult-Tenant OAuth Client App

本质上,我想创建一个 Oauth 客户端作为应用程序,以便我可以从 Dynamics 为多个客户获取数据。有谁知道这是否可以在 AppSource 中完成,或者您知道其他方法吗?

我有一项服务将在与 Azure 不同的云中提供服务,因此我真的没有任何东西可以作为应用程序提交,我真的不希望每个客户都必须设置自己的应用程序为我的服务提供所需的 privileges/access,但看起来我可能不得不这样做。

听起来你会想要 register an app with Azure AD (the OAuth2.0 service/identity provider for work and school accounts), and create a multi-tenant app. Then you can configure this app in the Azure Portal to get permissions to the APIs the app wants tokens to call (in your case Dynamics or the Microsoft Graph)。

编写此应用程序后,您可以使用其中之一编写您的应用程序 Azure AD Auth Libraries. Here's some sample code for a .NET web API. You can find more code samples on Github and search active directory. Moreover, the Azure Active Directory Developer Landing Page 是寻找更多资源以完成所有这些工作的好地方。