Skip to main content
POST
The URL signs the exact Content-Length and Content-Type: PUT the bytes without an Authorization header and with exactly the listed headers, then call completeUpload. URLs live 1 hour; getUpload re-signs them. Voice samples (purpose: voice_sample) may be audio (<= 11 MB) or video (<= 500 MB, its audio is extracted to MP3 on import); larger files fail with 413 media_too_large. When to use: to send a local file as a project source or a voice sample. For a public URL use importMedia. Side effects: Reserves an upload that expires after 24 hours; nothing is processed until completeUpload. Cost: Free. Counts against the upload-hour rate limit and the payer’s caps of 20 open uploads (upload-open) and declared bytes per day (upload-bytes-day); 429 rate_limited names the policy. Idempotency: Idempotency-Key accepted (SDKs send one); retries within 24 h replay the first response with freshly signed URLs. Required scopes: media:write Errors: unsupported_media_type (415), media_too_large (413)

Authorizations

Authorization
string
header
required

API key from Settings -> API keys, sent as Authorization: Bearer <key> (SDK environment variable RASK_API_KEY). Bound to one workspace and one acting user. Operations list the scopes they need (OpenAPI 3.1 scopes on a bearer scheme).

Scopes

media:write

Headers

Idempotency-Key
string

Optional. A unique key per logical request (SDKs send a bare UUIDv4; an RFC 9651 quoted string is accepted and unquoted); reuse it unchanged on retries to replay the first response.

Required string length: 1 - 255
Pattern: ^[\x20-\x7E]+$

Body

application/json

Body of createUpload.

filename
string
required

File name without /, \ or control characters.

Required string length: 1 - 255
Pattern: ^[^/\\\x00-\x1F\x7F]+$
content_type
enum<string>
required

Accepted upload content types. voice_sample uploads accept audio (<= 11 MB, kept as uploaded) and video (<= 500 MB; its audio is extracted to MP3 on import).

  • video/mp4: accepted
  • video/quicktime: accepted
  • video/x-matroska: accepted
  • video/webm: accepted
  • video/x-msvideo: accepted
  • video/x-m4v: accepted
  • video/3gpp: accepted
  • audio/mpeg: accepted
  • audio/wav: accepted
  • audio/x-wav: accepted
  • audio/flac: accepted
  • audio/x-flac: accepted
  • audio/mp4: accepted
  • audio/x-m4a: accepted
Available options:
video/mp4,
video/quicktime,
video/x-matroska,
video/webm,
video/x-msvideo,
video/x-m4v,
video/3gpp,
audio/mpeg,
audio/wav,
audio/x-wav,
audio/flac,
audio/x-flac,
audio/mp4,
audio/x-m4a
size_bytes
integer<int64>
required

Exact size in bytes (<= getPlan.limits.max_upload_bytes).

Required range: 1 <= x <= 5000000000
purpose
enum<string>
default:project_source

project_source (default) or voice_sample (audio <= 11 MB, or video <= 500 MB whose audio is extracted to MP3).

Available options:
project_source,
voice_sample

Response

Created: Upload.

A presigned upload. Bytes go straight to storage, never through the API host.

object
enum<string>
required

Always upload.

Available options:
upload
id
string
required

Upload id.

status
enum<string>
required

Upload status.

  • pending: waiting for bytes; transfer URLs are valid
  • completing: completeUpload is running
  • completed: registered as media
  • aborted: deleted before completion
  • expired: not completed within 24 hours
Available options:
pending,
completing,
completed,
aborted,
expired
filename
string
required

File name.

content_type
enum<string>
required

Accepted upload content types. voice_sample uploads accept audio (<= 11 MB, kept as uploaded) and video (<= 500 MB; its audio is extracted to MP3 on import).

  • video/mp4: accepted
  • video/quicktime: accepted
  • video/x-matroska: accepted
  • video/webm: accepted
  • video/x-msvideo: accepted
  • video/x-m4v: accepted
  • video/3gpp: accepted
  • audio/mpeg: accepted
  • audio/wav: accepted
  • audio/x-wav: accepted
  • audio/flac: accepted
  • audio/x-flac: accepted
  • audio/mp4: accepted
  • audio/x-m4a: accepted
Available options:
video/mp4,
video/quicktime,
video/x-matroska,
video/webm,
video/x-msvideo,
video/x-m4v,
video/3gpp,
audio/mpeg,
audio/wav,
audio/x-wav,
audio/flac,
audio/x-flac,
audio/mp4,
audio/x-m4a
size_bytes
integer<int64>
required

Declared size.

purpose
enum<string>
required

What a media item is for.

  • project_source: the source of a project (default)
  • voice_sample: a sample for createVoiceClone (audio, or video whose audio is extracted to MP3 on import)
Available options:
project_source,
voice_sample
transfer
object | null
required

Presigned URLs while pending, for a key with media:write; otherwise and afterwards null.

media_id
string | null
required

Media created by completeUpload.

import_job_id
string | null
required

The media_import job.

expires_at
string<date-time>
required

The upload expires 24 hours after creation.

created_at
string<date-time>
required

Creation time.