Back to top

Volumes

Volume Management (Block Storage)

Retrieve volume's events
GET
/volumes/{id}/events

Returns a list of the current volume’s events

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    include
    string in query

    related attributes to include

    page
    integer in query

    page to display, default to 1, max 100_000

    per_page
    integer in query

    items per page, default to 10, max 1_000

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • {
    	"events": [
    		{
    			"id": "string",
    			"state": "string",
    			"type": "string",
    			"body": "string",
    			"relationships": [
    				{
    					"href": "string"
    				}
    			],
    			"interpolated": "string",
    			"created_at": "string",
    			"href": "string"
    		}
    	],
    	"meta": {
    		"first": {
    			"href": "string"
    		},
    		"previous": {
    			"href": "string"
    		},
    		"self": {
    			"href": "string"
    		},
    		"next": {
    			"href": "string"
    		},
    		"last": {
    			"href": "string"
    		},
    		"total": "integer"
    	}
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Retrieve all volumes
GET
/projects/{id}/storage

Returns a list of the current projects’s volumes.

  • Parameters
  • id
    string  (required) in path

    Project UUID

    include
    string in query

    related attributes to include

    page
    integer in query

    page to display, default to 1, max 100_000

    per_page
    integer in query

    items per page, default to 10, max 1_000

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • {
    	"volumes": [
    		{
    			"id": "string",
    			"name": "string",
    			"description": "string",
    			"size": "integer",
    			"locked": "boolean",
    			"billing_cycle": "string",
    			"state": "string",
    			"created_at": "string",
    			"updated_at": "string",
    			"project": {
    				"href": "string"
    			},
    			"facility": {
    				"href": "string"
    			},
    			"snapshot_policies": [
    				{
    					"href": "string"
    				}
    			],
    			"attachments": [
    				{
    					"href": "string"
    				}
    			],
    			"plan": {
    				"id": "string",
    				"slug": "string",
    				"name": "string",
    				"description": "string",
    				"line": "string",
    				"specs": "object",
    				"pricing": "object",
    				"legacy": "boolean",
    				"class": "string",
    				"available_in": [
    					{
    						"href": "string"
    					}
    				]
    			},
    			"href": "string",
    			"customdata": "string"
    		}
    	],
    	"meta": {
    		"first": {
    			"href": "string"
    		},
    		"previous": {
    			"href": "string"
    		},
    		"self": {
    			"href": "string"
    		},
    		"next": {
    			"href": "string"
    		},
    		"last": {
    			"href": "string"
    		},
    		"total": "integer"
    	}
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Create a volume
/projects/{id}/storage

Creates a new volume in our datacenter.

  • Parameters
  • id
    string  (required) in path

    Project UUID

    volume
     (required) in body

    Volume to create

    size, billing_cycle

    {
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"snapshot_policies": {
    		"$ref": "#\/definitions\/SnapshotPolicyInput"
    	},
    	"customdata": "string"
    } 
  • Response  201   created
  • {
    	"id": "string",
    	"name": "string",
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"state": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"project": {
    		"href": "string"
    	},
    	"facility": {
    		"href": "string"
    	},
    	"snapshot_policies": [
    		{
    			"href": "string"
    		}
    	],
    	"attachments": [
    		{
    			"href": "string"
    		}
    	],
    	"plan": {
    		"id": "string",
    		"slug": "string",
    		"name": "string",
    		"description": "string",
    		"line": "string",
    		"specs": "object",
    		"pricing": "object",
    		"legacy": "boolean",
    		"class": "string",
    		"available_in": {
    			"type": "array",
    			"items": {
    				"$ref": "#\/definitions\/Href"
    			}
    		}
    	},
    	"href": "string",
    	"customdata": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Retrieve a volume
GET
/storage/{id}

Returns a single volume if the user has access

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    include
    string in query

    related attributes to include

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • {
    	"id": "string",
    	"name": "string",
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"state": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"project": {
    		"href": "string"
    	},
    	"facility": {
    		"href": "string"
    	},
    	"snapshot_policies": [
    		{
    			"href": "string"
    		}
    	],
    	"attachments": [
    		{
    			"href": "string"
    		}
    	],
    	"plan": {
    		"id": "string",
    		"slug": "string",
    		"name": "string",
    		"description": "string",
    		"line": "string",
    		"specs": "object",
    		"pricing": "object",
    		"legacy": "boolean",
    		"class": "string",
    		"available_in": {
    			"type": "array",
    			"items": {
    				"$ref": "#\/definitions\/Href"
    			}
    		}
    	},
    	"href": "string",
    	"customdata": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Update the volume
PUT
/storage/{id}

Updates the volume.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    volume
     (required) in body

    Volume to update

    {
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"customdata": "string"
    } 
  • Response  200   ok
  • {
    	"id": "string",
    	"name": "string",
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"state": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"project": {
    		"href": "string"
    	},
    	"facility": {
    		"href": "string"
    	},
    	"snapshot_policies": [
    		{
    			"href": "string"
    		}
    	],
    	"attachments": [
    		{
    			"href": "string"
    		}
    	],
    	"plan": {
    		"id": "string",
    		"slug": "string",
    		"name": "string",
    		"description": "string",
    		"line": "string",
    		"specs": "object",
    		"pricing": "object",
    		"legacy": "boolean",
    		"class": "string",
    		"available_in": {
    			"type": "array",
    			"items": {
    				"$ref": "#\/definitions\/Href"
    			}
    		}
    	},
    	"href": "string",
    	"customdata": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Delete the volume
/storage/{id}

Deletes the volume.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

  • Response  204   no content
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Restore volume
/storage/{id}/restore

Restore the volume to the given snapshot.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    restore_point
    string  (required) in query

    restore point

  • Response  200   ok
  • {
    	"id": "string",
    	"name": "string",
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"state": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"project": {
    		"href": "string"
    	},
    	"facility": {
    		"href": "string"
    	},
    	"snapshot_policies": [
    		{
    			"href": "string"
    		}
    	],
    	"attachments": [
    		{
    			"href": "string"
    		}
    	],
    	"plan": {
    		"id": "string",
    		"slug": "string",
    		"name": "string",
    		"description": "string",
    		"line": "string",
    		"specs": "object",
    		"pricing": "object",
    		"legacy": "boolean",
    		"class": "string",
    		"available_in": {
    			"type": "array",
    			"items": {
    				"$ref": "#\/definitions\/Href"
    			}
    		}
    	},
    	"href": "string",
    	"customdata": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Clone volume/snapshot
/storage/{id}/clone

Clone your volume or snapshot into a new volume. To clone the volume, send an empty body. To promote a volume snapshot into a new volume, include the snapshot_timestamp attribute in the request body.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    snapshot_timestamp
    string in query

    snapshot timestamp

  • Response  201   created
  • {
    	"id": "string",
    	"name": "string",
    	"description": "string",
    	"size": "integer",
    	"locked": "boolean",
    	"billing_cycle": "string",
    	"state": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"project": {
    		"href": "string"
    	},
    	"facility": {
    		"href": "string"
    	},
    	"snapshot_policies": [
    		{
    			"href": "string"
    		}
    	],
    	"attachments": [
    		{
    			"href": "string"
    		}
    	],
    	"plan": {
    		"id": "string",
    		"slug": "string",
    		"name": "string",
    		"description": "string",
    		"line": "string",
    		"specs": "object",
    		"pricing": "object",
    		"legacy": "boolean",
    		"class": "string",
    		"available_in": {
    			"type": "array",
    			"items": {
    				"$ref": "#\/definitions\/Href"
    			}
    		}
    	},
    	"href": "string",
    	"customdata": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Retrieve all volume attachment
GET
/storage/{id}/attachments

Returns a list of the current volume’s attachments.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    include
    string in query

    related attributes to include

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • {
    	"attachments": [
    		{
    			"id": "string",
    			"created_at": "string",
    			"volume": {
    				"href": "string"
    			},
    			"device": {
    				"href": "string"
    			},
    			"href": "string"
    		}
    	]
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Attach your volume
/storage/{id}/attachments

Attach your volume to a device.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    attachment
     (required) in body

    Device to attach

    device_id

    {
    	"device_id": "string"
    } 
  • Response  201   created
  • {
    	"id": "string",
    	"created_at": "string",
    	"volume": {
    		"href": "string"
    	},
    	"device": {
    		"href": "string"
    	},
    	"href": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Retrieve an attachment
GET
/storage/attachments/{id}

Returns a single attachment if the user has access

  • Parameters
  • id
    string  (required) in path

    Attachment UUID

    include
    string in query

    related attributes to include

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • {
    	"id": "string",
    	"created_at": "string",
    	"volume": {
    		"href": "string"
    	},
    	"device": {
    		"href": "string"
    	},
    	"href": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Detach volume
/storage/attachments/{id}

Detach volume.

  • Parameters
  • id
    string  (required) in path

    Attachment UUID

  • Response  204   no content
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Retrieve all volume snapshot
GET
/storage/{id}/snapshots

Returns a list of the current volume’s snapshots.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    include
    string in query

    related attributes to include

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • {
    	"snapshots": [
    		{
    			"id": "string",
    			"status": "string",
    			"created_at": "string",
    			"timestamp": "string",
    			"volume": {
    				"href": "string"
    			}
    		}
    	]
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Create a volume snapshot
/storage/{id}/snapshots

Creates a new snapshot of your volume.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

  • Response  202   accepted
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Delete volume snapshot
/storage/{volume_id}/snapshots/{id}

Delete volume snapshot.

  • Parameters
  • volume_id
    string  (required) in path

    Volume UUID

    id
    string  (required) in path

    Snapshot UUID

  • Response  204   no content
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Create a volume snapshot policy
/storage/{id}/snapshot-policies

Creates a new snapshot policy of your volume.

  • Parameters
  • id
    string  (required) in path

    Volume UUID

    snapshot_count
    integer in query

    Snapshot count

    snapshot_frequency
    string  (required) in query

    Snapshot frequency

  • Response  201   created
  • {
    	"id": "string",
    	"snapshot_count": "integer",
    	"snapshot_frequency": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"volume": {
    		"href": "string"
    	},
    	"href": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Update the volume snapshot policy
PUT
/storage/snapshot-policies/{id}

Updates the volume snapshot policy.

  • Parameters
  • id
    string  (required) in path

    Snapshot Policy UUID

    snapshot_count
    integer in query

    Snapshot count

    snapshot_frequency
    string  (required) in query

    Snapshot frequency

  • Response  200   ok
  • {
    	"id": "string",
    	"snapshot_count": "integer",
    	"snapshot_frequency": "string",
    	"created_at": "string",
    	"updated_at": "string",
    	"volume": {
    		"href": "string"
    	},
    	"href": "string"
    } 
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
  • Response  422   unprocessable entity
Delete the volume snapshot policy
/storage/snapshot-policies/{id}

Deletes the volume snapshot policy.

  • Parameters
  • id
    string  (required) in path

    Snapshot Policy UUID

  • Response  204   no content
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found
Retrieve the custom metadata of a storage volume
GET
/storage/{id}/customdata

Provides the custom metadata stored for this storage volume in json format

  • Parameters
  • id
    string  (required) in path

    Storage Volume UUID

  •  
  • Response Body Show Hide
  • Request URL Show Hide
  • cURL Show Hide
  • Response  200   ok
  • Response  401   unauthorized
  • Response  403   forbidden
  • Response  404   not found