W3C home > Mailing lists > Public > www-tag@w3.org > April 2002

RE: REST and the Web

From: Mike Dierken <mike@dataconcert.com>
Date: Mon, 1 Apr 2002 09:40:07 -0800
Message-ID: <2AE31649CF989F4FB354F6D95EB0CE6E5CEBDB@xmlfmail.xmlfund.com>
To: www-tag@w3.org


> -----Original Message-----
> From: Joshua Allen [mailto:joshuaa@microsoft.com] 

> There *is* a "proper" way to use POST: in my opinion that is 
> the behavior which says that the POSTed entity creates a new 
> URI which is subordinate to the POST target, and returns the 
> URI of that new resource.  This is really a fine 
> architecture, and if people stuck to it we would have a much 
> easier time in realizing the semantic web.

There isn't a requirement in the specification that a new resource with a
URI be created.
If it happens that a new resource is created, the protocol describes how to
say that (201 Created and Location:), but it is optional behavior.

--rfc2068--
9.5 POST

   The POST method is used to request that the destination server accept
   the entity enclosed in the request as a new subordinate of the
   resource identified by the Request-URI in the Request-Line. 
   [...]
   The action performed by the POST method might not result in a
   resource that can be identified by a URI. In this case, either 200
   (OK) or 204 (No Content) is the appropriate response status,
   depending on whether or not the response includes an entity that
   describes the result.

   If a resource has been created on the origin server, the response
   SHOULD be 201 (Created) and contain an entity which describes the
   status of the request and refers to the new resource, and a Location
   header (see section 14.30).
Received on Monday, 1 April 2002 12:41:22 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 26 April 2012 12:47:06 GMT