MS Teams Authentication Guide


Please note that the Marketplace MS Teams connection is not currently available as it is under maintenance.

 

Due to the strict nature of MS Teams for businesses, there are additional steps required to complete in order to connect MS Teams to 3rd party apps. If you have a dedicated IT provided then this maybe something that they will be able to help with. 

 

You will need to create an Azure Active Directory OAuth application and to obtain your credentials from it. To do this you will need to apply for permission using the Microsoft request form for protected methods, approval can take up to a week.

Protected methods include: 

  • Messages: Get Channel Message, List Channel Messages, List Updated Channel Messages. 
  • Webhooks: Get Team Chats, Get Channel Chats

 

Once you have created an active directory, you can create an application:

  • Navigate to Azure Active Directory > App registrations > New registration.
  • Enter application details including Name, Supported account types, and Redirect URI.
  • After registration, note down the Client ID and Tenant ID.

Here is a helpful link: https://learn.microsoft.com/en-us/entra/identity-platform/quickstart-register-app

Create a Client Secret:

  • Under the application overview, go to Certificates & secrets > Client secrets > New client secret.
  • Enter description and expiration duration.
  • Note the value under the newly created client secret.

 

Enable Permissions:

  • Set permissions for your application under API permissions.
  • Add permissions required for your authentication type (Delegated or Application).

 

To set permissions for your application, from the application overview:

  1. Under the Manage heading, select API permissions.
  2. Select Add a permission.
  3. Under the Microsoft APIs tab, select Microsoft Graph.
  4. Select Delegated permissions or Application permissions, depending on the authentication type you are using.
  5. Select the required permissions.
  6. Select Add permissions.

 

To set up permissions for all methods for application permissions, use the following permissions:

  • CallRecords.Read.All
  • ChannelMember.Read.All
  • ChannelMessage.Read.All
  • ChannelSettings.Read.All
  • Chat.Read.All
  • Directory.Read.All
  • GroupMember.Read.All
  • Presence.ReadWrite.All
  • TeamSettings.Read.All
  • Teamwork.Migrate.All
  • User.Read.All

To set up permissions for all methods for delegated permissions, use the following permissions:

  • ChannelMember.Read.All
  • ChannelMessage.Read.All
  • ChannelMessage.Send
  • ChannelSettings.Read.All
  • Chat.Read
  • GroupMember.Read.All
  • Presence.ReadWrite
  • TeamSettings.Read.All
  • User.Read.All

 

More info on permissions can be found here: https://learn.microsoft.com/en-us/graph/permissions-reference