Compose extension is throwing error : V3 agent not found

Compose extension is throwing error : V3 agent not found

我是在 Teams 中创建 Compose Extensions 的新手,在将其添加到我的 Teams 时遇到问题。

所有配置都已到位,从注册机器人到将其托管为 Azure 上的机器人服务,再到在代码中处理组合扩展查询。我已经在清单中共享了 Bot Id,并为 URL 托管的机器人提供了附加到端点 URL 的 /api/messages

作为独立应用程序的机器人可以在本地和 Azure Porta 上运行。我也成功地远程调试了它。但是,一旦我将其作为消息传递扩展加载到 Teams 中,查询就不会正确触发。

  1. 打字时停止并显示"Something went wrong with this app. Try Again"。

  2. 此外,当我们加载 Compose Extension 时,它应该对托管的 bot 应用程序进行初始命中,我有调试器,它既没有命中 Constructor 也没有命中 Post 方法.

  3. 我收到一个 404 错误 V3 agent not found 和一个失败的 POST 请求。

任何可能遇到过类似问题并已从中恢复过来的人,或者可能知道我可能哪里出错的人,请提供您的建议。非常感谢。

{
  "$schema": "https://statics.teams.microsoft.com/sdk/v1.2/manifest/MicrosoftTeams.schema.json",
  "manifestVersion": "1.2",
  "version": "1.0.0",
  "id": "f3c14e30-0af2-4f96-b714-5d258edcab47",
  "packageName": "net.azurewebsites.fetchassistant",
  "developer": {
    "name": "abc",
    "websiteUrl": "https://fetchassistant.azurewebsites.net",
    "privacyUrl": "https://fetchassistant.azurewebsites.net",
    "termsOfUseUrl": "https://fetchassistant.azurewebsites.net"
  },
  "icons": {
    "color": "color.png",
    "outline": "outline.png"
  },
  "name": {
    "short": "FetchAssistant",
    "full": "Fetch Assistant"
  },
  "description": {
    "short": "abc",
    "full": "xyz"
  },
  "accentColor": "#235EA5",
  "composeExtensions": [
    {
      "botId": "Microsoft App/Bot Id",
      "scopes": ["personal", "team"],
      "commands": [
        {
          "id": "FirstName",
          "description": "Search Relevant Documents",
          "title": "Get Name Division",
          "initialRun": false,
          "parameters": [
            {
              "name": "xyz",
              "description": "Get Name Division",
              "title": "Names"
            }
          ]
        }
      ]
    }
  ],
  "permissions": ["identity", "messageTeamMembers"],
  "validDomains": ["*.microsoft.com", "*.azurewebsites.net"]
}

我通过执行以下操作解决了您面临的问题:

  1. 导航到 https://dev.botframework.com/bots/
  2. 单击 "Add a featured channel" 部分中的 Microsoft Teams 图标
  3. 注册您的应用程序

我自己在扩展时遇到了这个错误。 按照添加频道的想法,我去了频道部分。

没有配置 Teams 频道。

所以,我添加了它。

加载我的扩展后错误消失了。