Newer Version Available
Post a Rich-Text Feed Element
This example posts a feed element that includes two paragraphs and an extra line break between them.
- Resource
- /chatter/feed-elements
- HTTP method
- POST
- Request body
- Feed Item Input
- Request body example
-
1{ 2 "body":{ 3 "messageSegments":[ 4 { 5 "markupType" : "Paragraph", 6 "type" : "MarkupBegin" 7 }, 8 { 9 "text" : "First line of text.", 10 "type" : "Text" 11 }, 12 { 13 "markupType" : "Paragraph", 14 "type" : "MarkupEnd" 15 }, 16 { 17 "markupType" : "Paragraph", 18 "type" : "MarkupBegin" 19 }, 20 { 21 "text" : " ", 22 "type" : "Text" 23 }, 24 { 25 "markupType" : "Paragraph", 26 "type" : "MarkupEnd" 27 }, 28 { 29 "markupType" : "Paragraph", 30 "type" : "MarkupBegin" 31 }, 32 { 33 "text" : "Second line of text.", 34 "type" : "Text" 35 }, 36 { 37 "markupType" : "Paragraph", 38 "type" : "MarkupEnd" 39 } 40 ] 41 }, 42 "subjectId":"me", 43 "feedElementType":"FeedItem" 44} - Returns
- Feed Item