Guest user
Jiglu developers
Previous item Next item

Tagged pages collection

The tagged pages Collection can be used to store any arbitrary content and have it tagged.

Submission

Site

A Space can have more than one tagged site. The tagged site to be used is specified by the <url> sub-element of the <author> element. You will be told this URL when you add or edit a tagged site.

Identifier

You must supply an identifier with an Atom Entry in the <id> element. Most commonly this will be the URL where visitors can view the tagged page but other internal identifiers can be used instead.

Content

Content to be tagged is submitted using a POST method request to the collection URL in the <content> element. This can be have a type of either text, html or xhtml but will always be converted to plain text for tagging anyway.

Response code

When a tagged page is successfully created using the API a response code of 201 will be given and the location of the new tagged page sent back in the Location: header.

Listing tagged pages in a collection

To retrieve a list of tagged pages, do a GET method request to the collection URL.

Tagged pages are returned in the order that they were tagged. The collection supports paging and returns first, last, next and previous links.

Retrieving individual tagged pages

You can retrieve the tags for a page in one of two ways:

  • Do a GET request on the URL returned in the Location: header of the response when the content was submitted.
  • Do a GET request on the Collection URL with a parameter of site containing the ID of the site being retrieved (the long alphanumeric bit at the end of the <url> element used in its submission) and a parameter of pages containing the URLs of the pages to be retrieved as specified in the <id> element on their submission, with each URL separated by a semicolon.

Tags that have been assigned manually will be returned in <category> elements of the Atom entry. Tags that have been assigned automatically will be returned in the <content> element according to the Jiglu Tagging Schema.

Updating

It is not currently possible to update an existing tagged page using the API. You will need to delete it and resubmit again.

Deletion

To delete a tagged page do a DELETE request on the URL returned in the Location: header when the tagged page was created.

Written by Stephen Hebditch.
Published on Thursday, 7 August 2008 at 15:10. Version 7.0.0.