QHTTPStatus
@quik/core / QHTTPStatus
Enumeration: QHTTPStatus
Defined in: enums/QHTTPStatus.ts:15
A list with the supported HTTP Status codes that can be used in the application.
Statuses starting with 2 (200, 201, 202, 204 etc.) are usually sent when you want to show a successful response.
Statuses starting with 4 (400, 401, 403 etc.) are usually sent when you want to show that the response has failed, based on the input received from the user.
Statuses starting with 5 (500, 501, 503 etc.) are usually sent when you or the server want to show that something failed.
Enumeration Members
ACCEPTED
ACCEPTED:
202
Defined in: enums/QHTTPStatus.ts:34
ACCEPTED HTTP Status Code
This status code should be used when you accept a request and do some asynchronous backend processing.
ALMOST_THERE
ALMOST_THERE:
419
Defined in: enums/QHTTPStatus.ts:97
ALMOST 4.20 HTTP Status Code
Easter egg HTTP Status
BAD_GATEWAY
BAD_GATEWAY:
502
Defined in: enums/QHTTPStatus.ts:125
BAD GATEWAY HTTP Status Code
This status code should be used when the gateway cannot connect to a child (proxy) server.
BAD_REQUEST
BAD_REQUEST:
400
Defined in: enums/QHTTPStatus.ts:61
BAD REQUEST HTTP Status Code
This status code should be used when you want to return an error triggered by the data sent by the user.
CREATED
CREATED:
201
Defined in: enums/QHTTPStatus.ts:28
CREATED HTTP Status Code
This status code should be used when you want to create a new item in your application.
FORBIDDEN
FORBIDDEN:
403
Defined in: enums/QHTTPStatus.ts:73
FORBIDDEN HTTP Status Code
This status code should be used when the user doesn't have permission to access an endpoint.
GATEWAY_UNAVAILABLE
GATEWAY_UNAVAILABLE:
504
Defined in: enums/QHTTPStatus.ts:138
GATEWAY UNAVAILABLE HTTP Status Code
This status code should be used when the gateway is unavailable.
GONE
GONE:
410
Defined in: enums/QHTTPStatus.ts:85
GONE HTTP Status Code
This status code should be used when the endpoint accessed by the user was deleted.
KEEP_CALM
KEEP_CALM:
420
Defined in: enums/QHTTPStatus.ts:103
KEEP CALM HTTP Status Code
Easter egg HTTP Status
MOVED_PERMANENTLY
MOVED_PERMANENTLY:
301
Defined in: enums/QHTTPStatus.ts:48
MOVED PERMANENTLY HTTP Status Code
This status code should be used when the endpoint your user wants to access has moved to a new location permanently.
NO_CONTENT
NO_CONTENT:
204
Defined in: enums/QHTTPStatus.ts:41
NO CONTENT HTTP Status Code
This status code should be used when you don't return anything to the user, but the processing was done successfully. For example, when you delete a record, you can use this status code.
NOT_FOUND
NOT_FOUND:
404
Defined in: enums/QHTTPStatus.ts:79
NOT FOUND HTTP Status Code
This status code should be used when the endpoint accessed by the user doesn't exist.
OK
OK:
200
Defined in: enums/QHTTPStatus.ts:22
OK HTTP Status Code
This status code should be used when you want to return a successful response. It is automatically used when you don't specify any status code.
REDIRECT
REDIRECT:
302
Defined in: enums/QHTTPStatus.ts:54
REDIRECT HTTP Status Code
This status code should be used when the endpoint your user wants to access has moved temporary to a new location.
SERVER_ERROR
SERVER_ERROR:
500
Defined in: enums/QHTTPStatus.ts:119
SERVER ERROR HTTP Status Code
This status code should be used when the server encountered an error, not triggered by the user input. This status is used by default when a server error occurred.
SERVER_UNAVAILABLE
SERVER_UNAVAILABLE:
503
Defined in: enums/QHTTPStatus.ts:132
SERVER UNAVAILABLE HTTP Status Code
This status code should be returned when the server is unavailable to handle a request. This status code is used by default when your code execution takes more than the set timeout period.
TEAPOT
TEAPOT:
418
Defined in: enums/QHTTPStatus.ts:91
I'M A TEAPOT HTTP Status Code
Easter egg HTTP Status
TOO_MANY_REQUESTS
TOO_MANY_REQUESTS:
429
Defined in: enums/QHTTPStatus.ts:111
TOO MANY REQUESTS HTTP Status Code
This status code should be returned when the client has exceeded the allowed request rate for an endpoint.
UNAUTHORIZED
UNAUTHORIZED:
401
Defined in: enums/QHTTPStatus.ts:67
UNAUTHORIZED HTTP Status Code
This status code should be used when the user is unauthorized to access an endpoint.
UNPROCESSABLE_ENTITY
UNPROCESSABLE_ENTITY:
422
Defined in: enums/QHTTPStatus.ts:104