2023-03-31 17:29:04 +13:00
|
|
|
package apiv1
|
|
|
|
|
2023-12-09 23:24:42 +13:00
|
|
|
// These structs are for the purpose of defining swagger HTTP parameters & responses
|
2023-03-31 17:29:04 +13:00
|
|
|
|
2024-11-09 12:33:16 +13:00
|
|
|
// Binary data response which inherits the attachment's content type.
|
2023-03-31 17:29:04 +13:00
|
|
|
// swagger:response BinaryResponse
|
2023-11-19 14:56:27 +13:00
|
|
|
type binaryResponse string
|
2023-03-31 17:29:04 +13:00
|
|
|
|
|
|
|
// Plain text response
|
|
|
|
// swagger:response TextResponse
|
2023-10-15 19:24:06 +13:00
|
|
|
type textResponse string
|
2023-03-31 17:29:04 +13:00
|
|
|
|
2023-09-27 17:29:03 +13:00
|
|
|
// HTML response
|
|
|
|
// swagger:response HTMLResponse
|
2023-10-15 19:24:06 +13:00
|
|
|
type htmlResponse string
|
2023-09-27 17:29:03 +13:00
|
|
|
|
2024-11-09 12:33:16 +13:00
|
|
|
// Server error will return with a 400 status code
|
|
|
|
// with the error message in the body
|
2023-03-31 17:29:04 +13:00
|
|
|
// swagger:response ErrorResponse
|
2023-10-15 19:24:06 +13:00
|
|
|
type errorResponse string
|
2023-03-31 17:29:04 +13:00
|
|
|
|
2024-11-09 12:33:16 +13:00
|
|
|
// Not found error will return a 404 status code
|
|
|
|
// swagger:response NotFoundResponse
|
|
|
|
type notFoundResponse string
|
|
|
|
|
2023-07-09 22:33:47 +12:00
|
|
|
// Plain text "ok" response
|
2023-03-31 17:29:04 +13:00
|
|
|
// swagger:response OKResponse
|
2023-10-15 19:24:06 +13:00
|
|
|
type okResponse string
|
2023-09-22 06:55:20 +12:00
|
|
|
|
|
|
|
// Plain JSON array response
|
|
|
|
// swagger:response ArrayResponse
|
|
|
|
type arrayResponse []string
|
2024-05-04 10:15:30 +12:00
|
|
|
|
|
|
|
// JSON error response
|
|
|
|
// swagger:response jsonErrorResponse
|
|
|
|
type jsonErrorResponse struct {
|
|
|
|
// A JSON-encoded error response
|
|
|
|
//
|
|
|
|
// in: body
|
|
|
|
Body JSONErrorMessage
|
|
|
|
}
|