Skip to content

Channel tab deeplink subEntityId not passed when clicked from within the target channel (desktop & web; works on mobile) #3083

Description

@lingfeidiewu

Summary

When a deep link targeting a channel tab includes subEntityId in the context parameter, the tab receives context.page.subPageId correctly only if the link is clicked from a different chat/channel. If the same deep link is clicked from within the target channel's own conversation, subPageId is undefined on both desktop and web clients. Mobile (iOS/Android) works correctly in all cases.

Environment

  • @microsoft/teams-js: 2.53.0
  • Teams clients tested: Desktop (new Teams), Web (teams.microsoft.com)
  • Mobile: iOS Teams app
  • Tab type: Channel (configurable) tab
  • Manifest version: 1.17+
https://teams.microsoft.com/l/entity/<appId>/<entityId>?webUrl=<url>&label=<label>&context=<encoded-context>&groupId=<groupId>&tenantId=<tenantId>

Where context is:

{
  "subEntityId": "some-value",
  "canvasUrl": "https://example.com/teams/page?param=value",
  "channelId": "19:xxxxx@thread.tacv2"
}

Reproduction steps

  1. Pin a configurable tab to channel A.
  2. In the tab code, read subPageId on load:
    const ctx = await app.getContext();
    console.log('subPageId:', ctx.page.subPageId);
    
  3. Post the deep link (with subEntityId in context) as a message in channel A's conversation.
  4. Also post the same deep link in a different chat (e.g., a 1:1 chat or another channel).
  5. Click the link from the different chat → ✅ subPageId is populated.
  6. Click the link from channel A's own conversation → ❌ subPageId is undefined.
  7. Click the link from channel A's conversation on mobile → ✅ subPageId is populated.

Expected behavior

context.page.subPageId should contain the subEntityId value from the deep link regardless of where the link is clicked from.

Actual behavior

Click source Desktop Web Mobile
Different chat / channel ✅ subPageId received ✅ subPageId received ✅ subPageId received
Target channel's own conversation ❌ undefined ❌ undefined ✅ subPageId received

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions