Soniox
Docs
API reference/REST API/Files

Upload file

Uploads a new file.

POST
/v1/files

Headers

AuthorizationRequiredBearer <SONIOX_API_KEY>

Request

multipart/form-dataRequired
client_reference_idstring

Optional tracking identifier string. Does not need to be unique.

Maximum length: 256
fileRequiredfile

The file to upload. Original file name will be used unless a custom filename is provided.

Format: "binary"

Response

201

Uploaded file.

idRequiredstring

Unique identifier of the file.

Format: "uuid"
filenameRequiredstring

Name of the file.

sizeRequiredinteger

Size of the file in bytes.

created_atRequiredstring

UTC timestamp indicating when the file was uploaded.

Format: "date-time"
client_reference_idstring

Tracking identifier string.

Errors

Uploaded file.

{
  "id": "84c32fc6-4fb5-4e7a-b656-b5ec70493753",
  "filename": "example.mp3",
  "size": 123456,
  "created_at": "2024-11-26T00:00:00Z"
}