POST /attempt/audio_upload
Upload Audio
Upload audio or promote an existing raw upload.
Three shapes:
- File only → multipart
file: server writes bytes, createsuploads_entry+ full audio chain on top. - upload_id only →
?upload_id=<uuid>of an existing upload (e.g. raw bytes captured by the realtime adapter). Server reuses the upload and stacks resource + entry + junctions on top. - upload_id + file → client pre-reserved via
/attempt/audio/newand now fills the slot. Server writes bytes into that upload’s file and then runs the full chain.
Returns \{audio_id, audios_id, upload_id\}. Client only needs
audios_id; upload_id is the primitive handed back.
Parameters
| Name | In | Required | Description |
|---|---|---|---|
upload_id | query | No | — |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
file | string | No | — |
length_seconds | integer | No | — |
name | string | No | — |
description | string | No | — |
idempotency_key | string | No | — |
soft | boolean | No | — |
accept | boolean | No | — |
Response (AudioUploadAttemptApiResponse)
| Field | Type | Required | Description |
|---|---|---|---|
audio_id | string | Yes | UUID of the audios_entry (server plumbing; public handle is audios_id) |
audios_id | string | Yes | UUID of the audios_resource — use this for /generate, /chat/message, download |
upload_id | string | Yes | UUID of the uploads_entry (primitive raw file) |
idempotency_key | string | No | Server-minted soft-call key; echo with accept to promote/reject the staged upload. |
Last updated on