POST api/2.0/community/event/{feedid}/comment
Adds a comment to the event with the ID specified in the request. The parent event ID can be also specified if needed.
Name |
Description |
Type |
Example |
feedid
sent in url
|
Feed ID
|
number
|
1234
|
content
sent in body
|
Comment text
|
string
|
some text
|
parentId
sent in body
|
Comment parent ID
|
number
|
1234
|
Send parentId=0 or doesn't send it at all if you want your comment to be on the root level.
Sending data in application/json:
{
content:"My comment",
parentId:"9924256A-739C-462b-AF15-E652A3B1B6EB"
}
Sending data in application/x-www-form-urlencoded
content="My comment"&parentId="9924256A-739C-462b-AF15-E652A3B1B6EB"
application/json
{
"status": 0,
"response": {
"Id": 10,
"ParentId": 123,
"Created": "2020-12-07T13:56:02.2899133Z",
"Updated": "2020-12-07T13:56:02.2899133Z",
"CreatedBy": {
"Id": "00000000-0000-0000-0000-000000000000",
"DisplayName": "Mike Zanyatski",
"Title": "Manager",
"AvatarSmall": "url to small avatar",
"ProfileUrl": "\\/Products\\/People\\/Profile.aspx?user=administrator"
},
"Text": "comment text"
}
}
text/xml
<result>
<status>0</status>
<response>
<Id>10</Id>
<ParentId>123</ParentId>
<Created>2020-12-07T13:56:02.2899133Z</Created>
<Updated>2020-12-07T13:56:02.2899133Z</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>
<Text>comment text</Text>
</response>
</result>