How to get list of details of ADD user by using of Azure Mgmt SDK fluent

Anirban Goswami 256 Reputation points
2020-08-06T18:09:57.267+00:00

Hi All,

I am using https://www.nuget.org/packages/Microsoft.Azure.Management.Fluent for getting resources in Azure with programmatically(C# .NET-Core Web app) and tried to get resources information by providing service principals as below...

     string subscriptionId = "xxx";
            string clientId = "xxx";
            string tenantId = "xxx";
            string clientSecret = "xxx";

            AzureCredentials cred = new AzureCredentialsFactory()
                .FromServicePrincipal(
                clientId,
                clientSecret,
                tenantId,
                AzureEnvironment.AzureGlobalCloud
                );

            var azure = Azure.Configure()
                             .WithLogLevel(HttpLoggingDelegatingHandler.Level.Basic)
                             .Authenticate(cred)
                             .WithSubscription(subscriptionId);
//get total count of ADD user
var identity = azure.AccessManagement.ActiveDirectoryUsers.List().ToArray().Length.ToString();

Any sample code(C#.NET-Core Web app) to find out list of details of ADD user by using of Azure Mgmt SDK fluent
Pls, advice on above.

Thanks

Microsoft Entra External ID
Microsoft Entra External ID
A modern identity solution for securing access to customer, citizen and partner-facing apps and services. It is the converged platform of Azure AD External Identities B2B and B2C. Replaces Azure Active Directory External Identities.
2,851 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
21,439 questions
0 comments No comments
{count} votes

Accepted answer
  1. Anirban Goswami 256 Reputation points
    2020-08-07T14:56:41.127+00:00

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.