I imported curl into HTTP Request node but I don’t know how to map the binary file to the url so it can upload the file. I thought it would be {{ $binary.data }} but it uploads a 0 byte file. The curl is: curl -X PUT -u :ba41e440-330c-412b-96b6-b803dee7c99e https://pixeldrain.com/api/file/ -T setup.exe
Thanks for the detailed info. The issue you’re facing is likely because you’re not correctly mapping the binary data into the HTTP Request node in n8n. Here’s how to fix it and what the sample JSON would look like.
Step-by-step Fix
Make sure your file (e.g., setup.exe) is being handled by a node like “Read Binary File” or uploaded via “Webhook (binary)” or “Google Drive Download” etc., so that it’s available in $binary data.
In the HTTP Request node:
Set Send Binary Data to true.
In Binary Property, type the name of the binary field (commonly data, file, or whatever your previous node outputted).
Set Method to PUT.
URL to: https://pixeldrain.com/api/file/
Authentication: Use Basic Auth with blank username and ba41e440-330c-412b-96b6-b803dee7c99e as the password.
Important:
If your binary property is not named data, replace "binaryPropertyName": "data" with the actual property name.
Also make sure the previous node actually outputs the file in binary form. You can confirm this by checking the $binary tab in the node’s output.
Let me know if you want me to help you build a full working example from file read to upload.