API DocsUploadsProcess an uploaded file

Process an uploaded file

POST/api/video/:id/process-upload
uploads:write

Start processing after the PUT. Step 4 of Upload a video file. Flare converts the file, makes the thumbnail and streams, then deletes the uploaded source.

  • sourceKey (string, required) - The key from presign. It must be inside the video's own folder (VIDEO_ID/...), or the request returns 400
  • source (string) - Output folder: composite (default), screen or camera
  • triggerAbr (boolean) - Build adaptive streams afterwards (default true)

Then poll Get a video until uploadStatus is ready, or uploadProcessingStatus is failed. A 502 means processing could not start; retry.

Examples

curl
curl https://flare.link/api/video/VIDEO_ID/process-upload \
  -H "Authorization: Bearer flr_pat_..." \
  -H "Content-Type: application/json" \
  -d '{ "sourceKey": "VIDEO_ID/source/demo.mp4" }'
node
const res = await fetch("https://flare.link/api/video/VIDEO_ID/process-upload", {
  method: "POST",
  headers: {
    Authorization: "Bearer flr_pat_...",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({ sourceKey: presign.key })
});
const data = await res.json();
python
import requests

res = requests.post(
  "https://flare.link/api/video/VIDEO_ID/process-upload",
  headers={"Authorization": "Bearer flr_pat_..."},
  json={ "sourceKey": presign["key"] }
)
print(res.json())

Expected response

{
  "success": true,
  "status": "PROCESSING",
  "message": "Upload processing started.",
  "callId": "fc-01J..."
}