Upload a file
POST /api/upload uploads audio for existing integrations. Send JSON to your assigned legacy API origin with a legacy bearer token. For v2 image effects, attach the source image directly to the multipart request.
The example uploads a short audio file in one request. Set
LEGACY_API_ORIGIN to the assigned origin without a trailing slash or /api, and set LEGACY_ACCESS_TOKEN to your legacy session token.
- 400 confirms a missing or invalid file field or byte range. Read the
errorstring and correct the request. - 401 indicates an authentication failure. Check the legacy token and the API origin.
- 409 means the requested offset would leave a gap. The response includes
size, the current number of bytes stored. Check which bytes have already been uploaded, then resume from that offset.
file_name to transcribe audio.
Treat result URLs as opaque. The current storage serves public URLs. Anyone with the URL can access the file while it is available.