cURL
curl --request POST \ --url https://api.siliconflow.cn/v1/files \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: multipart/form-data' \ --form purpose=batch \ --form file='@example-file'
{ "code": 20000, "message": "Ok", "status": true, "data": { "id": "file-jkvytbjtow", "object": "file", "bytes": 8509, "createdAt": 1741685396, "filename": "requests.jsonl", "purpose": "batch" } }
Upload files
Use the following format for authentication: Bearer
batch
"batch"
File to upload
"/path/to/abc.jsonl"
Successful response
20000
"Ok"
true
Show child attributes
"file-jkvytbjtow"
"file"
8509
1741685396
"requests.jsonl"