Upload API documentation
Upload and manage files and videos from your own scripts, apps and servers with a simple REST API.
Quick start
The API is a Premium feature. Create a key in your dashboard under API, then send it as a Bearer token on every request.
Base URL: https://myupload.us/api/v1
- Header:
Authorization: Bearer YOUR_API_KEY - Files up to 1 GiB, counted against your storage quota.
- Uploads return
202with the item and its shareurl. They go through the same processing as a browser upload, so poll the item or use a webhook. - Up to 120 uploads per hour per account. Over the limit you get
429with aRetry-Afterheader. - Retry safely: send an
Idempotency-Keyheader. The same key within 24 hours returns the original result instead of a duplicate.
Upload a file
POST /filesSend multipart form data. Put text fields such as title, folderId or newFolderName before the file. Or send the file as the raw request body with ?filename=name.ext.
curl -X POST https://myupload.us/api/v1/files -H "Authorization: Bearer YOUR_API_KEY" -F title="My file" -F file=@./report.pdfOr have us fetch it from a URL (up to 100 URLs per request):
curl -X POST https://myupload.us/api/v1/files/remote -H "Authorization: Bearer YOUR_API_KEY" -H "Content-Type: application/json" -d '{"urls": ["https://example.com/archive.zip"]}'Upload a video
POST /videosSame request as files. The video is encoded to adaptive HLS after upload, and the share link plays it with the myUpload player as soon as it is ready (the original upload plays meanwhile).
curl -X POST https://myupload.us/api/v1/videos -H "Authorization: Bearer YOUR_API_KEY" -F title="My video" -F file=@./clip.mp4Or have us fetch it from a URL:
curl -X POST https://myupload.us/api/v1/videos/remote -H "Authorization: Bearer YOUR_API_KEY" -H "Content-Type: application/json" -d '{"urls": ["https://example.com/clip.mp4"]}'Resumable uploads (tus)
For big files or flaky connections, use the open tus protocol at https://myupload.us/files/ with the same Authorization: Bearer key. Add kind video to the upload metadata for videos. Any tus client library works.
Check status, list and delete
# Upload responses are "processing" until the file is ready. Poll until status is "ready":
curl https://myupload.us/api/v1/files/FILE_ID -H "Authorization: Bearer YOUR_API_KEY"
# List, and delete
curl "https://myupload.us/api/v1/videos?page=1&pageSize=25" -H "Authorization: Bearer YOUR_API_KEY"
curl -X DELETE https://myupload.us/api/v1/videos/VIDEO_ID -H "Authorization: Bearer YOUR_API_KEY"Item status is one of uploading, processing, ready, failed or disabled.
Webhooks
Get told the moment an upload is ready or fails, instead of polling. Add your endpoint in the dashboard. Events: file.ready, file.failed and ping.
Each delivery carries X-Webhook-Event and X-Webhook-Signature: t=<unix>,v1=<hex>, where v1 is the HMAC-SHA256 of <t>.<raw body> with your webhook secret. Reject deliveries older than 5 minutes. Answer with any 2xx; other answers are retried with growing delays for about a day.
import { createHmac, timingSafeEqual } from 'node:crypto';
// rawBody must be the exact request body string, not re-serialized JSON.
export function verifyWebhook(rawBody, signatureHeader, secret) {
const parts = Object.fromEntries(signatureHeader.split(',').map((p) => p.split('=')));
if (Math.abs(Date.now() / 1000 - Number(parts.t)) > 300) return false; // reject replays
const expected = createHmac('sha256', secret).update(`${parts.t}.${rawBody}`).digest('hex');
return timingSafeEqual(Buffer.from(parts.v1), Buffer.from(expected));
}Errors & limits
Errors return JSON like {"error":{"code":"too_large","message":"…"}} with a matching HTTP status.
400no file, or an empty file401missing or invalid key403missing permission, quota exceeded, or the product is switched off413larger than 1 GiB429rate limited (seeRetry-After)
The full machine-readable description is available as openapi.json. Prefer chat? You can also upload from Telegram.
Ready to automate your uploads?
Create a free account, upgrade to Premium and generate your API key in one click.
No credit card · Payouts by bank, PayPal or crypto
