Re: #303: Generic semantics for the 400 status code (also #302)

I'm not hearing any pushback on this, so assigning for -16.


On 17/07/2011, at 10:54 AM, Mark Nottingham wrote:

> On 15/07/2011, at 10:53 PM, Mark Nottingham wrote:
> 
>> When people have error states that don't cleanly fit into an existing status code, they're often encouraged to use 400 or 500, depending on whether the client or server were at fault, as they're the most "generic" status codes.
>> 
>> 500's definition fits this:
>> 
>>> 8.5.1.  500 Internal Server Error
>>> 
>>>  The server encountered an unexpected condition which prevented it
>>>  from fulfilling the request.
>> 
>> However, 400 is much more specific:
>> 
>>> 8.4.1.  400 Bad Request
>>> 
>>>  The request could not be understood by the server due to malformed
>>>  syntax.  The client SHOULD NOT repeat the request without
>>>  modifications.
>> 
>> I think the 400 definition needs to be broadened, so that people don't invent their own status codes, or misuse existing ones.
>> 
>> E.g.,
>> 
>> """
>> The server can or will not process the request, due to a client error (e.g., malformed syntax).
>> """
> 
> This was logged as <http://trac.tools.ietf.org/wg/httpbis/trac/ticket/303>.

--
Mark Nottingham   http://www.mnot.net/

Received on Tuesday, 19 July 2011 13:02:25 UTC