Navigate The Section Hierarchy

A client application can navigate the section hierarchy by recursively following all links with the rel attribute down (see down).

Root section 1 in the "start" Atom feed shown in Get Started, for example, has a single down link that returns a new feed containing entries for all of section 1's subsections. So submitting the request:

curl -u user:password -X GET http://host-ip-address/webservice/escenic/section/1/subsections

returns a new Atom feed like this:

<feed xmlns="http://www.w3.org/2005/Atom"> 
  <author> 
    <name>Escenic Content Engine</name>
  </author>
  <id>http://host-ip-address/webservice/escenic/section/1/subsections</id>   
  <link rel="self" 
        href="http://host-ip-address/webservice/escenic/section/1/subsections" 
        type="application/atom+xml"/>  
  <updated>2010-06-23T17:35:45.180Z</updated>  
  <title type="text">Subsections for Section with id=1</title> 
  <entry>  
    <id>http://host-ip-address/webservice/escenic/section/4</id> 
    <title type="text">New Articles</title>
    <updated>2010-06-22T10:16:46.637Z</updated>
    <category term="directory" scheme="http://www.escenic.com/types"/>   
    <link rel="edit-media" 
          type="application/vnd.escenic.content+xml;type=com.escenic.section" 
          href="http://host-ip-address/webservice/escenic/section/4"/>  
    <link rel="down" 
          href="http://host-ip-address/webservice/escenic/section/4/subsections" 
          type="application/atom+xml"/>
    <link rel="http://www.escenic.com/types/relation/inboxes" 
          href="http://host-ip-address/webservice/escenic/section/4/inboxes" 
          type="application/atom+xml"/>
    <link rel="http://www.escenic.com/types/relation/lists" 
          href="http://host-ip-address/webservice/escenic/section/4/lists" 
          type="application/atom+xml"/>
    <link rel="http://www.escenic.com/types/relation/pages" 
          href="http://host-ip-address/webservice/escenic/section/4/pages" 
          type="application/atom+xml"/>
    <link rel="http://www.escenic.com/types/relation/content-items" 
          href="http://host-ip-address/webservice/escenic/section/4/content-items" 
          type="application/atom+xml"/> 
    <link rel="http://www.escenic.com/types/relation/changelog" 
          href="http://host-ip-address/webservice/escenic/changelog/section/4" 
          type="application/atom+xml"/>
  </entry>
...
</feed>

Each entry in this feed contains a similar down link leading to further subsections that the client can follow. If a section has no subsections, then following the link will result in an empty feed like this:

<feed xmlns="http://www.w3.org/2005/Atom">
  <author>
    <name>Escenic Content Engine</name>   
  </author>   
  <id>http://host-ip-address/webservice/escenic/section/4/subsections</id>  
  <link 
    rel="self" 
    href="http://host-ip-address/webservice/escenic/section/4/subsections" 
    type="application/atom+xml"/> 
  <updated>2010-06-23T18:15:53.779Z</updated> 
  <title type="text">Subsections for Section with id=4</title>
  <link href="http://host-ip-address/webservice/escenic/section/1/subsections"/>
</feed>

A client can therefore use these links to traverse the entire section tree of a publication.