Photo by Dimitri Karastelev on Unsplash
How to setup Microsoft Azure account for using MSTeams: An Easy Guide( step-by-step)
Microsoft 365 offers a sandbox account for free which includes services like MS Teams, Microsoft Graph, Microsoft Identity platform and more. In this article, we will learn to set up a Microsoft account for MS Teams with trouble-free steps so you don't have to jump from document to document;
Let's go!!
Prerequisites
You need to have a Microsoft developer’s account and log in. To create one from scratch, navigate to this link and click on 'Join now'.
App registration in Azure
Navigate to ‘Azure Active Directory’ in the Microsoft Azure portal.
In the overview page, click on ‘Add’ with the plus icon then click on ‘App registration’.
Click on ‘App Registration’.
Another method; You can also search ‘App registrations’ and then click on ‘New Registration’. The following page should open;
Fill in the following details and click on the ‘Register’ button.
Name -> Name of your application
Supported Account Types -> Accounts in any organizational directory (Multitenant) or Single Tenant based on your requirement.
Redirect URI (optional) -> URL where the user will be redirected after login
After the app is registered, you will be redirected to your app’s dashboard.
Generating client-secret
In the overview section of the registered app, click on ‘Add a certificate or secret’ in the ‘Essentials’ section.
Click on ‘New client secret’. Then add the required details.
Finally, click on the 'Add' button.
Copy the Value and Secret ID. Make sure to save the ‘Value’ of the generated secret, since it is only available to copy immediately after generating the Client secret.
Now we should have 1 secret added in the ‘Client credentials’ property of app overview.
Setting up API permissions for Graph API
Navigate to your registered app.
Then click on ‘API permissions’ on the left bar or search in the search bar.
Next, click on ‘Grant admin consent for MSFT’ and finally click on Microsoft graph API.
Add the permissions as mentioned below and save.
It should be in total of 20 permissions.
Make sure to check the Type (Delegated or Application) when adding permission.
User management
Add new user
Click on ‘Users’ in services or search in the Microsoft Azure dashboard.
Then click on ‘New User’ and then click on ‘Create new user’.
Next, add the following details and click on ‘Review + create’.
Assigning a license to a user
When we assign a licensing plan (for example, Microsoft 365 Enterprise E3 or Microsoft 365 Business Premium) to the user, a team's license is automatically assigned, and the user is enabled for MS Teams.
You can disable or enable Teams for a user by removing or assigning a license at any time.
Search the user and click on ‘Edit properties'.
Go to the ‘Usage location’ select ‘United States’ and click on the ‘save’ button.
Click on ‘Licenses’ on the left panel and click on ‘Assignments’.
Select the following checkbox and click on the ‘save’ button.
Assigning groups (aka teams) to user
Click on ‘Users’ and open the user to add ‘Groups’.
Click on ‘Groups’ and click on ‘Add memberships’.
Check the teams/ groups and click on ‘Select’.
To verify, sign in to the selected user and check teams.
You're all set to use MS Teams in your application. 🎉
Links you may find useful:
https://developer.microsoft.com/en-us/microsoft-365/dev-program
https://learn.microsoft.com/en-us/graph/api/resources/teams-api-overview?view=graph-rest-1.0