summaryrefslogtreecommitdiff
path: root/pkg/api/server
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/api/server')
-rw-r--r--pkg/api/server/register_volumes.go10
-rw-r--r--pkg/api/server/swagger.go7
2 files changed, 12 insertions, 5 deletions
diff --git a/pkg/api/server/register_volumes.go b/pkg/api/server/register_volumes.go
index 2cf249cc3..93b972b6b 100644
--- a/pkg/api/server/register_volumes.go
+++ b/pkg/api/server/register_volumes.go
@@ -53,8 +53,8 @@ func (s *APIServer) registerVolumeHandlers(r *mux.Router) error {
// produces:
// - application/json
// responses:
- // '204':
- // description: no error
+ // '200':
+ // "$ref": "#/responses/VolumePruneResponse"
// '500':
// "$ref": "#/responses/InternalError"
r.Handle(VersionedPath("/libpod/volumes/prune"), s.APIHandler(libpod.PruneVolumes)).Methods(http.MethodPost)
@@ -71,11 +71,11 @@ func (s *APIServer) registerVolumeHandlers(r *mux.Router) error {
// - application/json
// responses:
// '200':
- // "$ref": "#/responses/InspectVolumeResponse"
+ // "$ref": "#/responses/VolumeCreateResponse"
// '404':
- // "$ref": "#/responses/NoSuchVolume"
+ // "$ref": "#/responses/NoSuchVolume"
// '500':
- // "$ref": "#/responses/InternalError"
+ // "$ref": "#/responses/InternalError"
r.Handle(VersionedPath("/libpod/volumes/{name}/json"), s.APIHandler(libpod.InspectVolume)).Methods(http.MethodGet)
// swagger:operation DELETE /libpod/volumes/{name} volumes removeVolume
// ---
diff --git a/pkg/api/server/swagger.go b/pkg/api/server/swagger.go
index 2e1a269f2..50ce42b3b 100644
--- a/pkg/api/server/swagger.go
+++ b/pkg/api/server/swagger.go
@@ -151,6 +151,13 @@ type ok struct {
}
}
+// Volume prune response
+// swagger:response VolumePruneResponse
+type swagVolumePruneResponse struct {
+ // in:body
+ Body []entities.VolumePruneReport
+}
+
// Volume create response
// swagger:response VolumeCreateResponse
type swagVolumeCreateResponse struct {