# First request to get the presigned URL
curl -X POST \
'https://api.prd.realitydefender.xyz/api/files/aws-presigned' \
-H 'X-API-KEY: your-api-key-here' \
-H 'Content-Type: application/json' \
-d '{"fileName": "your-file.mp4"}'
# Second request to upload the file using the presigned URL
# Important: The @ prefix is required before the filename when using --data-binary
# This tells curl to read the file content (works on all platforms: macOS, Linux, Windows)
# For filenames with spaces or special characters, wrap the entire @filename in quotes
curl -X PUT \
'presigned-url-from-previous-response' \
--data-binary '@your-file.mp4'
# Example with a filename containing spaces:
# curl -X PUT 'presigned-url-from-previous-response' \
# --data-binary '@filename with spaces.mp4'