Skip to main content
POST
Announce a file to upload

Authorizations

Authorization
string
header
required

Authorization: Bearer hk_live_... for live keys or Authorization: Bearer hk_test_... for test-mode keys. hk_test_ keys resolve real public catalog metadata but return deterministic committed fixtures, never call inference, and never mutate live credits. This is the only transport for the credential: the x-api-key alias once documented was removed in 0.2.0, because the edge authorizer reads Authorization as its single identity source and a request on any other header is refused before it is authenticated.

Never accepted on a dashboardJwt operation, and there are no exceptions. GET /v1/usage and GET /v1/limits briefly declared both schemes (0.8.0); that was withdrawn in 0.8.1 because no deployed route could honor it — both operations are served by the control-plane API, whose authorizer verifies a Cognito token and refuses an hk_live_ credential on shape, and the customer API does not route either path. An API-key holder reads its balance and reservation from QuoteResponse, which carries balance_credits and reserved_credits on every quote. Every operation in this document takes one scheme or the other and refuses the wrong one as unauthenticated.

Body

application/json
sha256
string
required

The file's SHA-256, lowercase hex. The PUT is signed against it.

Pattern: ^[a-f0-9]{64}$
bytes
integer
required

The file's exact length; the PUT must carry the same Content-Length.

Required range: 1 <= x <= 5368709120
content_type
enum<string>
required
Available options:
audio/mpeg,
audio/mp3,
audio/mp4,
audio/m4a,
audio/x-m4a,
audio/aac,
audio/x-aac,
audio/ogg,
audio/opus,
audio/flac,
audio/x-flac,
audio/wav,
audio/x-wav,
audio/webm
declared_duration_seconds
number
required

What the quote is priced from. A job whose audio runs past the ceiling this reserves fails as declared_duration_exceeded and releases the reservation.

Required range: x <= 36000
title
string

How the entry is labelled; the private show is always "Uploads".

Required string length: 1 - 300

Response

The upload is recorded; PUT the file next.

upload_id
string
required

Opaque, server-generated upload identifier.

Maximum string length: 40
Pattern: ^upl_[A-Za-z0-9]{16,32}$
put_url
string<uri>
required

Presigned PUT; send the file body with put_headers and nothing else.

Maximum string length: 4096
put_headers
object
required

Every header the PUT must carry, verbatim; they are part of the signature.

put_url_expires_at
string<date-time>
required
retained_until
string<date-time>
required

Logical upload expiry and allowance-release time; physical cleanup is asynchronous.

bytes
integer
required
Required range: x >= 1
content_type
enum<string>
required
Available options:
audio/mpeg,
audio/mp3,
audio/mp4,
audio/m4a,
audio/x-m4a,
audio/aac,
audio/x-aac,
audio/ogg,
audio/opus,
audio/flac,
audio/x-flac,
audio/wav,
audio/x-wav,
audio/webm
declared_duration_seconds
number
required
title
required
Maximum string length: 300