Hello!
I'm trying to upload a csv file via the download tool. I've got my data all good to go and in a blob, but when it comes to uploading it, it keeps failing.
I can upload it fine using a file on my desktop and Postman, here's the code for what works there:
I'd really prefer to find a solution that doesn't involved saving a file anywhere and just keeping the data in the workflow as there is sensitive data involved.
Here's how my download tool is set up:
When I run this, it looks like it uploaded ok, but when I check the status, it says it's failed.
Thanks in advance!
Hi @macinjosh1 ,
I'm not sure why you're using a blob, but you can download to a specific file location in the download tool, then simply load in the file you downloaded:
you can create the filepath in a formula tool and simply download it there. Then wrap an input tool in a macro, feed this field into the macro andset this as the input path.
EDIT: Hang on...I misread this. You want to UPLOAD?
So interesting question, the initial response I get is this:
But I have a check status in an iterative macro after that times out. When I use Postman to check on it, this is the response I get:
Any one have any ideas?
hey @macinjosh1
Sorry for delay getting back to you, i was hoping to get setup with Qualtrics to have a look at it first hand, as these are usually a little difficult to work out without having access to the API, but i suspect a couple things. The request you make in Alteryx is slightly different, in that your field name is 'FileBlob'
Whereas within the request, it is --data-binary:
This could potentially be the difference - Although it shouldn't matter it may be worth changing to see if it helps.
Additionally, this article explaining this functionality states:
"the tool has to be configured to send a PUT command", are you able to try it as a PUT command and see if that works?
I haven't managed to find the documentation of the API call you are referencing specifically, but a similar one is a PUT request, so this may be the difference needed:
https://api.qualtrics.com/api-reference/reference/singleResponses.json/paths/~1responses~1%7Brespons...
Also, i'd recommend if you need it working ASAP, looking at the RunCommand tool, this allows curl to be executed, so your curl statement would work exactly the same as in command line.
Hope this helps!
TheOC
I'm not married to using the download tool, runcommand is fine. How do I get the blob to get uploaded in that scenario?
Thanks for your help!
Hey @TheOC Thanks for the help so far!
Sorry, but I'm not tracking here, and not familiar with the runcommand tool which isn't helping...
I've got a blob of data all ready to go. I can put that curl information in the command part of the tool I believe. But I want the data to come from the blob, not the file that's listed there. That's the part I'm missing right now.