0

I am building a static tab for MS Teams with contentBotId specified.The staticTabs manifest entry looks as following:

"staticTabs": [
    {
        "entityId": "availability",
        "name": "Availability",
        "scopes": [ "personal" ],
        "contentBotId": "myBotId",
        "context": [ "personalTab" ]
    },
    {
        "entityId": "coffees",
        "name": "Coffees",
        "scopes": [ "personal" ],
        "contentUrl": "https://my-content-url.com/...",
        "websiteUrl": "https://my-website-url.com/...",
        "context": ["personalTab"]
    }
],

So, the Availability tab is using contentBotId and Coffees tab is a website. I have no problems with Coffees tab at all but have problems with Availability tab in chat scope.
when I am trying to open the Availability tab from personal apps side panel - all works as expected:enter image description here
But when I am trying to open the same tab from chat with my bot - MS Teams shows There was a problem reaching this app error: enter image description here In MS Team Dev console I can see the following errors:

CDL: {"errorCode":"Error","requestId":"q-15","hostRendererId":"5e3ce6c0-2b1f-4285-8d4b-75ee78787346","component":"RequestHandler","requestWindowId":"main","operationType":"query","operationName":"appDefinition","message":"error while processing q-15: {\"name\":\"Error\",\"message\":\"Variable \\\"$appId\\\" got invalid value undefined; Expected non-nullable type \\\"ID!\\\" not to be null.\",\"stack\":[]} (reason: undefined)"}
console.error @ ?agent=electron&version=21071502213:1
invoke @ main-2d2eb2cbb891032b.js:22
error @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:22
safeWrapILoggerCall @ main-2d2eb2cbb891032b.js:22
error @ main-2d2eb2cbb891032b.js:22
onError @ main-2d2eb2cbb891032b.js:22
setResponseAndEndScenario @ main-2d2eb2cbb891032b.js:22
reconcileResponse @ main-2d2eb2cbb891032b.js:22
onMessageReceived @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:27
(anonymous) @ main-2d2eb2cbb891032b.js:27
(anonymous) @ VM5:2
emit @ electron/js2c/sandbox_bundle.js:170
onMessage @ electron/js2c/sandbox_bundle.js:151

TrackRequestLink: 'appDefinition' operation of type 'query' failed.
console.error @ ?agent=electron&version=21071502213:1
invoke @ main-2d2eb2cbb891032b.js:22
error @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:22
Ds @ main-2d2eb2cbb891032b.js:22
Ms @ main-2d2eb2cbb891032b.js:22
error @ main-2d2eb2cbb891032b.js:22
m @ 73296-3f79f77061841a23.js:1
b @ 73296-3f79f77061841a23.js:1
value @ 73296-3f79f77061841a23.js:1
error @ 73296-3f79f77061841a23.js:1
m @ 73296-3f79f77061841a23.js:1
b @ 73296-3f79f77061841a23.js:1
value @ 73296-3f79f77061841a23.js:1
(anonymous) @ main-2d2eb2cbb891032b.js:22
onError @ main-2d2eb2cbb891032b.js:22
onError @ main-2d2eb2cbb891032b.js:22
setResponseAndEndScenario @ main-2d2eb2cbb891032b.js:22
reconcileResponse @ main-2d2eb2cbb891032b.js:22
onMessageReceived @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:22
(anonymous) @ main-2d2eb2cbb891032b.js:27
(anonymous) @ main-2d2eb2cbb891032b.js:27
(anonymous) @ VM5:2
emit @ electron/js2c/sandbox_bundle.js:170
onMessage @ electron/js2c/sandbox_bundle.js:151

TrackRequestLink: Errors ['{"name":"Error","message":"Variable \"$appId\" got invalid value undefined; Expected non-nullable type \"ID!\" not to be null.","stack":[]}']

Error: Unable to fetch app definition

I've double checked manifest schema and think I am not missing anything but might be wrong. Please correct me if so. The schema I am using is: https://developer.microsoft.com/en-us/json-schemas/teams/v1.9/MicrosoftTeams.schema.json and manifest version is 1.9
Let me know if you need more details from me and thank you for help!

Rajeesh Menoth
  • 1,704
  • 3
  • 17
  • 33
Sergey Anisimov
  • 885
  • 8
  • 22

2 Answers2

1

I've not ever tried using contentBotId as I've always had web content behind my tab, but as a backup you can consider creating a web page / SPA that simply hosts and renders your adaptive card using the javascript library. Here's an example: https://learn.microsoft.com/en-us/adaptive-cards/sdk/rendering-cards/javascript/render-a-card

Hilton Giesenow
  • 9,809
  • 2
  • 10
  • 24
0

This bug fix is on the way. We do not have exact ETA to share but it will be available publicly soon.

Dharman
  • 30,962
  • 25
  • 85
  • 135
ChetanSharma-msft
  • 702
  • 1
  • 3
  • 6
  • Microsoft Teams updated recently, and it introduced a new issue to my app. Please see the picture: https://imgur.com/a/rZBjkUH I am not sure where I could raise a bug so please, could you raise it in your team? I've checked and Microsoft Teams doesn't make any request to my application so I could avoid it on my end – Sergey Anisimov Oct 04 '21 at 22:54
  • Please note that the "There was a problem reaching this app" is showing from the personal apps panel only and it doesn't show when open conversation with bot from the chats list – Sergey Anisimov Oct 04 '21 at 22:56
  • @SergeyAnisimov - You mean to say that your is reversed: Previously: 1) when I am trying to open the Availability tab from personal apps side panel - all works as expected: 2) Now: – ChetanSharma-msft Oct 05 '21 at 18:12
  • @SergeyAnisimov - You mean to say that your issue is reversed: Previously: 1) Open the Availability tab from personal apps side panel - all works as expected: 2) Open the same tab from chat with bot - MS Teams shows error Now: 1) Open the Availability tab from personal apps side panel - MS Teams shows error 2) Open the same tab from chat with bot - all works as expected Is this correct? – ChetanSharma-msft Oct 05 '21 at 18:14
  • No, I mean that there is a new issue. When you open bot app from left pane MS Teams shows the Chat tab with error message in half of a screen. Please, see the screenshot: https://imgur.com/a/URAGPQr – Sergey Anisimov Oct 05 '21 at 21:40
  • I think this issue is reproducible with any app in Microsoft Teams. Example with Microsoft's App Studio: https://imgur.com/a/bWdpBzR – Sergey Anisimov Oct 06 '21 at 12:22
  • @SergeyAnisimov - Could you please share your Teams client version details & repro steps so that I can check it from my end. – ChetanSharma-msft Oct 06 '21 at 16:34
  • `You have Microsoft Teams Version 1.4.00.26376 (64-bit). It was last updated on 10/4/2021.`. To reproduce it, install App Studio: https://teams.microsoft.com/l/app/0c5cfdbb-596f-4d39-b557-5d9516c94107?source=store-copy-link then open application from personal apps side panel (on the left side, see previous screenshots) and browse Chat tab. There you will see error message in half of the screen – Sergey Anisimov Oct 06 '21 at 22:22
  • @SergeyAnisimov - New issue which you have mentioned is not actually a bug. Anyway once the original first issue will fix, you won't be able to see that image with content "There was a problem reaching this app" – ChetanSharma-msft Oct 08 '21 at 16:49
  • Could you please clarify what do you mean under "not actually a bug"? There is an error message in half of user's screen which we cannot remove. If we can, please tell me how – Sergey Anisimov Oct 09 '21 at 00:39
  • Okay, waiting for fix release. I will check if both issues are resolved, thank you – Sergey Anisimov Oct 09 '21 at 00:51
  • @SergeyAnisimov - This issue is fixed. Could you please let us know if you are still facing this? – Wajeed Shaikh Nov 08 '21 at 18:01
  • @Wajeed-MSFT All good now, thanks for fixing it – Sergey Anisimov Nov 27 '21 at 09:02
  • I followed the guidelines [here](https://learn.microsoft.com/en-us/microsoftteams/platform/resources/dev-preview/developer-preview-intro) but I keep getting a manifest parsing error. I can't event upload the app package from the [sample app](https://github.com/OfficeDev/Microsoft-Teams-Samples/tree/main/samples/tab-adaptive-cards/csharp) – freeAll Mar 28 '22 at 18:39
  • @freeAll-Could you please share the error log? – Sayali-MSFT Mar 29 '22 at 06:02
  • I get the below when uploading the app package to teams `Error while extracting package: Please ensure there are no folders in your app package and that your app package contains only the manifest.json and the two required icon files at its root level. For an easier experience creating your app package , install App Studio from the Teams Store.` – freeAll Mar 29 '22 at 17:47
  • Importing the manifest on app studio removes the preview [schema](https://raw.githubusercontent.com/OfficeDev/microsoft-teams-app-schema/preview/DevPreview/MicrosoftTeams.schema.json) and manifestVersion values, and then starts complaining with `staticTabs[1].contentUrl | String "" does not match regex pattern "^[Hh][Tt][Tt][Pp][Ss]?://".` – freeAll Mar 29 '22 at 17:56
  • It's looks like issue with icon.Could you please add icon properly and the content url. We are checking the [sample](https://github.com/OfficeDev/Microsoft-Teams-Samples/tree/main/samples/tab-adaptive-cards/csharp)our end. It's working fine for us.Could you please check it once? – Sayali-MSFT Mar 30 '22 at 05:27