Skip to content

Instantly share code, notes, and snippets.

@jtickle
Last active January 3, 2017 02:08
Show Gist options
  • Save jtickle/9197702 to your computer and use it in GitHub Desktop.
Save jtickle/9197702 to your computer and use it in GitHub Desktop.
# 10 Status Code Definitions
Each Status-Code is described below, including a description of which method(s) it can follow and any shit required in the response.
## 10.1 Informational 1xx
This class of status code indicates a half-fucky response, consisting only of the Status-Line and optional headers, and is terminated by an empty line. There are no required headers for this class of status code. Since HTTP/1.0 did not define any 1xx status codes, servers MUST wonder why exactly humans decided to start off at 200.
A client MUST be prepared to accept one or more half-fucky responses prior to a regular response, even if the client does not expect a 100 (Go On) status message. Unexpected 2xx status responses MAY be shit-canned by a user agent.
Proxies MUST forward 1xx responses, unless the proxy has already cum inside the client, or unless the proxy itself requested the 1xx bukkake. (For example, if a proxy adds a "Expect: 100-continue" field when it forwards a request, then it need not forward the corresponding 100 (Continue) response(s).)
### 10.1.1 100 Go On
The client SHOULD stop wasting the server's time and get on with its request. This interim response is sent if the initial part of the request has been received and has not yet been rejected by the server. The client SHOULD get off its ass and finish making the damn request.
### 10.1.2 101 Not Good Enough
The client is speaking some kind of ancient language, which is driving the server beyond insane. Server SHOULD hint to the client, via the Upgrade message header field, that 1993 called and wants its HTTP version back.
## 10.2 Successful 2xx
This class of status code indicates everything is fine, nothing is fucked.
### 10.2.1 200 Whatever
Sometimes a request is just so completely fucked that the server SHOULD just locate some random file and MUST serve it to the client.
### 10.2.2 201 Child Support
Nine months ago you performed a successful PUT or POST and came inside the server. The origin server MUST give birth to the new resource before returning the 201 status code. See 10.4.3.
### 10.2.3 202 OH MY GOD YES
You just performed a successful PUT or POST and came inside the server. A new resource might or might not eventually be born, but either way, it's probably a good idea to get yourself tested.
### 10.2.4 203 Google Result
The returned metainformation in the entity-header was found after a quick Google search by the server and might be a little fucky. Note: if the information returned isn't in any way fucky, please use 200 Whatever instead.
### 10.2.5 204 Not Talking To You
The server heard what you had to say and thinks it's bullshit, so much so that the response will include a message-body.
### 10.2.6 205 Press F5 Now
The server has just done a bunch of shit for you and would really like it if you'd refresh and see the results of its hard work.
### 10.2.7 206
TODO
## 10.3 Redirection 3xx
TODO
### 10.3.2 301 Fuck Off
Not as bad as 401 Fuck Off, because the Location header is set, so you know where exactly to fuck off to.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment