Another Kind of HTTP Negotiation
Wednesday, 6 February 2008
Here’s one that I’ve been wondering about for a while, for the LazyWeb (HTTP Geek Edition);
PUTs and POSTs can result in the creation of new resources, or changes to the state of existing ones. The response to both can contain one of
- a status message about what happened, or
- a representation of the resource (or most important one, if more than one was created/modified); often signalled by the
Content-Location header
, or - nothing (i.e., just the status line and headers), usually a
204 No Content
.
Usually, a server will just choose which of these is most appropriate, and send it for all such requests. However, I can easily see cases where clients would want to hint to the server what they want back; e.g., a mobile client might prefer nothing, for efficiency, while a publisher might want to get a copy of the article they just submitted back, to make sure that they have any changes to the content locally.
My question is how a client should hint what they want back in such responses, and specifically whether this is purely an application-specific concern (and should therefore be expressed in the request-URI, for example), or is worthy of a standard (thereby better being expressed in a header).
BTW, I don’t think this is a form of content negotiation; that’s about the format of the response, and overloading it for this would produce some problems (e.g., how do you differentiate between an HTML status message and a HTML representation? There are also conflicts with probably resolutions of issue 69).
25 Comments
Mike Amundsen said:
Wednesday, February 6 2008 at 1:42 AM
James Snell said:
Wednesday, February 6 2008 at 1:55 AM
Stefan Eissing said:
Wednesday, February 6 2008 at 2:03 AM
Mike Amundsen said:
Wednesday, February 6 2008 at 2:30 AM
Mark Nottingham said:
Wednesday, February 6 2008 at 2:32 AM
James Snell said:
Wednesday, February 6 2008 at 2:36 AM
Mark Nottingham said:
Wednesday, February 6 2008 at 2:43 AM
Mike Amundsen said:
Wednesday, February 6 2008 at 2:58 AM
duryodhan said:
Wednesday, February 6 2008 at 3:36 AM
Robert Brewer said:
Wednesday, February 6 2008 at 4:07 AM
James Snell said:
Wednesday, February 6 2008 at 4:28 AM
Dimitri Glazkov said:
Wednesday, February 6 2008 at 4:57 AM
Mike Amundsen said:
Wednesday, February 6 2008 at 5:10 AM
Mark Nottingham said:
Wednesday, February 6 2008 at 5:13 AM
Mike Amundsen said:
Wednesday, February 6 2008 at 5:32 AM
Subbu Allamaraju said:
Wednesday, February 6 2008 at 6:27 AM
Mike Amundsen said:
Thursday, February 7 2008 at 1:47 AM
Mike Amundsen said:
Thursday, February 7 2008 at 4:25 AM
Mark Nottingham said:
Thursday, February 7 2008 at 4:25 AM
James Snell said:
Thursday, February 7 2008 at 7:42 AM
James Snell said:
Friday, February 8 2008 at 7:45 AM
Mark Nottingham said:
Friday, February 8 2008 at 9:15 AM
Mike Amundsen said:
Sunday, February 10 2008 at 2:24 AM
Brian Smith said:
Wednesday, February 13 2008 at 6:47 AM
James Snell said:
Friday, February 15 2008 at 6:06 AM