Get storages
GET /provider/storages
Returns the list of provider storage resources and their details.
Example cURL requests
Get provider storage ids
curl -H "X-Auth-Token: $TOKEN" -X GET https://$OP_PANEL_HOST/api/v3/onepanel/provider/storages
{
"ids": [
"18a42a43b1b2d92455ffa09e9a15df7fch4f82",
"0a26877440f6ce457106c6958dfe7ecbch0ac6",
"b3d7d10504393556d9b1631a74c34520ch8359"
]
}
Request Examples
Shell
onepanel-rest-cli -u onepanel:$PASSPHRASE getStorages --host https://$OP_PANEL_HOST:9443Responses
application/json
200
The provider storage resources Ids.
Property
Type & Description
ids
array of strings
The list of Ids of cluster storage resources.
Example
application/json
{
"ids": [
"x7It3cpgNgLZ8RwOrOoW",
"Q1boCClpCS5mUNhM7YCy"
]
} 401
Unauthorized request.
403
Forbidden request.
500
Internal server error.
Property
Type & Description
error object (ErrorDetails) Object describing an error.
error
object (ErrorDetails)
Object describing an error.
id required
string
String identifying the error type. Does not change between error instances.
description required
string
Human readable error description. May contain information specific to given error instance.
details
object
Details about the error instance. The object schema is specific to each error type.
Example
application/json
{
"error": {
"id": "badValueString",
"details": {
"key": "name"
},
"description": "Bad value: provided \"name\" must be a string."
}
} 503
Services needed to fulfill this request are not running.