Creating a stand-alone forum recommendation
Added by IBM contributorIBM | Edited by Claudia R Elbourn on June 15, 2015
Rate this article 1 starsRate this article 2 starsRate this article 3 starsRate this article 4 starsRate this article 5 stars

To like a post(topic/reply) in a stand-alone forum, send an Atom entry document containning the forum recommendation to the forum topic/reply resources.

 

Input
Method URI Description
POST /forums/atom/recommendation/entries Value of the href attribute of the <link> element with the rel="recommendations" attribute value in the forum topic feed or forum reply feed.
Content Type: application/atom+xml
Sample Request:
<entry xmlns="http://www.w3.org/2005/Atom">
	    <title type="text">like</title>
	    <content type="text">reply test</content>
	    <category scheme="http://www.ibm.com/xmlns/prod/sn/type" term="recommendation"></category>
	</entry>
Name Type Optional Description
postUuid
string No The UUID of the post you wish to recommend.
Output
Content Type: application/atom+xml
Name Type Optional Description
Location
string No Link to edit_url of the forum recommendation. You can use the web address specified here to retrieve the forum recommendation.
Code Description
201
Indicates that the forum recommendation was successfully created. If an error occurs, this header contains one of the error codes.
400
Bad Request.
401
Unauthorized.
Examples
POST /forums/atom/recommendation/entries?postUuid=84139b22-17f0-4290-939b-73370c6ef17c HTTP/1.1
	Host: www.dulcinea.com
	Content-Type: application/atom+xml
	Authorization: xxx
	Content-Length: nnn
	
	<entry xmlns="http://www.w3.org/2005/Atom">
	    <title type="text">like</title>
	    <content type="text">reply test</content>
	    <category scheme="http://www.ibm.com/xmlns/prod/sn/type" term="recommendation"></category>
	</entry>

Response returned by the server
HTTP/1.1 201 Created
	Date: Wed, 04 Aug 2010 21:45:09 GMT
	Content-Length: nnn
	Content-Type: application/atom+xml; charset="utf-8"
	Location: http://www.dulcinea.com/forums/atom/recommendation/entries
	
	<entry xmlns="http://www.w3.org/2005/Atom">
	  <id>urn:lsid:ibm.com:forum:6cfec8d7-4263-494a-bf8d-3d05745c7e6f</id>
	  <title type="text">like</title>
	  <category term="recommendation" scheme="http://www.ibm.com/xmlns/prod/sn/type">
	  </category>
	  <author>
	    <email>ajones35@janet.iris.com</email>
	    <name>Amy Jones35</name>
	    <snx:userid xmlns:snx="http://www.ibm.com/xmlns/prod/sn">50730340-0101-102e-88fc-f78755f7e0ed</snx:userid>
	    <snx:userState xmlns:snx="http://www.ibm.com/xmlns/prod/sn">active</snx:userState>
	  </author>
	  <link href="http://lcfvt223.dyn.webahead.ibm.com:9081/forums/atom/recommendation/entry?postUuid=28847619-0723-41c8-9fdf-2b2d0cd59bdc" rel="self" type="application/atom+xml">
	  </link>
	  <link href="http://lcfvt223.dyn.webahead.ibm.com:9081/forums/atom/recommendation/entry?postUuid=28847619-0723-41c8-9fdf-2b2d0cd59bdc" rel="edit" type="application/atom+xml">
	  </link>
	  <link href="http://lcfvt223.dyn.webahead.ibm.com:9081/forums/html/topic?id=28847619-0723-41c8-9fdf-2b2d0cd59bdc" rel="alternate" type="application/atom+xml">
	  </link>
	</entry>