Forum Discussion

Nate's avatar
Nate
Occasional Contributor
3 years ago
Solved

404 when attemting to upload or update a file using curl.exe on windows

When using c:\windows\system32\curl.exe, attempts to upload or update a file result in 

 

curl.exe -T C:\my.apk HTTPS://cloud.bitbar.com/api/me/files/ --stderr - -u <access_key>:

{"message":"Resource '/api/v2/users/74701599/files/com.phonegap.clockshark.apk' does not exist","statusCode":404}

 

curl.exe -T C:\my.apk https://cloud.bitbar.com/api/me/files/<id>/file --stderr - -u <access_key>:
{"message":"Resource '/api/v2/users/74701599/files/148705724/file' does not exist","statusCode":404}

 

Both work fine when I try with cygwin curl.

  • Support caught the issue with the syntax generated by the cURL Uploader in Azure.  It tries to use -T "my.ip", but need to do a POSt with -F "file=my.ipa".

     

    Corrected syntax: 

    c:\Windows\System32\curl.exe -F "file=@C:\my.ipa" https://cloud.bitbar.com/api/me/files --stderr - -u "<key>:"

     

     

1 Reply

  • Nate's avatar
    Nate
    Occasional Contributor

    Support caught the issue with the syntax generated by the cURL Uploader in Azure.  It tries to use -T "my.ip", but need to do a POSt with -F "file=my.ipa".

     

    Corrected syntax: 

    c:\Windows\System32\curl.exe -F "file=@C:\my.ipa" https://cloud.bitbar.com/api/me/files --stderr - -u "<key>:"