Hi Narshima, Welcome to MS Q&A
Yes, you can create an Azure Active Directory using Azure SDK. The Azure SDKs are collections of libraries built to make it easier to use Azure services from different languages. The SDKs are designed to simplify interactions between your application and Azure resources. To create an Azure Active Directory using Azure SDK, you can use the Microsoft Graph API, which is a RESTful web API that enables you to access Microsoft Cloud service resources. You can use the Microsoft Graph API to create, read, update, and delete different types of Azure Active Directory resources such as users, groups, and applications.
For example -
To create an Azure AD group using Azure SDK, you can use the az ad group create
command. The --display-name
and --mail-nickname
parameters are required. Here is an example command:
az ad
This will create a group with the display name "MyGroup" and mail nickname "MyGroup". You can add members to the group using the az ad group member add
command. Here is an example command:
az ad
Replace <object-id>
with the object ID of the user or service principal you want to add to the group.
References:
- Authenticate JavaScript apps to Azure services during local development using developer accounts - Create Microsoft Entra group for local development
- Authenticate JavaScript apps to Azure services during local development using service principals - Create a Microsoft Entra security group for local development
- Authenticate Python apps to Azure services during local development using developer accounts - Create Microsoft Entra security group for local development
kindly accept answer if it helps
Please let me know if you have any question
Thanks
Deepanshu