Skip to main content

Storage (Compute API)

Two kinds of persistent storage, both created per region and attached to compute at launch:

  • Cloud drive — block storage for one instance at a time. Fast; survives the instance.
  • Shared filesystem — network storage that many instances or every replica of a cluster can mount at once. Datasets, checkpoints, model weights.

What they are and how they bill is in Storage; this page is the API. Prerequisites and shared rules are on the overview.

Endpoints​

MethodPathWhat it does
GET/storage/availabilityFree capacity per region
GET/cloud-drivesYour drives
POST/cloud-drivesCreate a drive
DELETE/cloud-drives/{id}Delete a drive (must not be attached)
GET/shared-filesystemsYour filesystems
POST/shared-filesystemsCreate a filesystem
DELETE/shared-filesystems/{id}Delete a filesystem (must not be attached)

Attaching happens on the compute side: cloud_drives / new_cloud_drives on POST /gpu-instances, shared_filesystems / new_shared_filesystems on instances and clusters. Folder export (download as an archive) is console-only.

Quick run​

KEY="eco_YOUR_KEY"; API="https://api.ecohash.com"

curl -s $API/storage/availability -H "Authorization: Bearer $KEY"
# {"atl":{"block_available_gb":28646,"fs_available_gb":57293},"dls":{...}}

# A 100 GB shared filesystem in atl
curl -s -X POST $API/shared-filesystems \
-H "Authorization: Bearer $KEY" -H "Content-Type: application/json" \
-d '{ "name": "datasets", "region_id": "atl", "size_gb": 100, "mount_path": "/data" }'
# → 202 {"id": 41, "status": "pending", ...}; poll GET /shared-filesystems until "available"

# Launch an instance with it mounted
curl -s -X POST $API/gpu-instances -H "Authorization: Bearer $KEY" -H "Content-Type: application/json" \
-d '{ "region_id": "atl", "gpu_type": "<from availability>", "gpu_count": 1,
"container_image": "public.ecr.aws/a2b7e2y7/ecolink/gpu-base:v0.1.0",
"estimated_duration_hours": 0,
"shared_filesystems": [{ "id": 41, "mount_path": "/data" }] }'

# Later, once nothing is attached to it
curl -s -X DELETE $API/shared-filesystems/41 -H "Authorization: Bearer $KEY"

POST /cloud-drives and POST /shared-filesystems​

FieldTypeRequiredNotes
namestringyesUnique among your active drives / filesystems
region_idstringyesStorage lives in one region and attaches only to compute in that region
size_gbintyesOne of 50, 100, 200, 300, 400, 500
mount_pathstringfilesystems only, optionalDefault mount path (e.g. /data); can be overridden per attachment. Unique among your active filesystems

Up to 8 drives and 8 filesystems per account (409 above that). 409 also for a duplicate name. 402 if the balance cannot cover the first day.

Returns 202 Accepted with the object in status pending; it becomes available within seconds to a minute. No credit hold — storage bills daily per GB from creation until deletion.

The objects​

FieldCloud driveShared filesystem
id, name, region_id, size_gb✓✓
mount_path—default mount path
statuspending → available ↔ in_use; suspended (unpaid), deleting, deleted, lostsame
created_at, updated_at✓✓

in_use means a running instance or cluster has it mounted.

DELETE /cloud-drives/{id} and DELETE /shared-filesystems/{id}​

Refused with 409 ("drive is currently attached") while anything running has it mounted — terminate that first. Otherwise the status goes to deleting, the data is destroyed, and billing stops at the next daily boundary. Returns 202 Accepted with the object.

Your privacy choices

Essential cookies are always on. You can change these choices at any time.