【问题标题】:Fail to try webhook for Microsoft Teams site无法为 Microsoft Teams 网站尝试 webhook
【发布时间】:2017-10-13 14:02:56
【问题描述】:

有人知道我是不是做错了什么,或者目前有什么东西不工作?

  • 我使用 MessageCard Playground 并希望将数据发送到 Teams 频道。
  • 我确实设置了连接器并获得了一个 webhook url。
  • 现在我想向频道发送一些样本(有效的 json)

收到此错误:

知道我做错了什么吗?

更新

示例 JSON

{
  "@type": "MessageCard",
  "@context": "http://schema.org/extensions",
  "summary": "Issue 4711",
  "themeColor": "0078D7",
  "title": "Issue opened: \"TEST Message for webhook\"",
  "sections": [
    {
      "activityTitle": "Yves Rausch",
      "activitySubtitle": "10/12/2017, 22:34",
      "facts": [
        {
          "name": "Title:",
          "value": "TinyMCE 4 implementieren"
        },
        {
          "name": "Issue #:",
          "value": "6417"
        }
      ],
      "text": "There is a push webhook info and leads me to the workflow."
    }
  ],
  "potentialAction": [
    {
      "@type": "OpenUri",
      "name": "View in process",
      "targets": [
        { "os": "default", "uri": "https://intranet.tqsoft.net/ror/workflowact/6417" }
      ]
    }
  ]
}

【问题讨论】:

  • 您能添加一些示例代码和 JSON 负载吗?
  • @MarcLaFleur-Microsoft 添加了一些 Json 示例,但页面中的任何示例,例如Microsoft Flow 批准,导致相同的错误 400。
  • @MarcLaFleur-Microsoft 当我在请求中检查 Params 时,无论我拥有的 json 代码是什么,它都是空的。
  • 你如何将此有效负载发送到 webhook?
  • 正如我前面提到的,我使用messagecardplayground.azurewebsites.net 进行测试并希望以后使用 C#.Net

标签: microsoft-teams asp.net-webhooks


【解决方案1】:

目前 MessageCard Playground 中似乎存在一个错误,阻止它正确地 POST 到 webhook 端点。

我建议尝试使用 Postman 发出 HTTP 请求。您可以简单地从 Playground 复制并粘贴 JSON。有关如何设置的详细信息,请参阅Sending actionable messages via Office 365 Connectors

【讨论】:

    猜你喜欢
    • 2020-02-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-08-18
    • 2020-07-27
    • 1970-01-01
    相关资源
    最近更新 更多