Using Azure AD to gain the orgid of a Teams Tag.

John Cade 6 Reputation points
2020-08-01T10:51:20.08+00:00

Hi,

I'm currently building a system of Flows/Power Automates in order to run behind a Form in order to send a number of Flow Adaptive Cards to a Channel, within this channel I want to use the Tags System built in and I've manged to find the following code:

    {  
      "type": "mention",  
      "text": "<at>John </at>",  
      "mentioned": {  
        "id": "8:orgid:{org-ID-of-the-user}",  
        "name": "John "  
      }  

And I wondered if anyone could help me get started with finding the org-ID-of-the-Team not the user.

For example I currently have a channel setup with a @Aman ullah setup as a group and I want a certain adaptive card to mention this tag instead of name every single person.

Thanks in advance.
John

Microsoft Teams Development
Microsoft Teams Development
Microsoft Teams: A Microsoft customizable chat-based workspace.Development: The process of researching, productizing, and refining new or existing technologies.
1,706 questions
Microsoft Teams
Microsoft Teams
A Microsoft customizable chat-based workspace.
5,359 questions
1 vote

2 answers

Sort by: Most helpful
  1. Wajeed-MSFT 226 Reputation points Microsoft Employee
    2020-08-04T13:32:32.95+00:00

    Currently, @mention for team, channel or group is not supported in Bot messages/cards. We are updating the card documentation to add note for this.

    No comments

  2. JimmyYang-MSFT 34,506 Reputation points Microsoft Employee
    2020-08-04T08:42:46.403+00:00

    Hi!
    According to your description, this issue is related to script development, which we do not support. We recommend you post it in this forum.
    https://powerusers.microsoft.com/t5/General-Power-Automate/bd-p/MPAForum

    In my experience, you can use the joinedTeams API to get all of the Teams that the current user belongs to. The response contains the group ID for each Team.
    https://learn.microsoft.com/en-us/graph/api/user-list-joinedteams?view=graph-rest-beta&tabs=http

    No comments