|
@@ -134,6 +134,19 @@ var (
|
|
|
},
|
|
|
}
|
|
|
|
|
|
+ invalidPaginationResponseDescriptor = ResponseDescriptor{
|
|
|
+ Name: "Invalid pagination number",
|
|
|
+ Description: "The received parameter n was invalid in some way, as described by the error code. The client should resolve the issue and retry the request.",
|
|
|
+ StatusCode: http.StatusBadRequest,
|
|
|
+ Body: BodyDescriptor{
|
|
|
+ ContentType: "application/json",
|
|
|
+ Format: errorsBody,
|
|
|
+ },
|
|
|
+ ErrorCodes: []errcode.ErrorCode{
|
|
|
+ ErrorCodePaginationNumberInvalid,
|
|
|
+ },
|
|
|
+ }
|
|
|
+
|
|
|
repositoryNotFoundResponseDescriptor = ResponseDescriptor{
|
|
|
Name: "No Such Repository Error",
|
|
|
StatusCode: http.StatusNotFound,
|
|
@@ -490,6 +503,7 @@ var routeDescriptors = []RouteDescriptor{
|
|
|
},
|
|
|
},
|
|
|
Failures: []ResponseDescriptor{
|
|
|
+ invalidPaginationResponseDescriptor,
|
|
|
unauthorizedResponseDescriptor,
|
|
|
repositoryNotFoundResponseDescriptor,
|
|
|
deniedResponseDescriptor,
|
|
@@ -1578,6 +1592,9 @@ var routeDescriptors = []RouteDescriptor{
|
|
|
},
|
|
|
},
|
|
|
},
|
|
|
+ Failures: []ResponseDescriptor{
|
|
|
+ invalidPaginationResponseDescriptor,
|
|
|
+ },
|
|
|
},
|
|
|
},
|
|
|
},
|