Upload File

Body·Body_upload_file_v1_files_upload_post
required
multipart/form-data
  • file
    Type: string · FileFormat: binary
    required

    binary data, used to describe files

  • only_calculate_tokens
    Type: boolean · Only Calculate Tokens
Responses
  • application/json
  • application/json
Request Example for post/files/upload
curl https://ai.hatz.ai/v1/files/upload \
  --request POST \
  --header 'Content-Type: multipart/form-data' \
  --header 'X-API-Key: YOUR_SECRET_TOKEN' \
  --form 'file=@filename' \
  --form 'only_calculate_tokens=false'
null