Initiate Upload
Start a single-part upload. Returns a presigned upload_url to PUT the bytes to, and the canonical file_url to pass as a model input. The file row is created now, so an upload you never complete leaves a row whose file_url 404s. Walkthrough: File uploads.
Authorizations
Use the format: Key modelrunner_key
Headers
JSON object setting an expiry for the stored object, e.g. {"expiration_duration_seconds": 3600}. The countdown starts at upload time. See the data retention guide.
Body
Original filename. Preserved, with a random prefix.
MIME type. Send the same value as Content-Type on the PUT.
Byte size, for validation.
Also mint relay_upload_url — a first-party PUT URL on this API host that streams to the same object server-side. For clients whose egress allowlist rejects the raw AWS S3 host.
Response
Presigned upload.
Presigned S3 PUT URL. Valid 5 minutes. Send no Authorization header — the URL carries its own credentials.
Canonical public URL. Usable as model input once the bytes land.
Present only when relay: true. Same 5-minute window; PUT the raw bytes here instead if the S3 host is blocked.

