post: reply

回复帖子,并向组对话中的指定线程添加新帖子。可以在请求中同时指定父对话和线程,或者仅指定父线程,而不指定父对话。

先决条件

要执行此 API,需要以下范围之一:

Group.Readwrite.All

HTTP 请求

POST /groups/{id}/threads/{id}/posts/{id}/reply
POST /groups/{id}/conversations/{id}/threads/{id}/posts/{id}/reply

请求标头

标头
Authorization Bearer . Required.

请求正文

在请求正文中,提供具有以下参数的 JSON 对象。

参数 类型 说明
帖子 帖子 正在回复的新帖子。

响应

如果成功,此方法返回 200, OK 响应代码。它不在响应正文中返回任何内容。

示例

下面是一个如何调用此 API 的示例。

请求

下面是一个请求示例。

POST https://graph.microsoft.com/v1.0/groups/{id}/threads/{id}/posts/{id}/reply
Content-type: application/json
Content-length: 1131

{
  "post": {
    "body": {
      "contentType": "",
      "content": "content-value"
    },
    "receivedDateTime": "datetime-value",
    "hasAttachments": true,
    "from": {
      "emailAddress": {
        "name": "name-value",
        "address": "address-value"
      }
    },
    "sender": {
      "emailAddress": {
        "name": "name-value",
        "address": "address-value"
      }
    },
    "conversationThreadId": "conversationThreadId-value",
    "newParticipants": [
      {
        "emailAddress": {
          "name": "name-value",
          "address": "address-value"
        }
      }
    ],
    "conversationId": "conversationId-value",
    "createdDateTime": "datetime-value",
    "lastModifiedDateTime": "datetime-value",
    "changeKey": "changeKey-value",
    "categories": [
      "categories-value"
    ],
    "id": "id-value",
    "inReplyTo": {
    },
    "attachments": [
      {
        "lastModifiedDateTime": "datetime-value",
        "name": "name-value",
        "contentType": "contentType-value",
        "size": 99,
        "isInline": true,
        "id": "id-value"
      }
    ]
  }
}
响应
响应

下面是一个响应示例。

HTTP/1.1 200 OK