Upload files, retrieve info, and manage your files programmatically from any application.
v1.0 · Last updated June 2026success: false object with an error message. Successful responses return success: true with the relevant data.
The API supports two modes:
Include the token in the Authorization header:
Authorization: Bearer YOUR_API_TOKENTo get a token: log in → Account Settings → API Access → Generate Token.
| Method | Endpoint | Auth | Description |
|---|---|---|---|
| POST | /api/upload | Optional | Upload a file |
| GET | /api/file/{file_id} | None | Get file info |
| DELETE | /api/file/{file_id} | Required | Delete your file |
| GET | /api/user | Required | Account info & limits |
Upload a file using multipart/form-data. Omit the Authorization header to upload as a guest.
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
file | File | Yes | The file to upload |
auto_delete | Integer | No | Optional. Days until deletion: 0=never, 1, 7, 30, 90, 365. Default: 0 (Never) — omit this parameter to keep the file forever. |
cURL — User upload (with token)
curl -X POST https://zippyshare.day/api/upload \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-F "file=@/path/to/document.pdf"cURL — Guest upload (no token)
curl -X POST https://zippyshare.day/api/upload \
-F "file=@/path/to/photo.jpg"JavaScript (fetch)
const form = new FormData();
form.append('file', fileInput.files[0]);
// auto_delete defaults to 0 (Never) — omit to keep file forever
const res = await fetch('https://zippyshare.day/api/upload', {
method: 'POST',
headers: { 'Authorization': 'Bearer YOUR_API_TOKEN' },
body: form,
});
const data = await res.json();
console.log(data.download_link);PHP
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => 'https://zippyshare.day/api/upload',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_TOKEN'],
CURLOPT_POSTFIELDS => [
'file' => new CURLFile('/path/to/file.zip', 'application/zip', 'file.zip'),
// 'auto_delete' => 0, // optional — omit to keep file forever
],
]);
$response = json_decode(curl_exec($curl), true);
echo $response['download_link'];Python
import requests
with open('/path/to/file.zip', 'rb') as f:
res = requests.post(
'https://zippyshare.day/api/upload',
headers={'Authorization': 'Bearer YOUR_API_TOKEN'},
files={'file': f},
# data={'auto_delete': 0}, # optional — omit to keep file forever
)
data = res.json()
print(data['download_link'])Success Response (HTTP 201)
{{
"success": true,
"file_id": "abc123xyz456def",
"name": "document.pdf",
"size": 204800,
"extension": "pdf",
"download_link": "https://zippyshare.day/f/abc123xyz456def",
"preview_link": "https://zippyshare.day/p/abc123xyz456def",
"expires_at": "2026-07-28T00:00:00+00:00"
}}Note: preview_link is only returned for images and PDF files. expires_at is null when the file never expires. If you omit auto_delete, the file is kept forever.
Retrieve information about any uploaded file. No authentication required.
curl https://zippyshare.day/api/file/abc123xyz456defSuccess Response (HTTP 200)
{{
"success": true,
"file_id": "abc123xyz456def",
"name": "document.pdf",
"size": 204800,
"extension": "pdf",
"mime": "application/pdf",
"type": "pdf",
"download_link": "https://zippyshare.day/f/abc123xyz456def",
"preview_link": "https://zippyshare.day/p/abc123xyz456def",
"downloads": 14,
"uploaded_at": "2026-06-28T10:30:00+00:00",
"expires_at": "2026-07-28T10:30:00+00:00"
}}Permanently delete one of your own uploaded files. Bearer token required. You can only delete files uploaded with your account.
curl -X DELETE https://zippyshare.day/api/file/abc123xyz456def \
-H "Authorization: Bearer YOUR_API_TOKEN"Success Response (HTTP 200)
{{
"success": true,
"message": "File deleted successfully."
}}Returns your account details and current upload limits. Bearer token required.
curl https://zippyshare.day/api/user \
-H "Authorization: Bearer YOUR_API_TOKEN"Success Response (HTTP 200)
{{
"success": true,
"user": {{
"id": 42,
"name": "John Doe",
"email": "john@example.com"
}},
"limits": {{
"max_file_size": 1073741824,
"max_file_size_format": "1.00 GB",
"storage_total": null,
"storage_used": 52428800,
"storage_remaining": null,
"files_duration_days": null
}},
"upload_endpoint": "https://zippyshare.day/api/upload"
}}All errors return a JSON object with success: false and an error message.
{{
"success": false,
"error": "File is too large. Max allowed: 500 MB"
}}| HTTP Status | Meaning |
|---|---|
201 | File uploaded successfully |
200 | Request successful |
401 | Unauthorized — invalid or missing token on a protected endpoint |
404 | File not found |
422 | Validation error (file too large, invalid params, blocked file type, etc.) |
Upload limits are set by the site administrator and may change. Use GET /api/user to check your current limits programmatically.
| Feature | Guest (no token) | Registered User (token) |
|---|---|---|
| Max file size | Set by admin | Set by admin (usually higher) |
| Storage space | Shared IP-based quota | Personal quota |
| Delete files via API | Not available | Yes |
| File linked to account | No (anonymous) | Yes |
Authorization: Bearer header of your requests