Skip to main content
POST
/
serverless
/
files
/
file
/
url
/
{file}
Upload file from URL
curl --request POST \
  --url https://api.fal.ai/v1/serverless/files/file/url/{file} \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "url": "https://example.com/cat.jpg"
}
'
true

Authorizations

Authorization
string
header
required

API key must be prefixed with "Key ", e.g. Authorization: Key YOUR_API_KEY

Path Parameters

file
string
required

Target file path (including filename)

Example:

"datasets/images/cat.jpg"

Body

application/json

Upload a file from a URL into the target path

url
string<uri>
required

Publicly accessible URL for the file

Response

Upload initiated

Indicates whether the operation was successful