Home
Retrieving the Bookmarks service document
The first step perform if you plan to update resources made available through the Atom APIs is to retrieve the service document for the feature.
Atom API request details
Method Resource URI Description GET Service Document /api/app Retrieves a user's service document which defines a single workspace containing the user's collection of bookmarks.
Example
To retrieve the service document for the Bookmarks feature, send the following HTTP request:> GET /dogear/api/app HTTP/1.1 > Authorization: Basic ... > Host: dogear.enterprise.acme.com:9084 > Accept: */* > < HTTP/1.1 302 Found < Location: https://dogear.enterprise.acme.com:9447/dogear/api/app < Content-Language: en-US < Content-Length: 0 < Date: Tue, 26 Feb 2008 17:35:19 GMT < Server: WebSphere Application Server/6.1 ... > GET /dogear/api/app HTTP/1.1 > Authorization: Basic ... > Host: dogear.enterprise.acme.com:9447 > Accept: */*The HTTP response would look as follows:
< HTTP/1.1 200 OK < Content-Type: application/atomsvc+xml; charset=UTF-8 < Pragma: private < Cache-Control: private, no-cache=set-cookie < Content-Language: en-US < Set-Cookie: JSESSIONID=0000DjFA1vb88VDN0OKtoGS1OfG:-1; Path=/ < Transfer-Encoding: chunked < Date: Tue, 26 Feb 2008 17:35:19 GMT < Server: WebSphere Application Server/6.1 < Expires: Thu, 01 Dec 1994 16:00:00 GMTThe service document for Bookmarks is returned by the server. For example:
<?xml version="1.0" encoding="utf-8" ?> <service xmlns="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom"> <workspace> <atom:title>My Bookmarks</atom:title> <collection href="https://dogear.enterprise.acme.com:9447/dogear/api/app? email=Suzy_Jones11%40us.acme.com"> <atom:title>Entries</atom:title> <accept>entry</accept> <categories href="https://dogear.enterprise.acme.com:9447/dogear/tags? email=Suzy_Jones11%40us.acme.com" /> <categories href="https://dogear.enterprise.acme.com:9447/dogear/api/app/flags" /> </collection> </workspace> </service>If Lotus Connections is configured to prevent e-mail addresses from being displayed, the following content would be returned:
<?xml version="1.0" encoding="utf-8" ?> <service xmlns="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom"> <workspace> <atom:title>My Bookmarks</atom:title> <collection href="https://dogear.enterprise.acme.com:9447/dogear/api/app? userid=472835c0-8f0a-1028-8a08-db08123b51b2"> <atom:title>Entries</atom:title> <accept>entry</accept> <categories href="https://dogear.enterprise.acme.com:9447/dogear/tags? userid=472835c0-8f0a-1028-8a08-db08123b51b2" /> <categories href="https://dogear.enterprise.acme.com:9447/dogear/api/app/flags" /> </collection> </workspace> </service>