POST api/2.0/community/forum/{threadid} This function requires authentication

Description

Adds a new topic to the existing thread with a subject, content and topic type specified in the request.

Parameters
Name Description Type Example
threadid
sent in url
Thread ID number 1234
subject
sent in body
Topic subject string some text
content
sent in body
Topic text string some text
topicType
sent in body
Topic type Informational, Poll
Example
POST api/2.0/community/forum/1234
Host: yourportal.onlyoffice.com
Content-Type: application/json
Accept: application/json

{
  "subject": "some text",
  "content": "some text",
  "topicType": "Informational"
}
Returns

Added topic

Example Response

application/json

{
  "status": 0,
  "response": {
    "Id": 10,
    "Title": "Sample topic",
    "Created": "2020-12-07T13:56:02.3259212Z",
    "Updated": "2020-12-07T13:56:02.3259212Z",
    "Text": "This is sample post",
    "UpdatedBy": {
      "Id": "00000000-0000-0000-0000-000000000000",
      "DisplayName": "Mike Zanyatski",
      "Title": "Manager",
      "AvatarSmall": "url to small avatar",
      "ProfileUrl": "\\/Products\\/People\\/Profile.aspx?user=administrator"
    },
    "ThreadTitile": null,
    "Status": 0,
    "Type": 0,
    "Posts": [
      {
        "Id": 123,
        "Subject": "Sample subject",
        "Text": "Post text",
        "Created": "2020-12-07T13:56:02.3269198Z",
        "Updated": "2020-12-07T13:56:02.3269198Z",
        "CreatedBy": {
          "Id": "00000000-0000-0000-0000-000000000000",
          "DisplayName": "Mike Zanyatski",
          "Title": "Manager",
          "AvatarSmall": "url to small avatar",
          "ProfileUrl": "\\/Products\\/People\\/Profile.aspx?user=administrator"
        },
        "ThreadTitle": "Title",
        "Attachments": {
          "Name": "picture.jpg",
          "ContentType": "image/jpeg",
          "Created": "2020-12-07T13:56:02.3269198Z",
          "Updated": "2020-12-07T13:56:02.3269198Z",
          "Size": 122345,
          "Path": "url to file"
        }
      }
    ],
    "Tags": "Tag1,Tag2"
  }
}

text/xml

<result>
  <status>0</status>
  <response>
    <Id>10</Id>
    <Title>Sample topic</Title>
    <Created>2020-12-07T13:56:02.3259212Z</Created>
    <Updated>2020-12-07T13:56:02.3259212Z</Updated>
    <Text>This is sample post</Text>
    <UpdatedBy>
      <Id>00000000-0000-0000-0000-000000000000</Id>
      <DisplayName>Mike Zanyatski</DisplayName>
      <Title>Manager</Title>
      <AvatarSmall>url to small avatar</AvatarSmall>
      <ProfileUrl>\/Products\/People\/Profile.aspx?user=administrator</ProfileUrl>
    </UpdatedBy>
    <ThreadTitile />
    <Status>0</Status>
    <Type>0</Type>
    <Posts>
      <Id>123</Id>
      <Subject>Sample subject</Subject>
      <Text>Post text</Text>
      <Created>2020-12-07T13:56:02.3269198Z</Created>
      <Updated>2020-12-07T13:56:02.3269198Z</Updated>
      <CreatedBy>
        <Id>00000000-0000-0000-0000-000000000000</Id>
        <DisplayName>Mike Zanyatski</DisplayName>
        <Title>Manager</Title>
        <AvatarSmall>url to small avatar</AvatarSmall>
        <ProfileUrl>\/Products\/People\/Profile.aspx?user=administrator</ProfileUrl>
      </CreatedBy>
      <ThreadTitle>Title</ThreadTitle>
      <Attachments>
        <Name>picture.jpg</Name>
        <ContentType>image/jpeg</ContentType>
        <Created>2020-12-07T13:56:02.3269198Z</Created>
        <Updated>2020-12-07T13:56:02.3269198Z</Updated>
        <Size>122345</Size>
        <Path>url to file</Path>
      </Attachments>
    </Posts>
    <Tags>Tag1,Tag2</Tags>
  </response>
</result>