/volumes/types
endpoint to fetch this information.
cloud
and region
fields for the next step.
/volumes/create
API.
<api-key>
with your API key, and customize the cloud
, region
, and size_in_gb
fields to match your requirements.
id
of the newly created volume, which will be used to attach it to an instance.
id
field as you will need it in the next step.
id
in the volume_ids
field while creating the instance using the /instances/create
endpoint.
id
for the instance and a cloud_assigned_id
. Save this for further operations.
vdb
, sbd
, or similar.
lsblk
command (my volume is called vdb
in this example) and mount it to a directory using the following commands:
/mnt/vdb
directory should be connected to your volume and fully accessible for you to write and read from.
/instances/delete
endpoint to remove the instance.
<instance-id>
with the id
of your instance.
Delete the Volume
Once the instance has been deleted, you can safely delete the volume using the /volumes/delete
endpoint.
<volume-id>
with the id
of the volume.