Loading ...
Sorry, an error occurred while loading the content.
 

Re: [rest-discuss] Content negotiation unRESTful?

Expand Messages
  • Ben Ramsey
    ... The atom:entry represents a particular resource with whatever content is specified by the atom:content element. The proper way to represent other types of
    Message 1 of 20 , Apr 1, 2008
      On 3/31/08 10:06 AM, Jan Algermissen wrote:
      > Hmm...wonder how one would do this with an Atom entry's content,
      > where there can only be one content which also should have a media
      > type attribute set.

      The atom:entry represents a particular resource with whatever content is
      specified by the atom:content element.

      The proper way to represent other types of representations of the same
      atom:entry would be to use an atom:link with a rel attribute of "alternate" and
      a type attribute for the specific media type represented by the URI in the link
      href.

      You can have multiple "alternate" atom:link elements provided that there is not
      more than one with the same combination of type and hreflang.

      --
      Ben Ramsey
      http://benramsey.com/
    • Sebastien Lambla
      303 and httpRange-14 is a benefit. ... From: rest-discuss@yahoogroups.com [mailto:rest-discuss@yahoogroups.com] On Behalf Of Subbu Allamaraju Sent: 31 March
      Message 2 of 20 , Apr 7, 2008
        303 and httpRange-14 is a benefit.

        -----Original Message-----
        From: rest-discuss@yahoogroups.com [mailto:rest-discuss@yahoogroups.com] On
        Behalf Of Subbu Allamaraju
        Sent: 31 March 2008 16:07
        To: Jan Algermissen
        Cc: Stefan Tilkov; REST Discuss
        Subject: Re: [rest-discuss] Content negotiation unRESTful?

        Strictly speaking, this is still agent-driven content-negotiation, and
        the redirect you are proposing may be an implementation detail. IMO,
        this redirect is not necessary. There is no need for each
        representation to get its own URI, and in some cases, it could create
        unnecessary proliferation without extra benefits.

        Subbu

        On Mar 31, 2008, at 7:06 AM, Jan Algermissen wrote:
        > After taking a glance at it: I am not sure about the way he quotes
        > Roy or XML vs JSON being mechanical etc. but I think it is generally
        > correct not to deliver different media types through the same
        > resource. If you have several, then publish a single URI that
        > redirects to media type specific ones based upon the Accept header.
        > That way every resource gets its own URI which gives the client more
        > control/possibilities.


        ------------------------------------

        Yahoo! Groups Links
      Your message has been successfully submitted and would be delivered to recipients shortly.