@snyk/error-catalog-nodejs-public 3.16.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.
- package/README.md +7 -0
- package/package.json +15 -0
- package/src/catalogs/Fix-error-catalog.d.ts +100 -0
- package/src/catalogs/Fix-error-catalog.js +180 -0
- package/src/catalogs/Fix-error-catalog.js.map +1 -0
- package/src/catalogs/IsolatedBuilds-error-catalog.d.ts +32 -0
- package/src/catalogs/IsolatedBuilds-error-catalog.js +60 -0
- package/src/catalogs/IsolatedBuilds-error-catalog.js.map +1 -0
- package/src/catalogs/OpenAPI-error-catalog.d.ts +119 -0
- package/src/catalogs/OpenAPI-error-catalog.js +215 -0
- package/src/catalogs/OpenAPI-error-catalog.js.map +1 -0
- package/src/catalogs/OpenSourceEcosystems-error-catalog.d.ts +771 -0
- package/src/catalogs/OpenSourceEcosystems-error-catalog.js +1371 -0
- package/src/catalogs/OpenSourceEcosystems-error-catalog.js.map +1 -0
- package/src/catalogs/OpenSourceProjectIssues-error-catalog.d.ts +71 -0
- package/src/catalogs/OpenSourceProjectIssues-error-catalog.js +130 -0
- package/src/catalogs/OpenSourceProjectIssues-error-catalog.js.map +1 -0
- package/src/catalogs/OpenSourceProjectSnapshots-error-catalog.d.ts +71 -0
- package/src/catalogs/OpenSourceProjectSnapshots-error-catalog.js +130 -0
- package/src/catalogs/OpenSourceProjectSnapshots-error-catalog.js.map +1 -0
- package/src/catalogs/OpenSourceUnmanaged-error-catalog.d.ts +36 -0
- package/src/catalogs/OpenSourceUnmanaged-error-catalog.js +67 -0
- package/src/catalogs/OpenSourceUnmanaged-error-catalog.js.map +1 -0
- package/src/catalogs/PurlVulnerabilityFetching-error-catalog.d.ts +290 -0
- package/src/catalogs/PurlVulnerabilityFetching-error-catalog.js +520 -0
- package/src/catalogs/PurlVulnerabilityFetching-error-catalog.js.map +1 -0
- package/src/catalogs/SbomExport-error-catalog.d.ts +130 -0
- package/src/catalogs/SbomExport-error-catalog.js +235 -0
- package/src/catalogs/SbomExport-error-catalog.js.map +1 -0
- package/src/catalogs/Snyk-error-catalog.d.ts +94 -0
- package/src/catalogs/Snyk-error-catalog.js +170 -0
- package/src/catalogs/Snyk-error-catalog.js.map +1 -0
- package/src/catalogs/error-catalog.d.ts +10 -0
- package/src/catalogs/error-catalog.js +14 -0
- package/src/catalogs/error-catalog.js.map +1 -0
- package/src/catalogs/error-codes.d.ts +138 -0
- package/src/catalogs/error-codes.js +140 -0
- package/src/catalogs/error-codes.js.map +1 -0
- package/src/composite-error.d.ts +13 -0
- package/src/composite-error.js +27 -0
- package/src/composite-error.js.map +1 -0
- package/src/index.d.ts +3 -0
- package/src/index.js +7 -0
- package/src/index.js.map +1 -0
- package/src/problem-error.d.ts +20 -0
- package/src/problem-error.js +78 -0
- package/src/problem-error.js.map +1 -0
- package/src/types.d.ts +66 -0
- package/src/types.js +35 -0
- package/src/types.js.map +1 -0
- package/src/util/index.d.ts +1 -0
- package/src/util/index.js +5 -0
- package/src/util/index.js.map +1 -0
- package/src/util/json-api.d.ts +7 -0
- package/src/util/json-api.js +70 -0
- package/src/util/json-api.js.map +1 -0
|
@@ -0,0 +1,520 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UnsupportedContainerVendorError = exports.UndefinedContainerVendorError = exports.UnsupportedDebianDistroError = exports.UndefinedContainerDistroError = exports.TooManyIssuesError = exports.TooManyPurlsError = exports.InvalidPaginationParametersError = exports.InternalServerError = exports.VulndbNextError = exports.VulnDBInvalidResponseError = exports.VulnerabilityServiceUnavailableError = exports.PackageNotFoundError = exports.UnsupportedGoVersionFormatError = exports.ComponentNotSupportedError = exports.MissingComponentError = exports.UnsupportedEcosystemError = exports.NamespaceNotProvidedError = exports.InvalidPurlError = exports.AuthorizationRequestFailureError = exports.OrganizationNotWhitelistedError = void 0;
|
|
4
|
+
const problem_error_1 = require("../problem-error");
|
|
5
|
+
/**
|
|
6
|
+
* @class
|
|
7
|
+
* @name OrganizationNotWhitelistedError
|
|
8
|
+
* @description You likely don’t have access to the features in Beta. To get access, you can request access to features in Beta through your account manager or team.
|
|
9
|
+
* @summary Your Organisation is not authorized to perform this action
|
|
10
|
+
* @category PurlVulnerabilityFetching
|
|
11
|
+
* @param {string} details the specific details that causes this error
|
|
12
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
13
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
14
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
15
|
+
*/
|
|
16
|
+
class OrganizationNotWhitelistedError extends problem_error_1.ProblemError {
|
|
17
|
+
constructor(details, additionalData, cause, instance) {
|
|
18
|
+
super({
|
|
19
|
+
title: 'Your Organisation is not authorized to perform this action',
|
|
20
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-1040',
|
|
21
|
+
status: 403,
|
|
22
|
+
errorCode: 'SNYK-OSSI-1040',
|
|
23
|
+
level: 'warn',
|
|
24
|
+
instance,
|
|
25
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
26
|
+
this.name = this.constructor.name;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.OrganizationNotWhitelistedError = OrganizationNotWhitelistedError;
|
|
30
|
+
/**
|
|
31
|
+
* @class
|
|
32
|
+
* @name AuthorizationRequestFailureError
|
|
33
|
+
* @description Unexpected error when authenticating. Try again, and if the error still occurs, contact support.
|
|
34
|
+
* @summary Authorization request failure
|
|
35
|
+
* @category PurlVulnerabilityFetching
|
|
36
|
+
* @param {string} details the specific details that causes this error
|
|
37
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
38
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
39
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
40
|
+
*/
|
|
41
|
+
class AuthorizationRequestFailureError extends problem_error_1.ProblemError {
|
|
42
|
+
constructor(details, additionalData, cause, instance) {
|
|
43
|
+
super({
|
|
44
|
+
title: 'Authorization request failure',
|
|
45
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-1050',
|
|
46
|
+
status: 500,
|
|
47
|
+
errorCode: 'SNYK-OSSI-1050',
|
|
48
|
+
level: 'fatal',
|
|
49
|
+
instance,
|
|
50
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
51
|
+
this.name = this.constructor.name;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
exports.AuthorizationRequestFailureError = AuthorizationRequestFailureError;
|
|
55
|
+
/**
|
|
56
|
+
* @class
|
|
57
|
+
* @name InvalidPurlError
|
|
58
|
+
* @description Make sure that the purl is valid. See the Package URL specification link for further information.
|
|
59
|
+
*
|
|
60
|
+
* See more:
|
|
61
|
+
* - [https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst](https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst)
|
|
62
|
+
* @summary Invalid purl
|
|
63
|
+
* @category PurlVulnerabilityFetching
|
|
64
|
+
* @param {string} details the specific details that causes this error
|
|
65
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
66
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
67
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
68
|
+
*/
|
|
69
|
+
class InvalidPurlError extends problem_error_1.ProblemError {
|
|
70
|
+
constructor(details, additionalData, cause, instance) {
|
|
71
|
+
super({
|
|
72
|
+
title: 'Invalid purl',
|
|
73
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2010',
|
|
74
|
+
status: 400,
|
|
75
|
+
errorCode: 'SNYK-OSSI-2010',
|
|
76
|
+
level: 'warn',
|
|
77
|
+
instance,
|
|
78
|
+
}, details, Object.assign({ links: [
|
|
79
|
+
'https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst',
|
|
80
|
+
] }, additionalData), cause);
|
|
81
|
+
this.name = this.constructor.name;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
exports.InvalidPurlError = InvalidPurlError;
|
|
85
|
+
/**
|
|
86
|
+
* @class
|
|
87
|
+
* @name NamespaceNotProvidedError
|
|
88
|
+
* @description You have requested a package type that requires a namespace (e.g. maven group id). Provide the namespace to retrieve the package.
|
|
89
|
+
*
|
|
90
|
+
* See more:
|
|
91
|
+
* - [https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst](https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst)
|
|
92
|
+
* @summary Namespace not specified
|
|
93
|
+
* @category PurlVulnerabilityFetching
|
|
94
|
+
* @param {string} details the specific details that causes this error
|
|
95
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
96
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
97
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
98
|
+
*/
|
|
99
|
+
class NamespaceNotProvidedError extends problem_error_1.ProblemError {
|
|
100
|
+
constructor(details, additionalData, cause, instance) {
|
|
101
|
+
super({
|
|
102
|
+
title: 'Namespace not specified',
|
|
103
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2011',
|
|
104
|
+
status: 400,
|
|
105
|
+
errorCode: 'SNYK-OSSI-2011',
|
|
106
|
+
level: 'warn',
|
|
107
|
+
instance,
|
|
108
|
+
}, details, Object.assign({ links: [
|
|
109
|
+
'https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst',
|
|
110
|
+
] }, additionalData), cause);
|
|
111
|
+
this.name = this.constructor.name;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
exports.NamespaceNotProvidedError = NamespaceNotProvidedError;
|
|
115
|
+
/**
|
|
116
|
+
* @class
|
|
117
|
+
* @name UnsupportedEcosystemError
|
|
118
|
+
* @description The package type is not supported. Check the List issues for a package in Snyk API.
|
|
119
|
+
* @summary Unsupported ecosystem
|
|
120
|
+
* @category PurlVulnerabilityFetching
|
|
121
|
+
* @param {string} details the specific details that causes this error
|
|
122
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
123
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
124
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
125
|
+
*/
|
|
126
|
+
class UnsupportedEcosystemError extends problem_error_1.ProblemError {
|
|
127
|
+
constructor(details, additionalData, cause, instance) {
|
|
128
|
+
super({
|
|
129
|
+
title: 'Unsupported ecosystem',
|
|
130
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2020',
|
|
131
|
+
status: 400,
|
|
132
|
+
errorCode: 'SNYK-OSSI-2020',
|
|
133
|
+
level: 'warn',
|
|
134
|
+
instance,
|
|
135
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
136
|
+
this.name = this.constructor.name;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
exports.UnsupportedEcosystemError = UnsupportedEcosystemError;
|
|
140
|
+
/**
|
|
141
|
+
* @class
|
|
142
|
+
* @name MissingComponentError
|
|
143
|
+
* @description A list of components of the purl spec is required. The purl did not specify all the required components.
|
|
144
|
+
* @summary Purl components required
|
|
145
|
+
* @category PurlVulnerabilityFetching
|
|
146
|
+
* @param {string} details the specific details that causes this error
|
|
147
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
148
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
149
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
150
|
+
*/
|
|
151
|
+
class MissingComponentError extends problem_error_1.ProblemError {
|
|
152
|
+
constructor(details, additionalData, cause, instance) {
|
|
153
|
+
super({
|
|
154
|
+
title: 'Purl components required',
|
|
155
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2021',
|
|
156
|
+
status: 400,
|
|
157
|
+
errorCode: 'SNYK-OSSI-2021',
|
|
158
|
+
level: 'warn',
|
|
159
|
+
instance,
|
|
160
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
161
|
+
this.name = this.constructor.name;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
exports.MissingComponentError = MissingComponentError;
|
|
165
|
+
/**
|
|
166
|
+
* @class
|
|
167
|
+
* @name ComponentNotSupportedError
|
|
168
|
+
* @description Remove the unsupported component and retry the request.
|
|
169
|
+
* @summary Unsupported purl components
|
|
170
|
+
* @category PurlVulnerabilityFetching
|
|
171
|
+
* @param {string} details the specific details that causes this error
|
|
172
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
173
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
174
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
175
|
+
*/
|
|
176
|
+
class ComponentNotSupportedError extends problem_error_1.ProblemError {
|
|
177
|
+
constructor(details, additionalData, cause, instance) {
|
|
178
|
+
super({
|
|
179
|
+
title: 'Unsupported purl components',
|
|
180
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2022',
|
|
181
|
+
status: 400,
|
|
182
|
+
errorCode: 'SNYK-OSSI-2022',
|
|
183
|
+
level: 'warn',
|
|
184
|
+
instance,
|
|
185
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
186
|
+
this.name = this.constructor.name;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
exports.ComponentNotSupportedError = ComponentNotSupportedError;
|
|
190
|
+
/**
|
|
191
|
+
* @class
|
|
192
|
+
* @name UnsupportedGoVersionFormatError
|
|
193
|
+
* @description Go pseudo versions are not supported.
|
|
194
|
+
* @summary Unsupported Go version format
|
|
195
|
+
* @category PurlVulnerabilityFetching
|
|
196
|
+
* @param {string} details the specific details that causes this error
|
|
197
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
198
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
199
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
200
|
+
*/
|
|
201
|
+
class UnsupportedGoVersionFormatError extends problem_error_1.ProblemError {
|
|
202
|
+
constructor(details, additionalData, cause, instance) {
|
|
203
|
+
super({
|
|
204
|
+
title: 'Unsupported Go version format',
|
|
205
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2023',
|
|
206
|
+
status: 400,
|
|
207
|
+
errorCode: 'SNYK-OSSI-2023',
|
|
208
|
+
level: 'warn',
|
|
209
|
+
instance,
|
|
210
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
211
|
+
this.name = this.constructor.name;
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
exports.UnsupportedGoVersionFormatError = UnsupportedGoVersionFormatError;
|
|
215
|
+
/**
|
|
216
|
+
* @class
|
|
217
|
+
* @name PackageNotFoundError
|
|
218
|
+
* @description The package you specified in the purl cannot be found in the vulnerability database. Check the package name, ecosystem, and version, then try again.
|
|
219
|
+
* @summary Requested package not found
|
|
220
|
+
* @category PurlVulnerabilityFetching
|
|
221
|
+
* @param {string} details the specific details that causes this error
|
|
222
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
223
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
224
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
225
|
+
*/
|
|
226
|
+
class PackageNotFoundError extends problem_error_1.ProblemError {
|
|
227
|
+
constructor(details, additionalData, cause, instance) {
|
|
228
|
+
super({
|
|
229
|
+
title: 'Requested package not found',
|
|
230
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2030',
|
|
231
|
+
status: 404,
|
|
232
|
+
errorCode: 'SNYK-OSSI-2030',
|
|
233
|
+
level: 'warn',
|
|
234
|
+
instance,
|
|
235
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
236
|
+
this.name = this.constructor.name;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
exports.PackageNotFoundError = PackageNotFoundError;
|
|
240
|
+
/**
|
|
241
|
+
* @class
|
|
242
|
+
* @name VulnerabilityServiceUnavailableError
|
|
243
|
+
* @description This issue is unexpected, and the service will recover shortly. If the error still occurs, contact support.
|
|
244
|
+
* @summary Vulnerability service not available
|
|
245
|
+
* @category PurlVulnerabilityFetching
|
|
246
|
+
* @param {string} details the specific details that causes this error
|
|
247
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
248
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
249
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
250
|
+
*/
|
|
251
|
+
class VulnerabilityServiceUnavailableError extends problem_error_1.ProblemError {
|
|
252
|
+
constructor(details, additionalData, cause, instance) {
|
|
253
|
+
super({
|
|
254
|
+
title: 'Vulnerability service not available',
|
|
255
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2031',
|
|
256
|
+
status: 503,
|
|
257
|
+
errorCode: 'SNYK-OSSI-2031',
|
|
258
|
+
level: 'error',
|
|
259
|
+
instance,
|
|
260
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
261
|
+
this.name = this.constructor.name;
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
exports.VulnerabilityServiceUnavailableError = VulnerabilityServiceUnavailableError;
|
|
265
|
+
/**
|
|
266
|
+
* @class
|
|
267
|
+
* @name VulnDBInvalidResponseError
|
|
268
|
+
* @description An unexpected error occurred. Please try again, and if you continue to experience issues please contact support.
|
|
269
|
+
* @summary This issue is unexpected and the service should recover quickly if not please contact support
|
|
270
|
+
* @category PurlVulnerabilityFetching
|
|
271
|
+
* @param {string} details the specific details that causes this error
|
|
272
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
273
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
274
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
275
|
+
*/
|
|
276
|
+
class VulnDBInvalidResponseError extends problem_error_1.ProblemError {
|
|
277
|
+
constructor(details, additionalData, cause, instance) {
|
|
278
|
+
super({
|
|
279
|
+
title: 'This issue is unexpected and the service should recover quickly if not please contact support',
|
|
280
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2032',
|
|
281
|
+
status: 500,
|
|
282
|
+
errorCode: 'SNYK-OSSI-2032',
|
|
283
|
+
level: 'warn',
|
|
284
|
+
instance,
|
|
285
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
286
|
+
this.name = this.constructor.name;
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
exports.VulnDBInvalidResponseError = VulnDBInvalidResponseError;
|
|
290
|
+
/**
|
|
291
|
+
* @class
|
|
292
|
+
* @name VulndbNextError
|
|
293
|
+
* @description An unexpected error occurred with the vulnerability service. Please try again, and if you continue to experience issues please contact support.
|
|
294
|
+
* @summary This issue is unexpected and the service should recover quickly if not please contact support
|
|
295
|
+
* @category PurlVulnerabilityFetching
|
|
296
|
+
* @param {string} details the specific details that causes this error
|
|
297
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
298
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
299
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
300
|
+
*/
|
|
301
|
+
class VulndbNextError extends problem_error_1.ProblemError {
|
|
302
|
+
constructor(details, additionalData, cause, instance) {
|
|
303
|
+
super({
|
|
304
|
+
title: 'This issue is unexpected and the service should recover quickly if not please contact support',
|
|
305
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2033',
|
|
306
|
+
status: 500,
|
|
307
|
+
errorCode: 'SNYK-OSSI-2033',
|
|
308
|
+
level: 'error',
|
|
309
|
+
instance,
|
|
310
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
311
|
+
this.name = this.constructor.name;
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
exports.VulndbNextError = VulndbNextError;
|
|
315
|
+
/**
|
|
316
|
+
* @class
|
|
317
|
+
* @name InternalServerError
|
|
318
|
+
* @description This issue is unexpected, and the service will recover shortly. If the error still occurs, contact support.
|
|
319
|
+
* @summary Request not processed due to unexpected error
|
|
320
|
+
* @category PurlVulnerabilityFetching
|
|
321
|
+
* @param {string} details the specific details that causes this error
|
|
322
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
323
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
324
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
325
|
+
*/
|
|
326
|
+
class InternalServerError extends problem_error_1.ProblemError {
|
|
327
|
+
constructor(details, additionalData, cause, instance) {
|
|
328
|
+
super({
|
|
329
|
+
title: 'Request not processed due to unexpected error',
|
|
330
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2040',
|
|
331
|
+
status: 500,
|
|
332
|
+
errorCode: 'SNYK-OSSI-2040',
|
|
333
|
+
level: 'error',
|
|
334
|
+
instance,
|
|
335
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
336
|
+
this.name = this.constructor.name;
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
exports.InternalServerError = InternalServerError;
|
|
340
|
+
/**
|
|
341
|
+
* @class
|
|
342
|
+
* @name InvalidPaginationParametersError
|
|
343
|
+
* @description The pagination limit is > 1 and ≤ 1000, and the offset is ≥0.
|
|
344
|
+
* @summary Invalid pagination parameters
|
|
345
|
+
* @category PurlVulnerabilityFetching
|
|
346
|
+
* @param {string} details the specific details that causes this error
|
|
347
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
348
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
349
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
350
|
+
*/
|
|
351
|
+
class InvalidPaginationParametersError extends problem_error_1.ProblemError {
|
|
352
|
+
constructor(details, additionalData, cause, instance) {
|
|
353
|
+
super({
|
|
354
|
+
title: 'Invalid pagination parameters',
|
|
355
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2041',
|
|
356
|
+
status: 400,
|
|
357
|
+
errorCode: 'SNYK-OSSI-2041',
|
|
358
|
+
level: 'warn',
|
|
359
|
+
instance,
|
|
360
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
361
|
+
this.name = this.constructor.name;
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
exports.InvalidPaginationParametersError = InvalidPaginationParametersError;
|
|
365
|
+
/**
|
|
366
|
+
* @class
|
|
367
|
+
* @name TooManyPurlsError
|
|
368
|
+
* @description The number of purls sent in the request exceeds the limit of 1000 set by the service.
|
|
369
|
+
* @summary purls exceed limit
|
|
370
|
+
* @category PurlVulnerabilityFetching
|
|
371
|
+
* @param {string} details the specific details that causes this error
|
|
372
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
373
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
374
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
375
|
+
*/
|
|
376
|
+
class TooManyPurlsError extends problem_error_1.ProblemError {
|
|
377
|
+
constructor(details, additionalData, cause, instance) {
|
|
378
|
+
super({
|
|
379
|
+
title: 'purls exceed limit',
|
|
380
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2042',
|
|
381
|
+
status: 400,
|
|
382
|
+
errorCode: 'SNYK-OSSI-2042',
|
|
383
|
+
level: 'warn',
|
|
384
|
+
instance,
|
|
385
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
386
|
+
this.name = this.constructor.name;
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
exports.TooManyPurlsError = TooManyPurlsError;
|
|
390
|
+
/**
|
|
391
|
+
* @class
|
|
392
|
+
* @name TooManyIssuesError
|
|
393
|
+
* @description The number of issues found for the provided purls exceeds the limit defined by the API. Reduce the number of purls sent in a single request.
|
|
394
|
+
* @summary Number of issues exceeds limit
|
|
395
|
+
* @category PurlVulnerabilityFetching
|
|
396
|
+
* @param {string} details the specific details that causes this error
|
|
397
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
398
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
399
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
400
|
+
*/
|
|
401
|
+
class TooManyIssuesError extends problem_error_1.ProblemError {
|
|
402
|
+
constructor(details, additionalData, cause, instance) {
|
|
403
|
+
super({
|
|
404
|
+
title: 'Number of issues exceeds limit',
|
|
405
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2043',
|
|
406
|
+
status: 400,
|
|
407
|
+
errorCode: 'SNYK-OSSI-2043',
|
|
408
|
+
level: 'warn',
|
|
409
|
+
instance,
|
|
410
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
411
|
+
this.name = this.constructor.name;
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
exports.TooManyIssuesError = TooManyIssuesError;
|
|
415
|
+
/**
|
|
416
|
+
* @class
|
|
417
|
+
* @name UndefinedContainerDistroError
|
|
418
|
+
* @description The given Package URL does not have a required distro qualifier.
|
|
419
|
+
*
|
|
420
|
+
* See more:
|
|
421
|
+
* - [https://docs.snyk.io/scan-containers/how-snyk-container-works/supported-operating-system-distributions#debian](https://docs.snyk.io/scan-containers/how-snyk-container-works/supported-operating-system-distributions#debian)
|
|
422
|
+
* @summary Expected distro to be present
|
|
423
|
+
* @category PurlVulnerabilityFetching
|
|
424
|
+
* @param {string} details the specific details that causes this error
|
|
425
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
426
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
427
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
428
|
+
*/
|
|
429
|
+
class UndefinedContainerDistroError extends problem_error_1.ProblemError {
|
|
430
|
+
constructor(details, additionalData, cause, instance) {
|
|
431
|
+
super({
|
|
432
|
+
title: 'Expected distro to be present',
|
|
433
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2044',
|
|
434
|
+
status: 400,
|
|
435
|
+
errorCode: 'SNYK-OSSI-2044',
|
|
436
|
+
level: 'warn',
|
|
437
|
+
instance,
|
|
438
|
+
}, details, Object.assign({ links: [
|
|
439
|
+
'https://docs.snyk.io/scan-containers/how-snyk-container-works/supported-operating-system-distributions#debian',
|
|
440
|
+
] }, additionalData), cause);
|
|
441
|
+
this.name = this.constructor.name;
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
exports.UndefinedContainerDistroError = UndefinedContainerDistroError;
|
|
445
|
+
/**
|
|
446
|
+
* @class
|
|
447
|
+
* @name UnsupportedDebianDistroError
|
|
448
|
+
* @description This Debian distro is currently not supported.
|
|
449
|
+
* @summary Unsupported Debian distro
|
|
450
|
+
* @category PurlVulnerabilityFetching
|
|
451
|
+
* @param {string} details the specific details that causes this error
|
|
452
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
453
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
454
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
455
|
+
*/
|
|
456
|
+
class UnsupportedDebianDistroError extends problem_error_1.ProblemError {
|
|
457
|
+
constructor(details, additionalData, cause, instance) {
|
|
458
|
+
super({
|
|
459
|
+
title: 'Unsupported Debian distro',
|
|
460
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2045',
|
|
461
|
+
status: 400,
|
|
462
|
+
errorCode: 'SNYK-OSSI-2045',
|
|
463
|
+
level: 'warn',
|
|
464
|
+
instance,
|
|
465
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
466
|
+
this.name = this.constructor.name;
|
|
467
|
+
}
|
|
468
|
+
}
|
|
469
|
+
exports.UnsupportedDebianDistroError = UnsupportedDebianDistroError;
|
|
470
|
+
/**
|
|
471
|
+
* @class
|
|
472
|
+
* @name UndefinedContainerVendorError
|
|
473
|
+
* @description The given Package URL does not have a required namespace.
|
|
474
|
+
* @summary Expected namespace to be present
|
|
475
|
+
* @category PurlVulnerabilityFetching
|
|
476
|
+
* @param {string} details the specific details that causes this error
|
|
477
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
478
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
479
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
480
|
+
*/
|
|
481
|
+
class UndefinedContainerVendorError extends problem_error_1.ProblemError {
|
|
482
|
+
constructor(details, additionalData, cause, instance) {
|
|
483
|
+
super({
|
|
484
|
+
title: 'Expected namespace to be present',
|
|
485
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2046',
|
|
486
|
+
status: 400,
|
|
487
|
+
errorCode: 'SNYK-OSSI-2046',
|
|
488
|
+
level: 'warn',
|
|
489
|
+
instance,
|
|
490
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
491
|
+
this.name = this.constructor.name;
|
|
492
|
+
}
|
|
493
|
+
}
|
|
494
|
+
exports.UndefinedContainerVendorError = UndefinedContainerVendorError;
|
|
495
|
+
/**
|
|
496
|
+
* @class
|
|
497
|
+
* @name UnsupportedContainerVendorError
|
|
498
|
+
* @description The given Package URL does not contain a supported vendor.
|
|
499
|
+
* @summary Unsupported vendor
|
|
500
|
+
* @category PurlVulnerabilityFetching
|
|
501
|
+
* @param {string} details the specific details that causes this error
|
|
502
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
503
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
504
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
505
|
+
*/
|
|
506
|
+
class UnsupportedContainerVendorError extends problem_error_1.ProblemError {
|
|
507
|
+
constructor(details, additionalData, cause, instance) {
|
|
508
|
+
super({
|
|
509
|
+
title: 'Unsupported vendor',
|
|
510
|
+
type: 'https://docs.snyk.io/more-info/error-catalog#snyk-ossi-2047',
|
|
511
|
+
status: 400,
|
|
512
|
+
errorCode: 'SNYK-OSSI-2047',
|
|
513
|
+
level: 'warn',
|
|
514
|
+
instance,
|
|
515
|
+
}, details, Object.assign({ links: [] }, additionalData), cause);
|
|
516
|
+
this.name = this.constructor.name;
|
|
517
|
+
}
|
|
518
|
+
}
|
|
519
|
+
exports.UnsupportedContainerVendorError = UnsupportedContainerVendorError;
|
|
520
|
+
//# sourceMappingURL=PurlVulnerabilityFetching-error-catalog.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PurlVulnerabilityFetching-error-catalog.js","sourceRoot":"","sources":["../../../../../packages/error-catalog-nodejs-public/src/catalogs/PurlVulnerabilityFetching-error-catalog.ts"],"names":[],"mappings":";;;AAAA,oDAAgD;AAEhD;;;;;;;;;;GAUG;AACH,MAAa,+BAAgC,SAAQ,4BAAY;IAC/D,YACI,OAAe,EACf,cAAoC,EACpC,KAAa,EACb,QAAiB;QAEnB,KAAK,CACH;YACE,KAAK,EAAE,4DAA4D;YACnE,IAAI,EAAE,6DAA6D;YACnE,MAAM,EAAE,GAAG;YACX,SAAS,EAAE,gBAAgB;YAC3B,KAAK,EAAE,MAAM;YACb,QAAQ;SACT,EACD,OAAO,kBAEL,KAAK,EAAE,EAAE,IACN,cAAc,GAEnB,KAAK,CACN,CAAC;QACF,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IACpC,CAAC;CACF;AAzBD,0EAyBC;AAED;;;;;;;;;;GAUG;AACH,MAAa,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AAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IACpC,CAAC;CACF;AAzBD,oEAyBC;AAED;;;;;;;;;;GAUG;AACH,MAAa,6BAA8B,SAAQ,4BAAY;IAC7D,YACI,OAAe,EACf,cAAoC,EACpC,KAAa,EACb,QAAiB;QAEnB,KAAK,CACH;YACE,KAAK,EAAE,kCAAkC;YACzC,IAAI,EAAE,6DAA6D;YACnE,MAAM,EAAE,GAAG;YACX,SAAS,EAAE,gBAAgB;YAC3B,KAAK,EAAE,MAAM;YACb,QAAQ;SACT,EACD,OAAO,kBAEL,KAAK,EAAE,EAAE,IACN,cAAc,GAEnB,KAAK,CACN,CAAC;QACF,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IACpC,CAAC;CACF;AAzBD,sEAyBC;AAED;;;;;;;;;;GAUG;AACH,MAAa,+BAAgC,SAAQ,4BAAY;IAC/D,YACI,OAAe,EACf,cAAoC,EACpC,KAAa,EACb,QAAiB;QAEnB,KAAK,CACH;YACE,KAAK,EAAE,oBAAoB;YAC3B,IAAI,EAAE,6DAA6D;YACnE,MAAM,EAAE,GAAG;YACX,SAAS,EAAE,gBAAgB;YAC3B,KAAK,EAAE,MAAM;YACb,QAAQ;SACT,EACD,OAAO,kBAEL,KAAK,EAAE,EAAE,IACN,cAAc,GAEnB,KAAK,CACN,CAAC;QACF,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IACpC,CAAC;CACF;AAzBD,0EAyBC"}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import { ProblemError } from '../problem-error';
|
|
2
|
+
/**
|
|
3
|
+
* @class
|
|
4
|
+
* @name InternalServerError
|
|
5
|
+
* @description An unexpected error occurred during the SBOM generation. Review the request, then try again. If the error persists, contact Snyk Support.
|
|
6
|
+
* @summary SBOM generation export server error
|
|
7
|
+
* @category SbomExport
|
|
8
|
+
* @param {string} details the specific details that causes this error
|
|
9
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
10
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
11
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
12
|
+
*/
|
|
13
|
+
export declare class InternalServerError extends ProblemError {
|
|
14
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* @class
|
|
18
|
+
* @name UnexpectedDepGraphResponseError
|
|
19
|
+
* @description An unexpected dependency graph error occurred. Review the request, then try again. If the error persists, contact Snyk Support.
|
|
20
|
+
* @summary Dependency graph error
|
|
21
|
+
* @category SbomExport
|
|
22
|
+
* @param {string} details the specific details that causes this error
|
|
23
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
24
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
25
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
26
|
+
*/
|
|
27
|
+
export declare class UnexpectedDepGraphResponseError extends ProblemError {
|
|
28
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* @class
|
|
32
|
+
* @name UnexpectedParseDepGraphError
|
|
33
|
+
* @description The dependency graph cannot be parsed due to an unexpected error. Review the request, then try again. If the error persists, contact Snyk Support.
|
|
34
|
+
* @summary Error parsing dependency graph
|
|
35
|
+
* @category SbomExport
|
|
36
|
+
* @param {string} details the specific details that causes this error
|
|
37
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
38
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
39
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
40
|
+
*/
|
|
41
|
+
export declare class UnexpectedParseDepGraphError extends ProblemError {
|
|
42
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* @class
|
|
46
|
+
* @name IaCOrSASTProjectError
|
|
47
|
+
* @description Only SBOMs for Snyk Open Source or Snyk Container projects are supported.
|
|
48
|
+
* @summary SBOM not supported due to project type
|
|
49
|
+
* @category SbomExport
|
|
50
|
+
* @param {string} details the specific details that causes this error
|
|
51
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
52
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
53
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
54
|
+
*/
|
|
55
|
+
export declare class IaCOrSASTProjectError extends ProblemError {
|
|
56
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* @class
|
|
60
|
+
* @name UnsupportedProjectError
|
|
61
|
+
* @description Only SBOMs for open source projects are supported (Snyk Open Source).
|
|
62
|
+
* @summary SBOM not supported
|
|
63
|
+
* @category SbomExport
|
|
64
|
+
* @param {string} details the specific details that causes this error
|
|
65
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
66
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
67
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
68
|
+
*/
|
|
69
|
+
export declare class UnsupportedProjectError extends ProblemError {
|
|
70
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* @class
|
|
74
|
+
* @name DepGraphResponseError
|
|
75
|
+
* @description The server cannot process the request due to incomplete data. Review the request, then try again.
|
|
76
|
+
* @summary Dependency graph request cannot be processed
|
|
77
|
+
* @category SbomExport
|
|
78
|
+
* @param {string} details the specific details that causes this error
|
|
79
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
80
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
81
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
82
|
+
*/
|
|
83
|
+
export declare class DepGraphResponseError extends ProblemError {
|
|
84
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* @class
|
|
88
|
+
* @name MissingAuthTokenError
|
|
89
|
+
* @description The API token is misconfigured or expired. Configure or generate the API token, then try again.
|
|
90
|
+
*
|
|
91
|
+
* See more:
|
|
92
|
+
* - [https://docs.snyk.io/snyk-api-info/revoking-and-regenerating-snyk-api-tokens](https://docs.snyk.io/snyk-api-info/revoking-and-regenerating-snyk-api-tokens)
|
|
93
|
+
* @summary Authorization failed due to missing API token
|
|
94
|
+
* @category SbomExport
|
|
95
|
+
* @param {string} details the specific details that causes this error
|
|
96
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
97
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
98
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
99
|
+
*/
|
|
100
|
+
export declare class MissingAuthTokenError extends ProblemError {
|
|
101
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* @class
|
|
105
|
+
* @name EmptyRequestBodyError
|
|
106
|
+
* @description The body of the request is empty. Review the request, then try again.
|
|
107
|
+
* @summary Client request cannot be processed
|
|
108
|
+
* @category SbomExport
|
|
109
|
+
* @param {string} details the specific details that causes this error
|
|
110
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
111
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
112
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
113
|
+
*/
|
|
114
|
+
export declare class EmptyRequestBodyError extends ProblemError {
|
|
115
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* @class
|
|
119
|
+
* @name InvalidDepGraphError
|
|
120
|
+
* @description The request cannot be processed due to an internal error. Review the request, then try again.
|
|
121
|
+
* @summary Invalid dependency graph
|
|
122
|
+
* @category SbomExport
|
|
123
|
+
* @param {string} details the specific details that causes this error
|
|
124
|
+
* @param {Record<string, any>} [additionalData] a collection of relevant data specific to this error
|
|
125
|
+
* @param {Error} [cause] the `Error` type that caused this error to be thrown
|
|
126
|
+
* @param {string} [instance] the instance to use for this error. Overrides 'instance' metadata
|
|
127
|
+
*/
|
|
128
|
+
export declare class InvalidDepGraphError extends ProblemError {
|
|
129
|
+
constructor(details: string, additionalData?: Record<string, any>, cause?: Error, instance?: string);
|
|
130
|
+
}
|