Peregrine.Response
- Package
- purescript-peregrine
- Repository
- maxdeviant/peregrine
#fromStatus Source
fromStatus :: Status -> Response
Constructs a response from the specified HTTP status, using the status' reason phrase as the response body.
#withHeaders Source
withHeaders :: Headers -> Response -> Response
Sets the response headers, overwriting any existing headers.
#addHeader Source
addHeader :: HeaderName -> HeaderValue -> Response -> Response
Adds a header to the response.
If the response already contains a header with the specified name it will be overwritten.
#switchingProtocols Source
switchingProtocols :: Response
Returns a 101 Switching Protocols
response with the reason phrase in the body.
#processing Source
processing :: Response
Returns a 102 Processing
response with the reason phrase in the body.
#nonAuthoritativeInformation Source
nonAuthoritativeInformation :: Response
Returns a 203 Non-Authoritative Information
response with the reason phrase in the body.
#resetContent Source
resetContent :: Response
Returns a 205 Reset Content
response with the reason phrase in the body.
#partialContent Source
partialContent :: Response
Returns a 206 Partial Content
response with the reason phrase in the body.
#multiStatus Source
multiStatus :: Response
Returns a 207 Multi-Status
response with the reason phrase in the body.
#alreadyReported Source
alreadyReported :: Response
Returns a 208 Already Reported
response with the reason phrase in the body.
#multipleChoices Source
multipleChoices :: Response
Returns a 300 Multiple Choices
response with the reason phrase in the body.
#movedPermanently Source
movedPermanently :: Response
Returns a 301 Moved Permanently
response with the reason phrase in the body.
#notModified Source
notModified :: Response
Returns a 304 Not Modified
response with the reason phrase in the body.
#temporaryRedirect Source
temporaryRedirect :: Response
Returns a 307 Temporary Redirect
response with the reason phrase in the body.
#permanentRedirect Source
permanentRedirect :: Response
Returns a 308 Permanent Redirect
response with the reason phrase in the body.
#badRequest Source
badRequest :: Response
Returns a 400 Bad Request
response with the reason phrase in the body.
#unauthorized Source
unauthorized :: Response
Returns a 401 Unauthorized
response with the reason phrase in the body.
#paymentRequired Source
paymentRequired :: Response
Returns a 402 Payment Required
response with the reason phrase in the body.
#methodNotAllowed Source
methodNotAllowed :: Response
Returns a 405 Method Not Allowed
response with the reason phrase in the body.
#notAcceptable Source
notAcceptable :: Response
Returns a 406 Not Acceptable
response with the reason phrase in the body.
#proxyAuthenticationRequired Source
proxyAuthenticationRequired :: Response
Returns a 407 Proxy Authentication Required
response with the reason phrase in the body.
#requestTimeout Source
requestTimeout :: Response
Returns a 408 Request Timeout
response with the reason phrase in the body.
#lengthRequired Source
lengthRequired :: Response
Returns a 411 Length Required
response with the reason phrase in the body.
#preconditionFailed Source
preconditionFailed :: Response
Returns a 412 Precondition Failed
response with the reason phrase in the body.
#payloadTooLarge Source
payloadTooLarge :: Response
Returns a 413 Payload Too Large
response with the reason phrase in the body.
#uriTooLong Source
uriTooLong :: Response
Returns a 414 URI Too Long
response with the reason phrase in the body.
#unsupportedMediaType Source
unsupportedMediaType :: Response
Returns a 415 Unsupported Media Type
response with the reason phrase in the body.
#rangeNotSatisfiable Source
rangeNotSatisfiable :: Response
Returns a 416 Range Not Satisfiable
response with the reason phrase in the body.
#expectationFailed Source
expectationFailed :: Response
Returns a 417 Expectation Failed
response with the reason phrase in the body.
#misdirectedRequest Source
misdirectedRequest :: Response
Returns a 421 Misdirected Request
response with the reason phrase in the body.
#unprocessableEntity Source
unprocessableEntity :: Response
Returns a 422 Unprocessable Entity
response with the reason phrase in the body.
#failedDependency Source
failedDependency :: Response
Returns a 424 Failed Dependency
response with the reason phrase in the body.
#upgradeRequired Source
upgradeRequired :: Response
Returns a 426 Upgrade Required
response with the reason phrase in the body.
#preconditionRequired Source
preconditionRequired :: Response
Returns a 428 Precondition Required
response with the reason phrase in the body.
#tooManyRequests Source
tooManyRequests :: Response
Returns a 429 Too Many Requests
response with the reason phrase in the body.
#requestHeaderFieldsTooLarge Source
requestHeaderFieldsTooLarge :: Response
Returns a 431 Request Header Fields Too Large
response with the reason phrase in the body.
#internalServerError Source
internalServerError :: Response
Returns a 500 Internal Server Error
response with the reason phrase in the body.
#notImplemented Source
notImplemented :: Response
Returns a 501 Not Implemented
response with the reason phrase in the body.
#badGateway Source
badGateway :: Response
Returns a 502 Bad Gateway
response with the reason phrase in the body.
#gatewayTimeout Source
gatewayTimeout :: Response
Returns a 504 Gateway Timeout
response with the reason phrase in the body.
#httpVersionNotSupported Source
httpVersionNotSupported :: Response
Returns a 505 HTTP Version Not Supported
response with the reason phrase in the body.
#variantAlsoNegotiates Source
variantAlsoNegotiates :: Response
Returns a 506 Variant Also Negotiates
response with the reason phrase in the body.
#insufficientStorage Source
insufficientStorage :: Response
Returns a 507 Insufficient Storage
response with the reason phrase in the body.
#loopDetected Source
loopDetected :: Response
Returns a 508 Loop Detected
response with the reason phrase in the body.
#notExtended Source
notExtended :: Response
Returns a 510 Not Extended
response with the reason phrase in the body.
#networkAuthenticationRequired Source
networkAuthenticationRequired :: Response
Returns a 511 Network Authentication Required
response with the reason phrase in the body.