HTTP 状态字

HTTP回包的状态字由一个三位数的整型表示。

状态字的类型

第一位数字用于识别该状态字的大体类型
一共有1-5 五种

状态码意义说明
1xx信息(Informational)请求已经收到,正在处理
2xx成功(Success)当前的操作已经成功
3xx重定向(Redirection)未完成请求,需要跳转到其他操作
4xx客户端错误(Client Error)请求可能包含错误的语法,或者请求不能被满足
5xx服务器错误(Server Error)请求合法,但服务器出现了错误

具体状态码

状态码意义
100Continue
101Switching Protocols
200OK
202Accepted
203Non-Authoritative Information
204No Content
205Reset Content
206Partial Content
300Multiple Choices
301Moved Permanently
302Found
303See Other
304Not Modified
305Use Proxy
307Temporary Redirect
400Bad Request
402Payment Required
403Forbidden
404Not Found
405Method Not Allowed
406Not Acceptable
407Proxy Authentication Required
408Request Time-out
409Conflict
410Gone
411Length Required
412Precondition Failed
413Request Entity Too Large
414Request-URI Too Large
415Unsupported Media Type
416Requested range not satisfiable
417Expectation Failed
500Internal Server Error
501Not Implemented
502Bad Gateway
503Service Unavailable
504Gateway Time-out
505HTTP Version not supported

版权声明:本文为u013230511原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。