Skip to main content

Delete a share definition

DELETE 

/shares/:name

Required role: admin. Only an account or token with the admin role can call this operation.

Example request
curl --request DELETE \
--header "Authorization: Bearer $HOSERVA_TOKEN" \
--header "Content-Type: application/json" \
--data @body.json \
"https://$HOSERVA_HOST:8008/api/v1/shares/{name}"

Removes the share row and regenerates mounts and smb.conf. Leaves the share's files on disk. confirm: true is required. Deleting the data is deleteShareData. Refused with 409 maintenance_mode while the array is stopped: delete would unmount and rewrite share mounts against bare disk mountpoints on the root filesystem.

Request​

Responses​

Share definition removed.