User-893002196 posted
Hi All,
I got error:
AADSTS700016: Application with identifier 'undefined' was not found in the directory 'xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx'. This can happen if the application has not been installed by the administrator of the tenant or consented to by any user in the tenant. You may have sent your authentication request to the wrong tenant.
My code:
c.SingleApiVersion("v1", "AMPortal");
c.IncludeXmlComments(string.Format(@"{0}\bin\AMPortal.xml",
System.AppDomain.CurrentDomain.BaseDirectory));
c.DescribeAllEnumsAsStrings();
c.OAuth2("oauth2")
.Description("OAuth2 Implicit Grant")
.Flow("implicit")
.AuthorizationUrl("https://login.microsoftonline.com/xxxxx-xxxx-xxxx-xxxx-xxxxxxx/oauth2/authorize")
.TokenUrl("https://login.microsoftonline.com/xxxxx-xxxx-xxxx-xxxx-xxxxxxx/oauth2/token")
.Scopes(scopes =>
{
scopes.Add("https://xxx.onmicrosoft.com/AMPortal/Read", "Read access to protected resources");
scopes.Add("https://xxx.onmicrosoft.com/AMPortal/Write", "Write access to protected resources");
});
c.OperationFilter<AssignOAuth2SecurityRequirements>();
May I know where I am going wrong?
Please advise.