API reference
Volumes
GET
header
AuthorizationBearer <token>label_selector?stringFilter by labels: env=prod, env!=prod, env (has key), !env; comma = AND
Volumes
application/json- response
volumes*array<>curl -X GET "https://example.com/volumes"{ "volumes": [ { "id": 0, "name": "string", "size": 0, "status": "creating", "location": "string", "server": 0, "linux_device": "string", "protection": { "delete": true }, "labels": { "property1": "string", "property2": "string" }, "created": "2019-08-24T14:15:22Z" } ]}POST
header
AuthorizationBearer <token>application/json- body
name*stringLength
1 <= length <= 64size*integerSize in GB
Range
10 <= value <= 10240location?stringRequired unless server is given
server?integerAttach to this server after creation
Format
int64labels?Up to 64 key/value pairs; keys and values up to 63 characters
Created
application/json- response
volume*action?|nullcurl -X POST "https://example.com/volumes" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "size": 10 }'{ "volume": { "id": 0, "name": "string", "size": 0, "status": "creating", "location": "string", "server": 0, "linux_device": "string", "protection": { "delete": true }, "labels": { "property1": "string", "property2": "string" }, "created": "2019-08-24T14:15:22Z" }, "action": { "id": 0, "command": "create_server", "status": "running", "progress": 0, "started": "2019-08-24T14:15:22Z", "finished": "2019-08-24T14:15:22Z", "resources": [ { "id": 0, "type": "server" } ], "error": { "code": "string", "message": "string" } }}GET
header
AuthorizationBearer <token>id*integerFormat
int64Volume
application/json- response
volume*curl -X GET "https://example.com/volumes/0"{ "volume": { "id": 0, "name": "string", "size": 0, "status": "creating", "location": "string", "server": 0, "linux_device": "string", "protection": { "delete": true }, "labels": { "property1": "string", "property2": "string" }, "created": "2019-08-24T14:15:22Z" }}DELETE
header
AuthorizationBearer <token>id*integerFormat
int64Deleted
curl -X DELETE "https://example.com/volumes/0"Empty
PUT
header
AuthorizationBearer <token>id*integerFormat
int64application/json- body
name?stringLength
1 <= length <= 64labels?Up to 64 key/value pairs; keys and values up to 63 characters
protection?Updated
application/json- response
volume*curl -X PUT "https://example.com/volumes/0" \ -H "Content-Type: application/json" \ -d '{}'{ "volume": { "id": 0, "name": "string", "size": 0, "status": "creating", "location": "string", "server": 0, "linux_device": "string", "protection": { "delete": true }, "labels": { "property1": "string", "property2": "string" }, "created": "2019-08-24T14:15:22Z" }}POST
header
AuthorizationBearer <token>id*integerFormat
int64application/json- body
server*integerFormat
int64Action started
application/json- response
action*curl -X POST "https://example.com/volumes/0/actions/attach" \ -H "Content-Type: application/json" \ -d '{ "server": 0 }'{ "action": { "id": 0, "command": "create_server", "status": "running", "progress": 0, "started": "2019-08-24T14:15:22Z", "finished": "2019-08-24T14:15:22Z", "resources": [ { "id": 0, "type": "server" } ], "error": { "code": "string", "message": "string" } }}POST
header
AuthorizationBearer <token>id*integerFormat
int64Action started
application/json- response
action*curl -X POST "https://example.com/volumes/0/actions/detach"{ "action": { "id": 0, "command": "create_server", "status": "running", "progress": 0, "started": "2019-08-24T14:15:22Z", "finished": "2019-08-24T14:15:22Z", "resources": [ { "id": 0, "type": "server" } ], "error": { "code": "string", "message": "string" } }}POST
header
AuthorizationBearer <token>id*integerFormat
int64application/json- body
size*integerRange
10 <= value <= 10240Action started
application/json- response
action*curl -X POST "https://example.com/volumes/0/actions/resize" \ -H "Content-Type: application/json" \ -d '{ "size": 10 }'{ "action": { "id": 0, "command": "create_server", "status": "running", "progress": 0, "started": "2019-08-24T14:15:22Z", "finished": "2019-08-24T14:15:22Z", "resources": [ { "id": 0, "type": "server" } ], "error": { "code": "string", "message": "string" } }}