We are aware of the issue with the badge emails resending to everyone, we apologise for the inconvenience - learn more here.

Forum Discussion

dragonuber122's avatar
dragonuber122
New member | Level 2
5 years ago

Error in call to API function "files/upload": HTTP header "Dropbox-API-Arg": could not decode input

I'm unable to submit Dropbox API request from YML Gitlab Pipeline using PowerShell (Windows runner). The API requires to pass a JSON as a header parameter and encoding that JSON into YML Gitlab Pipel...
  • Greg-DB's avatar
    5 years ago

    The Dropbox API doesn't offer a way to retrieve more detailed error information. It returns the error in the response body, and this particular error just indicates that the supplied value couldn't be parsed as valid JSON. It doesn't offer a way to get more specific information about where the parsing failed within the string though, for example, or a way to echo back the original request data.

     

    As for the issue itself, it seems like you have the right idea here, but looking at the output you shared it appears you're actually getting two different errors. The first is the error message from Dropbox itself about the invalid JSON, but the second seems to be an error message from curl itself, not the Dropbox API, indicating an issue with some curl parameter. (That second one seems similar to this issue, for instance. Since you're not actually supplying a port number though, it may indicate that curl command itself is getting mangled somehow.) 

     

    So, it looks like the issue is with how the command is being formatted or escaped, perhaps related to the quotes and variables used in it. We can't provide support for YML Gitlab Pipeline, PowerShell, or curl themselves though, as those are made by third parties.