Community articleCreating bookmarks programmatically
Added by IBM contributorIBM on June 19, 2014
Rate this article 1 starsRate this article 2 starsRate this article 3 starsRate this article 4 starsRate this article 5 stars

To create a bookmark, send an Atom entry document containing the new bookmark to the bookmarks feed.


To create a bookmark, send an Atom entry document containing the new bookmark to the bookmarks feed.

See Authenticating requests for information about how to authenticate the request.

Input
Method URI Description
POST /dogear/api/app Found in the href attribute of the <collection> element in the user's service document.
Content Type: application/atom+xml
Sample Request:
<?xml version="1.0" encoding="UTF-8"?>

<entry
        xmlns:atom="http://www.w3.org/2005/Atom"
        xmlns:snx="http://www.ibm.com/xmlns/prod/sn"
        xmlns:thr="http://purl.org/syndication/thread/1.0">
<category term="bookmark" scheme="http://www.ibm.com/xmlns/prod/sn/type">
</category>
<id>http://communities.ibm.com:2006/service/atom/community/bookmarks?communityUuid=050c03c9-e062-4804-a6fc-0462c880fcaf&amp;referenceId=f48a42ca-d00e-46d9-9abe-2d08b9bfaf4c</id>
<title type="text">IBM Bookmark Test NEW</title>
<summary type="text">IBM Description NEW</summary>
<content type="text">IBM Description NEW</content>
<published>2014-01-28T14:32:11.547Z</published>
<updated>2014-01-28T14:32:11.547Z</updated>

<category term="ibm">
</category>
<category term="sbt">
</category>
<link href="http://www.ibm.com/">
</link>
<link href="https://greenhousestage.lotus.com/communities/service/atom/community/bookmarks?communityUuid=050c03c9-e062-4804-a6fc-0462c880fcaf&amp;referenceId=f48a42ca-d00e-46d9-9abe-2d08b9bfaf4c" rel="self">
</link>
<link href="https://greenhousestage.lotus.com/communities/service/atom/community/bookmarks?communityUuid=050c03c9-e062-4804-a6fc-0462c880fcaf&amp;referenceId=f48a42ca-d00e-46d9-9abe-2d08b9bfaf4c" rel="edit">
</link>
</entry>
Name Type Optional Description
userid
string No User ID of the user that owns the bookmark feed that the entry is being created in.
Output
Content Type: application/atom+xml
Name Type Optional Description
Location
string No Link to edit_url of the new bookmark entry. You can use the web address specified here to subsequently retrieve and update the bookmark entry.
Code Description
201
Indicates that the bookmark was successfully created. If an error occurs, this header contains one of the error codes.
400
Bad Request.
403
Forbidden.