Retrieve the Teams ID

You must know the Teams ID while configuring activities such as 'Send message to MS Teams channel'.

To retrieve the Teams ID for a particular team using Microsoft Teams, perform the following steps:
  1. Log into Microsoft Teams application.

  2. Click on the Teams icon in the left navigation menu.

  3. Right-click on the team name for which you want to find the Team ID.

  4. Select Get link to team.

    The URL link is displayed with Team ID next to the groupId parameter, as shown in the below example:

    https://teams.microsoft.com/l/team/19%3A1c3101a2a5264d248ff46d3193a1a05a%40thread.tacv2/conversations?groupId=5db8a0ea-6460-4ff3-9c45-a297a5f5d0ef&tenantId=123c8de3-bf07-4569-b282-b7512a1c9999

To retrieve the Teams ID using Microsoft Graph API in Graph Explorer, perform the following steps:
  1. Open Graph Explorer.

  2. Sign in with your user credentials, which are used for signing in to Microsoft Teams.

  3. Fill in the required details as mentioned below.
    HTTP Method : GET
    Version : v1.0
    URL : https://graph.microsoft.com/v1.0/groups?$filter=displayName eq '{teams-display-name}'&$select=id
  4. Click Run query.
    Figure 1. Graph Explorer
    Graph Explorer

Note: In case of a Forbidden error thrown by Graph API, find the missing permission from the error message. In this case, Team.ReadBasic.All permission is displayed.
Figure 2. Forbidden Error
Forbidden Error

To add the missing permission, perform the following steps:
  1. Navigate to Modify permissions (preview) tab.
    Figure 3. Modify permissions (preview)
    Modify permissions (preview)

  2. To provide the permission, click the Consent button next to the permission as you prefer.