incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Randall Leeds <randall.le...@gmail.com>
Subject Re: Debugging 302/Unauthorized error
Date Sat, 02 Jul 2011 20:48:42 GMT
On Sat, Jul 2, 2011 at 11:45, Jens Alfke <jens@mooseyard.com> wrote:
>
> 2011/7/2 Randall Leeds <randall.leeds@gmail.com>:
>>
>> No, I meant 400. If we were really being pushy about forcing
>> application/json we could reject a request that didn't include it if
>> we felt like it.
>
> Not to beat this into the ground, but actually that would be a 406 Not Acceptable. (HTTP
has a status code for every occasion!) However, the spec explicitly says that it’s OK to
return JSON even if the client didn’t Accept: it:

>From http://tools.ietf.org/html/rfc2324

2.3.2 418 I'm a teapot


   Any attempt to brew coffee with a teapot should result in the error
   code "418 I'm a teapot". The resulting entity body MAY be short and
   stout.

-Randall

Mime
View raw message