API Reference
Upload files programmatically with custom aliases and auto-expiration.
ENDPOINT
POST
https://phd-madrin.zone.id/api/uploadPARAMETERS
| Parameter | Type | Required | Description |
|---|---|---|---|
| file | File | Yes | The file to upload (multipart/form-data) |
| alias | String | No | Custom short code (letters, numbers, _, -). Max 16 chars. |
| expiration | String | No | 1h (hour), 1d (day), 1w (week), never (default) |
CUSTOM ALIAS
curl -X POST https://phd-madrin.zone.id/api/upload \ -F "file=@/path/to/logo.png" \ -F "alias=my-awesome-logo"
Result: https://phd-madrin.zone.id/f/my-awesome-logo.png
EXPIRATION
curl -X POST https://phd-madrin.zone.id/api/upload \ -F "file=@/path/to/temp-file.pdf" \ -F "expiration=1d"
File will be automatically deleted after 24 hours.
FULL EXAMPLE
curl -X POST https://phd-madrin.zone.id/api/upload \ -F "file=@/path/to/your/document.pdf" \ -F "alias=my-custom-name" \ -F "expiration=1d"
alias=my-custom-nameexpiration=1d
RESPONSE
{
"url": "https://phd-madrin.zone.id/f/my-custom-name.pdf",
"originalUrl": "https://...blob.vercel-storage.com/my-custom-name.pdf",
"filename": "my-custom-name.pdf",
"size": 1024000,
"alias": "my-custom-name",
"expiresAt": "2026-06-15T12:00:00.000Z",
"extension": "pdf"
}SUPPORTED FORMATS
ImagesDocumentsArchivesVideosAudio
Maximum size: 50 MB per upload.
AUTO-DELETE
Files with expiration are checked every hour by our cleanup service.
When expired, they are permanently deleted from storage.
NOTES
- Custom aliases must be unique. If taken, you'll receive a 409 Conflict error.
- Aliases only accept letters, numbers, underscores (_), and hyphens (-).
- No authentication required for basic uploads. Rate limits apply.
- All uploads are served via the edge network for global low latency.