HTTPurple.Response
- Package
- purescript-httpurple
- Repository
- sigma-andex/purescript-httpurple
#Response Source
type Response = { headers :: ResponseHeaders, status :: Status, writeBody :: ServerResponse -> Aff Unit }
A Response
is a status code, headers, and a body.
#send Source
send :: forall m. MonadEffect m => MonadAff m => ServerResponse -> Response -> m Unit
Given an HTTP Response
and a HTTPurple Response
, this method will return
a monad encapsulating writing the HTTPurple Response
to the HTTP Response
and closing the HTTP Response
.
#emptyResponse Source
emptyResponse :: forall m. MonadAff m => Status -> m Response
The same as response
but without a body.
#emptyResponse' Source
emptyResponse' :: forall m. MonadAff m => Status -> ResponseHeaders -> m Response
The same as emptyResponse
but with headers.
#switchingProtocols Source
switchingProtocols :: forall m. MonadAff m => m Response
101
#switchingProtocols' Source
switchingProtocols' :: forall m. MonadAff m => ResponseHeaders -> m Response
101 with headers
#processing Source
processing :: forall m. MonadAff m => m Response
102
#processing' Source
processing' :: forall m. MonadAff m => ResponseHeaders -> m Response
102 with headers
#ok' Source
ok' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
200 with headers
#nonAuthoritativeInformation Source
nonAuthoritativeInformation :: forall m b. MonadAff m => Body b => b -> m Response
203
#nonAuthoritativeInformation' Source
nonAuthoritativeInformation' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
203 with headers
#noContent' Source
noContent' :: forall m. MonadAff m => ResponseHeaders -> m Response
204 with headers
#resetContent Source
resetContent :: forall m. MonadAff m => m Response
205
#resetContent' Source
resetContent' :: forall m. MonadAff m => ResponseHeaders -> m Response
205 with headers
#partialContent' Source
partialContent' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
206 with headers
#multiStatus' Source
multiStatus' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
207 with headers
#alreadyReported Source
alreadyReported :: forall m. MonadAff m => m Response
208
#alreadyReported' Source
alreadyReported' :: forall m. MonadAff m => ResponseHeaders -> m Response
208 with headers
#iMUsed' Source
iMUsed' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
226 with headers
#multipleChoices' Source
multipleChoices' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
300 with headers
#movedPermanently' Source
movedPermanently' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
301 with headers
#found' Source
found' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
302 with headers
#seeOther' Source
seeOther' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
303 with headers
#notModified Source
notModified :: forall m. MonadAff m => m Response
304
#notModified' Source
notModified' :: forall m. MonadAff m => ResponseHeaders -> m Response
304 with headers
#useProxy' Source
useProxy' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
305 with headers
#temporaryRedirect Source
temporaryRedirect :: forall m b. MonadAff m => Body b => b -> m Response
307
#temporaryRedirect' Source
temporaryRedirect' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
307 with headers
#permanentRedirect Source
permanentRedirect :: forall m b. MonadAff m => Body b => b -> m Response
308
#permanentRedirect' Source
permanentRedirect' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
308 with headers
#badRequest' Source
badRequest' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
400 with headers
#unauthorized Source
unauthorized :: forall m. MonadAff m => m Response
401
#unauthorized' Source
unauthorized' :: forall m. MonadAff m => ResponseHeaders -> m Response
401 with headers
#paymentRequired Source
paymentRequired :: forall m. MonadAff m => m Response
402
#paymentRequired' Source
paymentRequired' :: forall m. MonadAff m => ResponseHeaders -> m Response
402 with headers
#forbidden' Source
forbidden' :: forall m. MonadAff m => ResponseHeaders -> m Response
403 with headers
#methodNotAllowed Source
methodNotAllowed :: forall m. MonadAff m => m Response
405
#methodNotAllowed' Source
methodNotAllowed' :: forall m. MonadAff m => ResponseHeaders -> m Response
405 with headers
#notAcceptable Source
notAcceptable :: forall m. MonadAff m => m Response
406
#notAcceptable' Source
notAcceptable' :: forall m. MonadAff m => ResponseHeaders -> m Response
406 with headers
#proxyAuthenticationRequired Source
proxyAuthenticationRequired :: forall m. MonadAff m => m Response
407
#proxyAuthenticationRequired' Source
proxyAuthenticationRequired' :: forall m. MonadAff m => ResponseHeaders -> m Response
407 with headers
#requestTimeout Source
requestTimeout :: forall m. MonadAff m => m Response
408
#requestTimeout' Source
requestTimeout' :: forall m. MonadAff m => ResponseHeaders -> m Response
408 with headers
#conflict' Source
conflict' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
409 with headers
#lengthRequired Source
lengthRequired :: forall m. MonadAff m => m Response
411
#lengthRequired' Source
lengthRequired' :: forall m. MonadAff m => ResponseHeaders -> m Response
411 with headers
#preconditionFailed Source
preconditionFailed :: forall m. MonadAff m => m Response
412
#preconditionFailed' Source
preconditionFailed' :: forall m. MonadAff m => ResponseHeaders -> m Response
412 with headers
#payloadTooLarge Source
payloadTooLarge :: forall m. MonadAff m => m Response
413
#payloadTooLarge' Source
payloadTooLarge' :: forall m. MonadAff m => ResponseHeaders -> m Response
413 with headers
#uRITooLong Source
uRITooLong :: forall m. MonadAff m => m Response
414
#uRITooLong' Source
uRITooLong' :: forall m. MonadAff m => ResponseHeaders -> m Response
414 with headers
#unsupportedMediaType Source
unsupportedMediaType :: forall m. MonadAff m => m Response
415
#unsupportedMediaType' Source
unsupportedMediaType' :: forall m. MonadAff m => ResponseHeaders -> m Response
415 with headers
#rangeNotSatisfiable Source
rangeNotSatisfiable :: forall m. MonadAff m => m Response
416
#rangeNotSatisfiable' Source
rangeNotSatisfiable' :: forall m. MonadAff m => ResponseHeaders -> m Response
416 with headers
#expectationFailed Source
expectationFailed :: forall m. MonadAff m => m Response
417
#expectationFailed' Source
expectationFailed' :: forall m. MonadAff m => ResponseHeaders -> m Response
417 with headers
#imATeapot' Source
imATeapot' :: forall m. MonadAff m => ResponseHeaders -> m Response
418 with headers
#misdirectedRequest Source
misdirectedRequest :: forall m. MonadAff m => m Response
421
#misdirectedRequest' Source
misdirectedRequest' :: forall m. MonadAff m => ResponseHeaders -> m Response
421 with headers
#unprocessableEntity Source
unprocessableEntity :: forall m. MonadAff m => m Response
422
#unprocessableEntity' Source
unprocessableEntity' :: forall m. MonadAff m => ResponseHeaders -> m Response
422 with headers
#failedDependency Source
failedDependency :: forall m. MonadAff m => m Response
424
#failedDependency' Source
failedDependency' :: forall m. MonadAff m => ResponseHeaders -> m Response
424 with headers
#upgradeRequired Source
upgradeRequired :: forall m. MonadAff m => m Response
426
#upgradeRequired' Source
upgradeRequired' :: forall m. MonadAff m => ResponseHeaders -> m Response
426 with headers
#preconditionRequired Source
preconditionRequired :: forall m. MonadAff m => m Response
428
#preconditionRequired' Source
preconditionRequired' :: forall m. MonadAff m => ResponseHeaders -> m Response
428 with headers
#tooManyRequests Source
tooManyRequests :: forall m. MonadAff m => m Response
429
#tooManyRequests' Source
tooManyRequests' :: forall m. MonadAff m => ResponseHeaders -> m Response
429 with headers
#requestHeaderFieldsTooLarge Source
requestHeaderFieldsTooLarge :: forall m. MonadAff m => m Response
431
#requestHeaderFieldsTooLarge' Source
requestHeaderFieldsTooLarge' :: forall m. MonadAff m => ResponseHeaders -> m Response
431 with headers
#internalServerError Source
internalServerError :: forall m b. MonadAff m => Body b => b -> m Response
500
#internalServerError' Source
internalServerError' :: forall m b. MonadAff m => Body b => ResponseHeaders -> b -> m Response
500 with headers
#notImplemented Source
notImplemented :: forall m. MonadAff m => m Response
501
#notImplemented' Source
notImplemented' :: forall m. MonadAff m => ResponseHeaders -> m Response
501 with headers
#badGateway Source
badGateway :: forall m. MonadAff m => m Response
502
#badGateway' Source
badGateway' :: forall m. MonadAff m => ResponseHeaders -> m Response
502 with headers
#gatewayTimeout Source
gatewayTimeout :: forall m. MonadAff m => m Response
504
#gatewayTimeout' Source
gatewayTimeout' :: forall m. MonadAff m => ResponseHeaders -> m Response
504 with headers
#hTTPVersionNotSupported Source
hTTPVersionNotSupported :: forall m. MonadAff m => m Response
505
#hTTPVersionNotSupported' Source
hTTPVersionNotSupported' :: forall m. MonadAff m => ResponseHeaders -> m Response
505 with headers
#variantAlsoNegotiates Source
variantAlsoNegotiates :: forall m. MonadAff m => m Response
506
#variantAlsoNegotiates' Source
variantAlsoNegotiates' :: forall m. MonadAff m => ResponseHeaders -> m Response
506 with headers
#insufficientStorage Source
insufficientStorage :: forall m. MonadAff m => m Response
507
#insufficientStorage' Source
insufficientStorage' :: forall m. MonadAff m => ResponseHeaders -> m Response
507 with headers
#loopDetected Source
loopDetected :: forall m. MonadAff m => m Response
508
#loopDetected' Source
loopDetected' :: forall m. MonadAff m => ResponseHeaders -> m Response
508 with headers
#notExtended Source
notExtended :: forall m. MonadAff m => m Response
510
#notExtended' Source
notExtended' :: forall m. MonadAff m => ResponseHeaders -> m Response
510 with headers
#networkAuthenticationRequired Source
networkAuthenticationRequired :: forall m. MonadAff m => m Response
511
#networkAuthenticationRequired' Source
networkAuthenticationRequired' :: forall m. MonadAff m => ResponseHeaders -> m Response
511 with headers
- Modules
- HTTPurple
- HTTPurple.
Body - HTTPurple.
Cont - HTTPurple.
Headers - HTTPurple.
Json - HTTPurple.
Lookup - HTTPurple.
Method - HTTPurple.
Middleware - HTTPurple.
NodeMiddleware - HTTPurple.
Path - HTTPurple.
Query - HTTPurple.
Request - HTTPurple.
Response - HTTPurple.
Routes - HTTPurple.
Server - HTTPurple.
Status - HTTPurple.
Utils - HTTPurple.
Validation - HTTPurple.
Version