Show a Planner Plan as a Tab inside Teams Channel is no more working using Graph API, any advice?

john john Pter 1,065 Reputation points
2024-06-07T06:57:07.46+00:00

I have this workflow which:-

  1. Create a new Team Channel
  2. Create a new Planner Plan
  3. Show the Planner Plan as a tab inside the Team Channel.

this was working well for around 6 months, but recently it stop working as expected.Here is my workflow which calls the Graph API (my question is not regarding power automate flow, but rather related to Graph API):-

johnjohnPter_0-1717716220211

johnjohnPter_1-1717716245341

johnjohnPter_2-1717716280957

here is the "Body of the request" for showing the plan as a tab inside channel action:-

{
    "displayName": "@{outputs('Compose_-_Friendly_Planner_Name')}",
    "******@odata.bind": "https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/com.microsoft.teamspace.tab.planner",
    "configuration": {
        "entityId": "@{body('Invoke_an_HTTP_request_-_Create_new_Channel')?['id']}",
        "contentUrl": "https://tasks.teams.microsoft.com/teamsui/{tid}/Home/PlannerFrame?page=7&auth_pvr=OrgId&auth_upn={userPrincipalName}&groupId={groupId}&planId=@{variables('PlannerID')}&channelId={channelId}&entityId={entityId}&tid={tid}&userObjectId={userObjectId}&subEntityId={subEntityId}&sessionId={sessionId}&theme={theme}&mkt={locale}&ringId={ringId}&PlannerRouteHint={tid}",
        "removeUrl": "https://tasks.teams.microsoft.com/teamsui/{tid}/Home/PlannerFrame?page=13&auth_pvr=OrgId&auth_upn={userPrincipalName}&groupId={groupId}&planId=@{variables('PlannerID')}&channelId={channelId}&entityId={entityId}&tid={tid}&userObjectId={userObjectId}&subEntityId={subEntityId}&sessionId={sessionId}&theme={theme}&mkt={locale}&ringId={ringId}&PlannerRouteHint={tid}",
        "websiteUrl": "https://tasks.office.com/{tid}/Home/PlanViews/@{variables('PlannerID')}?Type=PlanLink&Channel=TeamsTab"
    }
}

 

 

Currently when i click on the new channel tab i will not get the new planner tasks, i will rather get "My Tasks",as follow:-

johnjohnPter_3-1717716440813.png

 

 

previously i use to get the related Planner tasks as follow:-

johnjohnPter_4-1717716496198.png

 

 

any advice, why this is no loner working as it use to be?

 

Thanks

Microsoft 365 and Office | Development | Other
Microsoft Security | Microsoft Graph
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Noël Brand 5 Reputation points
    2024-12-04T07:56:51.7233333+00:00

    @Jeremy Barden try use the one @AsithwMSFT provided.
    The first solution in this thread didn't do it for me. But the one disregarding the entityID worked wonders. Use this and just replace the Domain and PlanID:

    {
        "displayName": "My tab 2",
        "******@odata.bind": "https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/com.microsoft.teamspace.tab.planner",
        "configuration": {
            "contentUrl": "https://tasks.office.com/[domain].onmicrosoft.com/Home/PlannerFrame?page=7&planId=[planId]"
        }
    }
    
    1 person found this answer helpful.

  2. AsithwMSFT 1,520 Reputation points Microsoft External Staff
    2024-06-08T06:07:41.64+00:00

    @john john Pter Do you see any graph API error response message or can you decode the access token with (https://jwt.ms)) to get more information?

    It could be that the Client Secret you registered in Azure AD has expired. if it is set to 6 months


  3. AsithwMSFT 1,520 Reputation points Microsoft External Staff
    2024-06-08T15:43:03.3433333+00:00

    Hi @john john Pter

    Here I am adding new answer instead of last one

    I created Teams Tab using the similar way you did via graph api and got the same Team's Tab view as you.

    After closely examining the request payload, I changed the format of the entityId value and achieved the view you mentioned. Could you try it ?"

    entity id format was like this

    "entityId": "tt.c_{channelId}_p_{planId}_h_{uniqueId}"

    here is sample request payload that I tried. (Note- this format is captured from Teams Planner app)

    {
      "displayName": "My tab 2",
      "******@odata.bind": "https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/com.microsoft.teamspace.tab.planner",
      "configuration": {
        "entityId": "tt.c_19:5c5b0ae547084496a4707c8bdb3db9c1@thread.tacv2_p_5XK80bGx1Uynb7gDB8Z7qMkBFEEx_h_1
    717853278545
    ",
        "contentUrl": "https://tasks.teams.microsoft.com/teamsui/{tid}/Home/PlannerFrame?page=7&auth_pvr=OrgId&auth_upn={userPrincipalName}&groupId={groupId}&planId=5XK80bGx1Uynb7gDB8Z7qMkBFEEx&channelId={channelId}&entityId={entityId}&tid={tid}&userObjectId={userObjectId}&subEntityId={subEntityId}&sessionId={sessionId}&theme={theme}&mkt={locale}&ringId={ringId}&PlannerRouteHint={tid}&tabVersion=20200228.1_s",
        "websiteUrl": "https://tasks.office.com/2fe35f47-6421-4209-a601-aad98974ad29/Home/PlanViews/5XK80bGx1Uynb7gDB8Z7qMkBFEEx?Type=PlanLink&Channel=TeamsTab"
      }
    }
    
    
    

    User's image

    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.