Insert a Social Post
NOTE: Inserting a post in a social feed is supported only with Microsoft SharePoint 2013.
To insert a post in a social feed, the insertXml
must include the following properties:
TYPE
|
The type of item to insert. To insert a post, specify SOCIALPOST .
|
The following properties specify where to insert the post:
SOCIALTHREADID
|
The ID of the thread to add the post to. If you set SOCIALTHREADID and not SITEFEEDURL , the post is added as a reply to the specified thread. |
SITEFEEDURL
|
The URL of the feed to add the post to. If you set SITEFEEDURL and not SOCIALTHREADID , the post is created in a new thread in the specified site feed. |
If you set neither SOCIALTHREADID
or SITEFEEDURL
, the post is created in a new thread in the authenticated user's feed (the user specified in the connector's configuration file).
The following metadata is required:
TEXT
|
The content to include in the new post. |
The following metadata is optional:
LINK
|
The text (that you added to the TEXT field) to make into a link, followed by a comma, followed by the link URL. You can include any number of LINK metadata elements. |
ATTACHMENTURI
|
The location (URI) of an attachment to include in the new post. |
For example, the value of your insertXML
action parameter might look like this:
<insertXML> <insert> <reference>[REF]</reference> <property name="TYPE" value="SOCIALPOST" /> <property name="SOCIALTHREADID" value="[THREADID]"/> <property name="SITEFEEDURL" value="http://SiteCollection.com/Site/newsfeed.aspx"/> <metadata name="TEXT" value="SomeContent"/> <metadata name="LINK" value="[TEXT],[URL]"/> <metadata name="ATTACHMENTURI" value="[URI]"/> </insert> </insertXML>