Soniox
Docs

Upload file

Upload a new file.

POST
/v1/files

Authorization

AuthorizationRequiredBearer <token>

In: header

Request body

multipart/form-dataRequired
client_reference_idstring

A string provided by the client to track the uploaded file. It can be an ID, a JSON string, or any other text. This value can be used for reference in future API requests or for internal mapping within the client’s systems. The value does not have to be unique. If not provided, it will remain unspecified.

fileRequiredfile

The file to upload. You can specify a custom filename that will be stored with the uploaded file.

Format: "binary"

Response body

201

Uploaded file.

idRequiredstring

The unique identifier of the file.

Format: "uuid"
filenameRequiredstring

Name of the file.

sizeRequiredinteger

Size of the file in bytes.

created_atRequiredstring

When the file was uploaded as string in ISO format.

Format: "date-time"
client_reference_idstring

A string provided by the client to track the uploaded file. It can be an ID, a JSON string, or any other text. This value can be used for reference in future API requests or for internal mapping within the client’s systems. The value does not have to be unique. If not provided, it will remain unspecified.

Errors

Uploaded file.

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