W3C home > Mailing lists > Public > ietf-http-wg@w3.org > October to December 2011

Re: "Accept" on 415 responses?

From: mike amundsen <mamund@yahoo.com>
Date: Mon, 12 Dec 2011 16:56:25 -0500
Message-ID: <CAPW_8m6tF5ubDV1WXj1rGa45gndukNYPWLzvNBGXyo1j0OTGjA@mail.gmail.com>
To: Julian Reschke <julian.reschke@gmx.de>
Cc: HTTP Working Group <ietf-http-wg@w3.org>
Yes, I think this could be helpful.

I adopted a similar pattern for some internal work a while back that
addressed this problem[1]:

In a nutshell, I added this to options:

-- Typical call to OPTIONS for this URL
REQUEST: **************
OPTIONS /xcs/ugdata/ HTTP/1.1
content-type:text/plain
Host: localhost
Accept: */*

RESPONSE: **************
HTTP/1.1 200 OK
Allow: DELETE,GET,HEAD,OPTIONS,POST,PUT
X-Accept-Types: text/html,text/xml,application/json
X-Content-Types: text/xml,application/x-www-form-urlencoded,application/json

In the running implementation I created, this kind of information is
also returned for 405, 406, and 415

And, yes, the "X-" is earns a sad face<g>.


[1] http://www.amundsen.com/blog/archives/716

mca
http://amundsen.com/blog/
http://twitter.com@mamund
http://mamund.com/foaf.rdf#me




On Mon, Dec 12, 2011 at 16:21, Julian Reschke <julian.reschke@gmx.de> wrote:
>
> Hi there,
>
> see
>
>
> <http://stackoverflow.com/questions/3343165/specify-supported-media-types-when-sending-415-unsupported-media-type>
>
> Should we specify what it means to return an Accept header field in an HTTP *response*?
>
> Best regards, Julian
>
Received on Tuesday, 13 December 2011 01:58:54 UTC

This archive was generated by hypermail 2.4.0 : Thursday, 2 February 2023 18:43:26 UTC