0

我正在尝试在 App Source 上发布 MS Teams 聊天机器人,但遇到了以下错误

或者

这是我的 manifest.json 文件的样子

{
  "$schema": "https://developer.microsoft.com/en-us/json-schemas/teams/v1.5/MicrosoftTeams.schema.json",
  "manifestVersion": "1.5",
  "version": "1.0.1",
  "id": "0007-0007-4a9f-8163-0007",
  "packageName": "MyBOT.Manifest",
  "developer": {
    "name": "MyCompany",
    "websiteUrl": "https://MyBOT.azurewebsites.net",
    "privacyUrl": "https://MyBOT.azurewebsites.net/Privacy",
    "termsOfUseUrl": "https://MyBOT.azurewebsites.net/Termsofuse",
    "mpnId": "0007"
  },
  "localizationInfo": {
    "defaultLanguageTag": "en-us"
  },
  "icons": {
    "color": "icon-color.png",
    "outline": "icon-outline.png"
  },
  "name": {
    "short": "MyBOT",
    "full": "MyBOT Virtual Assistant"
  },
  "description": {
    "short": "MyBOT",
    "full": "I am a Virtual Assistant, continuously in training to enhance my skills. Currently, I can help you by answering inquiries related to COVID-19, Zoom, Webex, Microsoft Office, Adobe, Microsoft Azure and Xbox. For questions that are not currently in my search database, I leverage the web to fetch you those information."
  },
  "accentColor": "#F9F9FA",
  "bots": [
    {
      "botId": "0007-0007-4a9f-8163-0007",
      "needsChannelSelector": false,
      "isNotificationOnly": false,
      "scopes": [ "team", "personal", "groupchat" ],
      "supportsFiles": false,
      "isNotificationOnly": false,
      "commandLists": [
        {
          "scopes": [ "team", "groupchat" ],
          "commands": [
            {
              "title": "help",
              "description": "Provides you the list of commands that you can enter"
            },
            {
              "title": "cancel",
              "description": "Cancels the current operation"
            }
          ]
        },
        {
          "scopes": [ "personal", "groupchat" ],
          "commands": [
            {
              "title": "main menu",
              "description": "This command takes you to the main menu"
            },
            {
              "title": "help",
              "description": "Provides you the list of commands that you can enter"
            }
          ]
        }
      ]
    }
  ],
  "permissions": [
    "identity",
    "messageTeamMembers"
  ],
  "validDomains": [
    "token.botframework.com"
  ]
}

验证器也给出以下错误

验证器错误

我已经查看了 Stackoverflow 中的这条消息以及在线搜索,但我无法获得关于如何解决此问题的确切文章。我读到了该应用程序必须如何适用于所有类型的设备,但manifest.json文件没有显示如何完成。有人可以给我一个模板,我可以在上面构建我的 manifest.json 文件吗?还是我完全做错了什么?

谢谢你。

4

3 回答 3

1

这个文件解决了这个问题。我们使用 AppStudio 来获取此文件。

   {
"$schema": "https://developer.microsoft.com/en-us/json-schemas/teams/v1.7/MicrosoftTeams.schema.json",
"manifestVersion": "1.7",
"version": "1.0.0",
"showLoadingIndicator": true,
"isFullscreen": true,
"id": "80007-8049-0007-8163-e89f9a80007",
"packageName": "com.myCompany.myBOT",
"developer": {
    "name": "myCompany Services",
    "websiteUrl": "https://myBOT.azurewebsites.net",
    "privacyUrl": "https://myBOT.azurewebsites.net/Privacy",
    "termsOfUseUrl": "https://myBOT.azurewebsites.net/Termsofuse",
    "mpnId": "00000"
},
"icons": {
    "color": "color.png",
    "outline": "outline.png"
},
"name": {
    "short": "myBOT",
    "full": "myBOT Virtual Assistant"
},
"description": {
    "short": "myBOT",
    "full": "I am a Virtual Assistant, continuously in training to enhance my skills. Currently, I can help you by answering inquiries related to COVID-19, Zoom, Webex, Microsoft Office, Adobe, Microsoft Azure and Xbox. For questions that are not currently in my search database, I leverage the web to fetch you those information."
},
"accentColor": "#F9F9FA",
"bots": [
    {
        "botId": "80007-8049-0007-8163-e89f9a890007",
        "scopes": [
            "team",
            "personal",
            "groupchat"
        ],
        "supportsFiles": false,
        "isNotificationOnly": false
    }
],
"permissions": [
    "identity",
    "messageTeamMembers"
],
"validDomains": [] }
于 2020-06-18T06:52:53.007 回答
0

有人可以给我一个模板,我可以在上面构建我的 manifest.json 文件吗?

你也许可以从这个开始(特别是搜索扩展),但你显然想要改变/修剪/添加它来做你真正想做的事情。 https://github.com/microsoft/BotBuilder-Samples/blob/master/samples/csharp_dotnetcore/50.teams-messaging-extensions-search/TeamsAppManifest/manifest.json

更多示例有清单文件的其他示例。

此外,您可能想尝试从App Studio(允许您创建它们的 MS Teams 应用)创建清单。

于 2020-06-15T18:51:20.760 回答
0

"IsNotificationOnly"属性在清单中添加了两次。能否请您尝试删除它并再次检查。

在此处输入图像描述

假设您已经有两个文件“icon-color.png”和“icon-outline.png”以及应用程序包 zip 文件中的 manifest.json。您能否验证所有三个文件是否都添加到 zip 文件中,并且在 zip 包中没有创建文件夹。

于 2020-06-15T10:53:04.013 回答