@emoyly/problem 7.0.6 → 8.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/README.md +1 -1
  2. package/cjs/defaults/4xx.d.ts +144 -144
  3. package/cjs/defaults/5xx.d.ts +54 -54
  4. package/cjs/defaults/aws.d.ts +8 -8
  5. package/cjs/defaults/cloudflare.d.ts +44 -44
  6. package/cjs/defaults/iis.d.ts +12 -12
  7. package/cjs/defaults/nginx.d.ts +24 -24
  8. package/cjs/defaults/others.d.ts +28 -28
  9. package/cjs/middleware/axios.js +1 -1
  10. package/cjs/middleware/base.d.ts +1 -1
  11. package/cjs/middleware/base.js +4 -4
  12. package/cjs/middleware/express.js +10 -28
  13. package/cjs/parsers/axios.js +9 -8
  14. package/cjs/parsers/jsonwebtoken.js +3 -0
  15. package/cjs/parsers/mikroorm.js +1 -0
  16. package/cjs/parsers/tsoa.js +3 -2
  17. package/cjs/parsers/zod.js +2 -1
  18. package/cjs/problem.d.ts +7 -7
  19. package/cjs/problem.js +41 -32
  20. package/cjs/tsconfig.tsbuildinfo +1 -1
  21. package/cjs/typings/codes.d.ts +2 -2
  22. package/cjs/typings/problem.d.ts +13 -2
  23. package/cjs/util/getProblems.d.ts +4 -4
  24. package/cjs/util/getProblems.js +18 -15
  25. package/cjs/util/index.d.ts +1 -1
  26. package/cjs/util/index.js +1 -1
  27. package/cjs/util/misc.d.ts +2 -2
  28. package/cjs/util/misc.js +3 -4
  29. package/cjs/util/validation.d.ts +5 -0
  30. package/cjs/util/validation.js +38 -0
  31. package/cjs/util/version.d.ts +1 -2
  32. package/cjs/util/version.js +1 -16
  33. package/esm/defaults/4xx.d.ts +144 -144
  34. package/esm/defaults/5xx.d.ts +54 -54
  35. package/esm/defaults/aws.d.ts +8 -8
  36. package/esm/defaults/cloudflare.d.ts +44 -44
  37. package/esm/defaults/iis.d.ts +12 -12
  38. package/esm/defaults/nginx.d.ts +24 -24
  39. package/esm/defaults/others.d.ts +28 -28
  40. package/esm/middleware/axios.js +1 -1
  41. package/esm/middleware/base.d.ts +1 -1
  42. package/esm/middleware/base.js +4 -4
  43. package/esm/middleware/express.js +11 -29
  44. package/esm/parsers/axios.js +9 -8
  45. package/esm/parsers/jsonwebtoken.js +3 -0
  46. package/esm/parsers/mikroorm.js +1 -0
  47. package/esm/parsers/tsoa.js +3 -2
  48. package/esm/parsers/zod.js +2 -1
  49. package/esm/problem.d.ts +7 -7
  50. package/esm/problem.js +41 -32
  51. package/esm/tsconfig.tsbuildinfo +1 -1
  52. package/esm/typings/codes.d.ts +2 -2
  53. package/esm/typings/problem.d.ts +13 -2
  54. package/esm/util/getProblems.d.ts +4 -4
  55. package/esm/util/getProblems.js +18 -15
  56. package/esm/util/index.d.ts +1 -1
  57. package/esm/util/index.js +1 -1
  58. package/esm/util/misc.d.ts +2 -2
  59. package/esm/util/misc.js +2 -3
  60. package/esm/util/validation.d.ts +5 -0
  61. package/esm/util/validation.js +33 -0
  62. package/esm/util/version.d.ts +1 -2
  63. package/esm/util/version.js +1 -15
  64. package/package.json +18 -13
  65. package/tsconfig.json +5 -1
  66. package/.editorconfig +0 -11
  67. package/.vscode/extensions.json +0 -7
  68. package/.vscode/settings.json +0 -2
  69. package/cjs/util/defaults.d.ts +0 -4
  70. package/cjs/util/defaults.js +0 -7
  71. package/esm/util/defaults.d.ts +0 -4
  72. package/esm/util/defaults.js +0 -4
  73. package/scripts/ensureCorrectVersion.js +0 -20
  74. package/src/defaults/4xx.ts +0 -149
  75. package/src/defaults/5xx.ts +0 -59
  76. package/src/defaults/aws.ts +0 -14
  77. package/src/defaults/cloudflare.ts +0 -50
  78. package/src/defaults/iis.ts +0 -19
  79. package/src/defaults/index.ts +0 -7
  80. package/src/defaults/nginx.ts +0 -34
  81. package/src/defaults/others.ts +0 -37
  82. package/src/index.ts +0 -4
  83. package/src/middleware/axios.ts +0 -28
  84. package/src/middleware/base.ts +0 -78
  85. package/src/middleware/express.ts +0 -71
  86. package/src/parsers/axios.ts +0 -60
  87. package/src/parsers/jsonwebtoken.ts +0 -107
  88. package/src/parsers/mikroorm.ts +0 -21
  89. package/src/parsers/tsoa.ts +0 -26
  90. package/src/parsers/zod.ts +0 -23
  91. package/src/problem.ts +0 -56
  92. package/src/typings/codes.ts +0 -6
  93. package/src/typings/index.ts +0 -4
  94. package/src/typings/middleware.ts +0 -14
  95. package/src/typings/parser.ts +0 -3
  96. package/src/typings/problem.ts +0 -27
  97. package/src/util/defaults.ts +0 -4
  98. package/src/util/getProblems.ts +0 -56
  99. package/src/util/index.ts +0 -4
  100. package/src/util/misc.ts +0 -21
  101. package/src/util/problemArray.ts +0 -21
  102. package/src/util/version.ts +0 -16
@@ -5,26 +5,29 @@ exports.createFromJson = createFromJson;
5
5
  exports.getProblems = getProblems;
6
6
  const problem_js_1 = require("../problem.js");
7
7
  const problemArray_js_1 = require("./problemArray.js");
8
- const version_js_1 = require("./version.js");
9
- const strings = ['title', 'type', 'instance', 'detail', '__problemVersion'];
8
+ const validation_js_1 = require("./validation.js");
10
9
  function isJsonProblem(input) {
11
- if (input === null)
12
- return false;
13
- if (typeof input !== 'object')
14
- return false;
15
- if (!strings.every(val => val in input && typeof input[val] === 'string'))
16
- return false;
17
- if (!(0, version_js_1.isCompatibleVersion)(('__problemVersion' in input && typeof input['__problemVersion'] === 'string') ? input['__problemVersion'] : ''))
18
- return false;
19
- if (!('status' in input) || typeof input.status !== 'number')
20
- return false;
21
- return true;
10
+ return (0, validation_js_1.validateBasicInput)(input) === true;
22
11
  }
23
- function createFromJson({ title, type, instance, detail, status, data }) {
12
+ function createFromJson({ title, type, instance, detail, status, data: _data, ...extras }) {
13
+ let data;
14
+ const extraKeys = Object.keys(extras);
15
+ if /* No extras, just use data */ (extraKeys.length < 1) {
16
+ data = _data;
17
+ }
18
+ else if /* Extras but no data, just use extras */ ((_data === undefined || _data === null)) {
19
+ data = extras;
20
+ }
21
+ else if /* Data is not object we can merge with, and we do have extras */ (typeof _data !== 'object' || Array.isArray(_data) || Object.keys(_data).some(val => extraKeys.includes(val))) {
22
+ data = { original: _data, extras };
23
+ }
24
+ else {
25
+ data = { ...extras, ..._data };
26
+ }
24
27
  return new problem_js_1.Problem({ title, type, instance, detail, status, data });
25
28
  }
26
29
  /**
27
- * Get an array of Problems from a given input.
30
+ * Get an array of Problems from any given input.
28
31
  * Handles existing Problems, arrays of Problems, JSON Problems, JSON Problem arrays and optionally attempts to parse any input with the given parsers.
29
32
  * Only returns an array of Problems if it can successfully parse the input.
30
33
  */
@@ -1,4 +1,4 @@
1
1
  export * from './getProblems.js';
2
- export * from './defaults.js';
3
2
  export * from './problemArray.js';
4
3
  export * from './misc.js';
4
+ export * from './validation.js';
package/cjs/util/index.js CHANGED
@@ -15,6 +15,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./getProblems.js"), exports);
18
- __exportStar(require("./defaults.js"), exports);
19
18
  __exportStar(require("./problemArray.js"), exports);
20
19
  __exportStar(require("./misc.js"), exports);
20
+ __exportStar(require("./validation.js"), exports);
@@ -1,2 +1,2 @@
1
- import { ProblemOpts } from '../typings/index.js';
2
- export declare function getHttpError(statusCode: number | string): ProblemOpts | undefined;
1
+ import { CodeOpts } from '../typings/index.js';
2
+ export declare function getCodeDefaults(statusCode: number | string): CodeOpts | undefined;
package/cjs/util/misc.js CHANGED
@@ -1,10 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getHttpError = getHttpError;
3
+ exports.getCodeDefaults = getCodeDefaults;
4
4
  const allCodes = require("../defaults/index.js");
5
- function getHttpError(statusCode) {
5
+ function getCodeDefaults(statusCode) {
6
6
  for (const key in allCodes) {
7
- // This ensures all codes are written correctly as well, so that's a bonus
8
7
  const codeObject = allCodes[key];
9
8
  if (typeof statusCode === 'string') {
10
9
  const conv = Number(statusCode);
@@ -13,7 +12,7 @@ function getHttpError(statusCode) {
13
12
  }
14
13
  const code = codeObject[statusCode];
15
14
  if (!code)
16
- return;
15
+ continue;
17
16
  return code;
18
17
  }
19
18
  }
@@ -0,0 +1,5 @@
1
+ export declare class ProblemValidationError extends Error {
2
+ errors: string[];
3
+ constructor(errors: string[]);
4
+ }
5
+ export declare function validateBasicInput(input: unknown): true | ProblemValidationError;
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ProblemValidationError = void 0;
4
+ exports.validateBasicInput = validateBasicInput;
5
+ class ProblemValidationError extends Error {
6
+ errors;
7
+ constructor(errors) {
8
+ super(`Problem input is invalid:\n${errors.join('\n')}`);
9
+ this.errors = errors;
10
+ }
11
+ }
12
+ exports.ProblemValidationError = ProblemValidationError;
13
+ const requiredStrings = ['title', 'type'];
14
+ const optionalStrings = ['detail', '__problemVersion', 'instance', 'stack', 'source'];
15
+ function validateBasicInput(input) {
16
+ const errors = [];
17
+ if (input === null) {
18
+ errors.push('Input is null');
19
+ return new ProblemValidationError(errors);
20
+ }
21
+ if (typeof input !== 'object') {
22
+ errors.push('Input is not an object');
23
+ return new ProblemValidationError(errors);
24
+ }
25
+ const missingRequired = requiredStrings.filter(val => typeof input[val] !== 'string');
26
+ for (const miss of missingRequired) {
27
+ errors.push(`"${miss}" is missing or not a string`);
28
+ }
29
+ const wrongOptional = optionalStrings.filter((val) => val in input && input[val] !== undefined && input[val] !== null && typeof input[val] !== 'string');
30
+ for (const wrong of wrongOptional) {
31
+ errors.push(`"${wrong}" is set, and is not a string`);
32
+ }
33
+ if (!('status' in input) || typeof input.status !== 'number')
34
+ errors.push('Status is not a number');
35
+ if (errors.length > 0)
36
+ return new ProblemValidationError(errors);
37
+ return true;
38
+ }
@@ -1,3 +1,2 @@
1
- export declare const version = "7.0.6";
1
+ export declare const version = "8.0.0";
2
2
  export declare const major: number;
3
- export declare function isCompatibleVersion(inputVersion: string): boolean;
@@ -1,20 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.major = exports.version = void 0;
4
- exports.isCompatibleVersion = isCompatibleVersion;
5
- exports.version = '7.0.6';
4
+ exports.version = '8.0.0';
6
5
  exports.major = Number(exports.version.split('.')[0]);
7
- function isCompatibleVersion(inputVersion) {
8
- // TODO: Remove this
9
- if (inputVersion === 'lua-dev')
10
- return true;
11
- const parts = inputVersion.split('.');
12
- const inputMajor = Number(parts[0]);
13
- if (parts.length !== 3)
14
- return false;
15
- if (isNaN(inputMajor))
16
- return false;
17
- if (inputMajor !== exports.major)
18
- return false;
19
- return true;
20
- }
@@ -1,147 +1,147 @@
1
1
  export declare const statusCodes: {
2
- 400: {
3
- status: number;
4
- title: string;
5
- type: string;
6
- };
7
- 401: {
8
- status: number;
9
- title: string;
10
- type: string;
11
- };
12
- 402: {
13
- status: number;
14
- title: string;
15
- type: string;
16
- };
17
- 403: {
18
- status: number;
19
- title: string;
20
- type: string;
21
- };
22
- 404: {
23
- status: number;
24
- title: string;
25
- type: string;
26
- };
27
- 406: {
28
- status: number;
29
- title: string;
30
- type: string;
31
- };
32
- 405: {
33
- status: number;
34
- title: string;
35
- type: string;
36
- };
37
- 407: {
38
- status: number;
39
- title: string;
40
- type: string;
41
- };
42
- 408: {
43
- status: number;
44
- title: string;
45
- type: string;
46
- };
47
- 409: {
48
- status: number;
49
- title: string;
50
- type: string;
51
- };
52
- 410: {
53
- status: number;
54
- title: string;
55
- type: string;
56
- };
57
- 411: {
58
- status: number;
59
- title: string;
60
- type: string;
61
- };
62
- 412: {
63
- status: number;
64
- title: string;
65
- type: string;
66
- };
67
- 413: {
68
- status: number;
69
- title: string;
70
- type: string;
71
- };
72
- 414: {
73
- status: number;
74
- title: string;
75
- type: string;
76
- };
77
- 415: {
78
- status: number;
79
- title: string;
80
- type: string;
81
- };
82
- 416: {
83
- status: number;
84
- title: string;
85
- type: string;
86
- };
87
- 417: {
88
- status: number;
89
- title: string;
90
- type: string;
91
- };
92
- 418: {
93
- status: number;
94
- title: string;
95
- type: string;
96
- };
97
- 421: {
98
- status: number;
99
- title: string;
100
- type: string;
101
- };
102
- 422: {
103
- status: number;
104
- title: string;
105
- type: string;
106
- };
107
- 423: {
108
- status: number;
109
- title: string;
110
- type: string;
111
- };
112
- 424: {
113
- status: number;
114
- title: string;
115
- type: string;
116
- };
117
- 425: {
118
- status: number;
119
- title: string;
120
- type: string;
121
- };
122
- 426: {
123
- status: number;
124
- title: string;
125
- type: string;
126
- };
127
- 428: {
128
- status: number;
129
- title: string;
130
- type: string;
131
- };
132
- 429: {
133
- status: number;
134
- title: string;
135
- type: string;
136
- };
137
- 431: {
138
- status: number;
139
- title: string;
140
- type: string;
141
- };
142
- 451: {
143
- status: number;
144
- title: string;
145
- type: string;
2
+ readonly 400: {
3
+ readonly status: 400;
4
+ readonly title: "Bad Request";
5
+ readonly type: "/errors/defaults/4xx/badrequest";
6
+ };
7
+ readonly 401: {
8
+ readonly status: 401;
9
+ readonly title: "Unauthorized";
10
+ readonly type: "/errors/defaults/4xx/unauthorized";
11
+ };
12
+ readonly 402: {
13
+ readonly status: 402;
14
+ readonly title: "Payment Required";
15
+ readonly type: "/errors/defaults/4xx/paymentrequired";
16
+ };
17
+ readonly 403: {
18
+ readonly status: 403;
19
+ readonly title: "Forbidden";
20
+ readonly type: "/errors/defaults/4xx/forbidden";
21
+ };
22
+ readonly 404: {
23
+ readonly status: 404;
24
+ readonly title: "Not Found";
25
+ readonly type: "/errors/defaults/4xx/notfound";
26
+ };
27
+ readonly 406: {
28
+ readonly status: 406;
29
+ readonly title: "Not Acceptable";
30
+ readonly type: "errors/defaults/4xx/notacceptable";
31
+ };
32
+ readonly 405: {
33
+ readonly status: 405;
34
+ readonly title: "Method Not Allowed";
35
+ readonly type: "errors/defaults/4xx/methodnotallowed";
36
+ };
37
+ readonly 407: {
38
+ readonly status: 407;
39
+ readonly title: "Proxy Authentication Required (RFC 7235)";
40
+ readonly type: "errors/defaults/4xx/proxyauthenticationrequired";
41
+ };
42
+ readonly 408: {
43
+ readonly status: 408;
44
+ readonly title: "Request Timeout";
45
+ readonly type: "errors/defaults/4xx/requesttimeout";
46
+ };
47
+ readonly 409: {
48
+ readonly status: 409;
49
+ readonly title: "Conflict";
50
+ readonly type: "errors/defaults/4xx/conflict";
51
+ };
52
+ readonly 410: {
53
+ readonly status: 410;
54
+ readonly title: "Gone";
55
+ readonly type: "errors/defaults/4xx/gone";
56
+ };
57
+ readonly 411: {
58
+ readonly status: 411;
59
+ readonly title: "Length Required";
60
+ readonly type: "errors/defaults/4xx/lengthrequired";
61
+ };
62
+ readonly 412: {
63
+ readonly status: 412;
64
+ readonly title: "Precondition Failed (RFC 7232)";
65
+ readonly type: "errors/defaults/4xx/preconditionfailed";
66
+ };
67
+ readonly 413: {
68
+ readonly status: 413;
69
+ readonly title: "Payload Too Large (RFC 7231)";
70
+ readonly type: "errors/defaults/4xx/payloadtoolarge";
71
+ };
72
+ readonly 414: {
73
+ readonly status: 414;
74
+ readonly title: "URI Too Long (RFC 7231)";
75
+ readonly type: "errors/defaults/4xx/uritoolong";
76
+ };
77
+ readonly 415: {
78
+ readonly status: 415;
79
+ readonly title: "Unsupported Media Type (RFC 7231)";
80
+ readonly type: "errors/defaults/4xx/unsupportedmediatype";
81
+ };
82
+ readonly 416: {
83
+ readonly status: 416;
84
+ readonly title: "Range Not Satisfiable (RFC 7233)";
85
+ readonly type: "errors/defaults/4xx/rangenotsatisfiable";
86
+ };
87
+ readonly 417: {
88
+ readonly status: 417;
89
+ readonly title: "Expectation Failed";
90
+ readonly type: "errors/defaults/4xx/expectationfailed";
91
+ };
92
+ readonly 418: {
93
+ readonly status: 418;
94
+ readonly title: "I'm a teapot (RFC 2324, RFC 7168)";
95
+ readonly type: "errors/defaults/4xx/i'mateapot";
96
+ };
97
+ readonly 421: {
98
+ readonly status: 421;
99
+ readonly title: "Misdirected Request (RFC 7540)";
100
+ readonly type: "errors/defaults/4xx/misdirectedrequest";
101
+ };
102
+ readonly 422: {
103
+ readonly status: 422;
104
+ readonly title: "Unprocessable Entity (WebDAV; RFC 4918)";
105
+ readonly type: "errors/defaults/4xx/unprocessableentity";
106
+ };
107
+ readonly 423: {
108
+ readonly status: 423;
109
+ readonly title: "Locked (WebDAV; RFC 4918)";
110
+ readonly type: "errors/defaults/4xx/locked";
111
+ };
112
+ readonly 424: {
113
+ readonly status: 424;
114
+ readonly title: "Failed Dependency (WebDAV; RFC 4918)";
115
+ readonly type: "errors/defaults/4xx/faileddependency";
116
+ };
117
+ readonly 425: {
118
+ readonly status: 425;
119
+ readonly title: "Too Early (RFC 8470)";
120
+ readonly type: "errors/defaults/4xx/tooearly";
121
+ };
122
+ readonly 426: {
123
+ readonly status: 426;
124
+ readonly title: "Upgrade Required";
125
+ readonly type: "errors/defaults/4xx/upgraderequired";
126
+ };
127
+ readonly 428: {
128
+ readonly status: 428;
129
+ readonly title: "Precondition Required (RFC 6585)";
130
+ readonly type: "errors/defaults/4xx/preconditionrequired";
131
+ };
132
+ readonly 429: {
133
+ readonly status: 429;
134
+ readonly title: "Too Many Requests (RFC 6585)";
135
+ readonly type: "errors/defaults/4xx/toomanyrequests";
136
+ };
137
+ readonly 431: {
138
+ readonly status: 431;
139
+ readonly title: "Request Header Fields Too Large (RFC 6585)";
140
+ readonly type: "errors/defaults/4xx/requestheaderfieldstoolarge";
141
+ };
142
+ readonly 451: {
143
+ readonly status: 451;
144
+ readonly title: "Unavailable For Legal Reasons (RFC 7725)";
145
+ readonly type: "errors/defaults/4xx/unavailableforlegalreasons";
146
146
  };
147
147
  };
@@ -1,57 +1,57 @@
1
1
  export declare const statusCodes: {
2
- 500: {
3
- status: number;
4
- title: string;
5
- type: string;
6
- };
7
- 501: {
8
- status: number;
9
- title: string;
10
- type: string;
11
- };
12
- 502: {
13
- status: number;
14
- title: string;
15
- type: string;
16
- };
17
- 503: {
18
- status: number;
19
- title: string;
20
- type: string;
21
- };
22
- 504: {
23
- status: number;
24
- title: string;
25
- type: string;
26
- };
27
- 505: {
28
- status: number;
29
- title: string;
30
- type: string;
31
- };
32
- 506: {
33
- status: number;
34
- title: string;
35
- type: string;
36
- };
37
- 507: {
38
- status: number;
39
- title: string;
40
- type: string;
41
- };
42
- 508: {
43
- status: number;
44
- title: string;
45
- type: string;
46
- };
47
- 511: {
48
- status: number;
49
- title: string;
50
- type: string;
51
- };
52
- 510: {
53
- status: number;
54
- title: string;
55
- type: string;
2
+ readonly 500: {
3
+ readonly status: 500;
4
+ readonly title: "Internal Server Error";
5
+ readonly type: "errors/defaults/5xx/internalservererror";
6
+ };
7
+ readonly 501: {
8
+ readonly status: 501;
9
+ readonly title: "Not Implemented";
10
+ readonly type: "errors/defaults/5xx/notimplemented";
11
+ };
12
+ readonly 502: {
13
+ readonly status: 502;
14
+ readonly title: "Bad Gateway";
15
+ readonly type: "errors/defaults/5xx/badgateway";
16
+ };
17
+ readonly 503: {
18
+ readonly status: 503;
19
+ readonly title: "Service Unavailable";
20
+ readonly type: "errors/defaults/5xx/serviceunavailable";
21
+ };
22
+ readonly 504: {
23
+ readonly status: 504;
24
+ readonly title: "Gateway Timeout";
25
+ readonly type: "errors/defaults/5xx/gatewaytimeout";
26
+ };
27
+ readonly 505: {
28
+ readonly status: 505;
29
+ readonly title: "HTTP Version Not Supported";
30
+ readonly type: "errors/defaults/5xx/httpversionnotsupported";
31
+ };
32
+ readonly 506: {
33
+ readonly status: 506;
34
+ readonly title: "Variant Also Negotiates (RFC 2295)";
35
+ readonly type: "errors/defaults/5xx/variantalsonegotiates";
36
+ };
37
+ readonly 507: {
38
+ readonly status: 507;
39
+ readonly title: "Insufficient Storage (WebDAV; RFC 4918)";
40
+ readonly type: "errors/defaults/5xx/insufficientstorage";
41
+ };
42
+ readonly 508: {
43
+ readonly status: 508;
44
+ readonly title: "Loop Detected (WebDAV; RFC 5842)";
45
+ readonly type: "errors/defaults/5xx/loopdetected";
46
+ };
47
+ readonly 511: {
48
+ readonly status: 511;
49
+ readonly title: "Network Authentication Required (RFC 6585)";
50
+ readonly type: "errors/defaults/5xx/networkauthenticationrequired";
51
+ };
52
+ readonly 510: {
53
+ readonly status: 510;
54
+ readonly title: "Not Extended (RFC 2774)";
55
+ readonly type: "errors/defaults/5xx/notextended";
56
56
  };
57
57
  };
@@ -1,12 +1,12 @@
1
1
  export declare const statusCodes: {
2
- 460: {
3
- status: number;
4
- title: string;
5
- type: string;
2
+ readonly 460: {
3
+ readonly status: 460;
4
+ readonly title: "Client closed connection before idle timeout period elapsed";
5
+ readonly type: "/errors/defaults/aws/clientclosedbeforetimeout";
6
6
  };
7
- 463: {
8
- status: number;
9
- title: string;
10
- type: string;
7
+ readonly 463: {
8
+ readonly status: 463;
9
+ readonly title: "X-Forwarded-For contains more than 30 ips";
10
+ readonly type: "/errors/defaults/aws/toomanyips";
11
11
  };
12
12
  };