Skip to main content
POST
/
v1
/
files
/
upload
/
stream
File Stream Upload
curl --request POST \
  --url https://api.foxapi.cc/v1/files/upload/stream \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form file='@example-file' \
  --form purpose=image-input
{
  "id": "file-abc123def456",
  "filename": "photo.png",
  "url": "https://cdn.foxapi.cc/uploads/file-abc123def456.png",
  "size": 204800,
  "created": 1757165031
}

Authorizations

Authorization
string
header
required

All APIs require Bearer Token authentication

Add to request header:

Authorization: Bearer YOUR_API_KEY

Body

multipart/form-data
file
file
required

The file to upload

purpose
string

Usage purpose of the uploaded file

Example:

"image-input"

Response

File uploaded successfully

id
string

File ID

Example:

"file-abc123def456"

filename
string

Original filename

Example:

"photo.png"

url
string

Accessible URL of the uploaded file

Example:

"https://cdn.foxapi.cc/uploads/file-abc123def456.png"

size
integer

File size in bytes

Example:

204800

created
integer

Upload timestamp

Example:

1757165031