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

Re: [rest-discuss] URI design

Expand Messages
  • Erik Wilde
    ... depends on how interactions are designed around it. just saying that a URI isn t RESTful doesn t make a whole lot of sense... cheers, dret.
    Message 1 of 5 , Nov 28, 2012
    • 0 Attachment
      On 2012-11-17 19:49 , Max Toro wrote:
      > Found this statement on the web:
      > "Implementing a http://www.mysite.com/invoice/add URI is not
      > considered a REST compliant practice."

      depends on how interactions are designed around it. just saying that "a
      URI isn't RESTful" doesn't make a whole lot of sense...

      cheers,

      dret.
    • Steve Klabnik
      REST says absolutely nothing about URI design.
      Message 2 of 5 , Nov 28, 2012
      • 0 Attachment
        REST says absolutely nothing about URI design.
      • Gaurav Agarwal
        I guess having something like: http://www.mysite.com/invoices And having a POST request to that link should make sense. Of course if trying to have a web
        Message 3 of 5 , Nov 28, 2012
        • 0 Attachment
          I guess having something like:
          http://www.mysite.com/invoices

          And having a POST request to that link should make sense.

          Of course if trying to have a web interface you could have a GET
          http://www.mysite.com/invoices/edit page.

          Sent to you by Gaurav Agarwal :)

        • Jan Algermissen
          ... What the quote is trying to say is, I guess, that designing interactions in the spirit of RPC (here: InvoceService.add(invoice)) is not RESTful. Correct
          Message 4 of 5 , Nov 29, 2012
          • 0 Attachment
            On Nov 18, 2012, at 4:49 AM, Max Toro <maxtoroq@...> wrote:

            > Found this statement on the web:
            > "Implementing a http://www.mysite.com/invoice/add URI is not
            > considered a REST compliant practice."
            >
            > What do you guys think?

            What the quote is trying to say is, I guess, that designing interactions in the spirit of RPC (here: InvoceService.add(invoice)) is not RESTful.

            'Correct' would be sth like

            POST /invoices

            Content-type: application/foo.invoice

            <invoice> ... </invoice>

            You do not need an 'add' semantic.


            As for the URI string per se: that is opaque and meaningless (as Erik and Steve already noted).

            Jan





            > --
            > Max Toro
            >
          Your message has been successfully submitted and would be delivered to recipients shortly.