【发布时间】:2022-05-05 04:26:47
【问题描述】:
我正在为指定 contentBotId 的 MS Teams 构建一个静态选项卡。staticTabs 清单条目如下所示:
"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"]
}
],
因此,可用性选项卡使用 contentBotId,而咖啡选项卡是一个网站。我对 Coffees 选项卡没有任何问题,但在聊天范围内的可用性选项卡有问题。
当我尝试从个人应用程序侧面板打开可用性选项卡时 - 一切都按预期工作:
但是,当我尝试通过与我的机器人聊天打开同一个选项卡时 - MS Teams 显示 访问此应用时出现问题 错误:
在 MS Team Dev 控制台中,我可以看到以下错误:
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
我已经仔细检查了清单架构,并认为我没有遗漏任何东西,但可能是错误的。如果是,请纠正我。我使用的架构是:https://developer.microsoft.com/en-us/json-schemas/teams/v1.9/MicrosoftTeams.schema.json,清单版本是 1.9
如果您需要我提供更多详细信息,请告诉我,感谢您的帮助!
【问题讨论】:
标签: botframework chatbot microsoft-teams teams-toolkit