Storage
Buckets
Buckets are containers for your objects. Each bucket has a unique name within your account.
Bucket Naming Rules
-
3-63 characters long -
Lowercase letters, numbers, and hyphens only -
Must start and end with a letter or number -
Cannot contain consecutive hyphens -
Unique within your account
Create a Bucket
Via Control Panel
Navigate to Storage → Buckets and click Create Bucket. Enter a name and click create.
Via AWS CLI
$ aws --profile edge --endpoint-url https://storage.edge.network \
s3 mb s3://my-new-bucket Via SDK (JavaScript)
import { S3Client, CreateBucketCommand } from '@aws-sdk/client-s3'
const client = new S3Client({
endpoint: 'https://storage.edge.network',
region: 'us-east-1',
forcePathStyle: true,
credentials: {
accessKeyId: 'YOUR_ACCESS_KEY',
secretAccessKey: 'YOUR_SECRET_KEY'
}
})
await client.send(new CreateBucketCommand({
Bucket: 'my-new-bucket'
})) List Buckets
$ aws --profile edge --endpoint-url https://storage.edge.network s3 ls 2025-01-15 09:00:00 assets 2025-02-01 14:30:00 backups 2025-02-10 11:15:00 uploads
Delete a Bucket
A bucket must be empty before it can be deleted.
Empty and delete:
# Delete all objects first
$ aws --profile edge --endpoint-url https://storage.edge.network \
s3 rm s3://my-bucket --recursive
# Then delete the bucket
$ aws --profile edge --endpoint-url https://storage.edge.network \
s3 rb s3://my-bucket Warning
Bucket deletion is permanent and cannot be undone.
Bucket Statistics
Each bucket tracks storage usage automatically:
| Metric | Description |
|---|---|
storage_bytes | Total size of all objects in bytes |
object_count | Number of objects in the bucket |
created_at | When the bucket was created |
Lifecycle Rules
Lifecycle rules automatically delete objects older than a specified number of days. Useful for temporary uploads, log files, build artifacts, and session data.
Creating a Rule
- Open a bucket and navigate to Settings
- Click Add Rule
- Set the number of days after which objects should be deleted
- Optionally set a prefix filter to only target objects with a specific path prefix (e.g.
logs/ortmp/)
How It Works
Rules are evaluated hourly. Objects whose last modified time exceeds the expiry threshold are deleted automatically.
Prefix filters let you target specific folders. A rule with prefix logs/ only deletes objects under that path.
You can have multiple rules per bucket. For example: delete tmp/ after 1 day and logs/ after 30 days.
API
GET /api/storage/buckets/:name/lifecycle — List rules for a bucket
POST /api/storage/buckets/:name/lifecycle — Create a rule ({ "expire_days": 30, "prefix": "logs/" })
DELETE /api/storage/buckets/:name/lifecycle/:ruleId — Delete a rule
Public Buckets
Buckets can be made public, allowing anyone to access objects via a direct URL without authentication.
Enabling Public Access
- Open a bucket and navigate to Settings
- Click Make Public
- Copy the public base URL
Objects are then accessible at:
https://storage.edge.network/_public/{customerId}/{bucket}/{object-key} Public
GET and HEAD requests require no authentication. CORS headers are included for browser access.
Private (default)
All requests require S3 authentication or a presigned URL. This is the default for all new buckets.
CDN Recommended for Production
For production public content, consider using Edge CDN with a storage bucket origin instead. CDN provides caching, DDoS protection, and global edge delivery on top of public access.
API
PATCH /api/storage/buckets/:name/public — Toggle public access ({ "is_public": true })