constant-list
Version:
Provide a constant list definition for the most common use case (http, file extension, mime, js type, ...)
94 lines (88 loc) • 2.77 kB
JavaScript
/**
* INFORMATION
*/
module.exports.CONTINUE = 100;
module.exports.SWITCHING_PROTOCOL = 101;
module.exports.PROCESSING = 102;
/**
* Success
*/
module.exports.OK = 200;
module.exports.CREATED = 201;
module.exports.ACCEPTED = 202;
module.exports.NON_AUTHORATIVE = 203;
module.exports.NO_CONTENT = 204;
module.exports.RESET_CONTENT = 205;
module.exports.PARTIAL_CONTENT = 206;
module.exports.MULTI_STATUS = 207;
module.exports.CONTENT_DIFFERENT = 210;
module.exports.IM_USED = 226;
/**
* Redirection
*/
module.exports.MULTIPLE_CHOICES = 300;
module.exports.MOVED_PERMANENTLY = 301;
module.exports.MOVED_TEMPORARILY = 302;
module.exports.SEE_OTHER = 303;
module.exports.NOT_MODIFIED = 304;
module.exports.USE_PROXY = 305;
module.exports.TEMPORARY_REDIRECT = 307;
module.exports.PERMANENT_REDIRECT = 308;
module.exports.TOO_MANY_REDIRECT = 310;
/**
* Error client
*/
module.exports.BAD_REQUEST = 400;
module.exports.UNAUTHORIZED = 401;
module.exports.PAYMENT_REQUIRED = 402;
module.exports.FORBIDDEN = 403;
module.exports.NOT_FOUND = 404;
module.exports.METHOD_NOT_ALLOWED = 405;
module.exports.NOT_ACCEPTABLE = 406;
module.exports.PROXY_AUTH_REQUIRED = 407;
module.exports.REQUEST_TIME_OUT = 408;
module.exports.CONFLICT = 409;
module.exports.GONE = 410;
module.exports.LENGTH_REQUIRED = 411;
module.exports.PRECONDITION_FAILED = 412;
module.exports.REQUEST_ENTITY_TOO_LARGE = 413;
module.exports.REQUEST_URI_TOO_LONG = 414;
module.exports.UNSUPPORTED_MEDIA = 415;
module.exports.REQUESTED_RANGE_UNSATISFIABLE = 416;
module.exports.EXPECTATION_FAILIED = 417;
module.exports.IM_A_TEAPOT = 418;
module.exports.UNPROCESSABLE_ENTITY = 422;
module.exports.LOCKED = 423;
module.exports.METHOD_FAILURE = 424;
module.exports.UNORDERED_COLLECTION = 425;
module.exports.UPGRADE_REQUIRED = 426;
module.exports.TOO_MANY_REQUESTS = 429;
module.exports.REQUEST_HEADER_TOO_LARGE = 431;
module.exports.RETRY_WITH = 449;
module.exports.BLOCKED_BY_PARENTAL_CONTROL = 450;
module.exports.LEGAL_REASON = 451;
module.exports.UNRECOVERABLE_ERROR = 456;
module.exports.CLIENT_CLOSED_CONNECTION = 499;
/**
* Error server
*/
module.exports.INTERNAL_ERROR = 500;
module.exports.NOT_IMPLEMENTED = 501;
module.exports.BAD_GATEWAY = 502;
module.exports.SERVICE_UNAVAILABLE = 503;
module.exports.GATEWAY_TIMEOUT = 504;
module.exports.VERSION_NOT_SUPPORTED = 505;
module.exports.VARIANT_ALSO_NEGOCIATE = 506;
module.exports.INSUFFICIENT_STORAGE = 507;
module.exports.LOOP_DETECTED = 508;
module.exports.BANDWIDTH_LIMIT_EXCEEDED = 509;
module.exports.NOT_EXTENDED = 510;
module.exports.NETWORK_AUTHENTICATION_REQUIRED = 511;
module.exports.UNKNOWN_ERROR = 520;
/**
* METHOD
*/
module.exports.POST = 'post';
module.exports.GET = 'get';
module.exports.PUT = 'put';
module.exports.DELETE = 'del';