Hi,
I'm not sure if that is possible but I would like to set a flow where I can send a CSV/Excel file via an API. So I would like for Alteryx to pick up an Excel/csv file, convert it into a 'json' file then upload/POST that file via an API. The trick is, I have to upload each row by themselves with the headers of course ( rows number can go from 3 to 30 depending on the day as the file will be different daily). On a regular basis I should have about 6 to 10 headers on a regular basis.
For the API I have the URL information which include the client_secret,ID and grant_type keys.
Any help I can find to help me build this would be greatly appreciated!!
Solved! Go to Solution.
This sounds like a job for either a batch or an iterative macro (I would lean toward iterative myself), but either should work just fine.
How would you proceed with that?
I beginning to understand it...what would the 2 outpu tools be in this case? a regular output?
For iterative macros, I follow a standardized system (as an initial note: Iterative Macros require 2 Macro Output Tools for proper functionality).
More Info. can be found here on iterative macros: https://knowledge.alteryx.com/index/s/article/Getting-Started-with-Iterative-Macros-1583461640389
I don't think this is neccesarily a macro situation - but have you used this API before @Jay2022 or do you just have the credentials? I'd check with postman and figure out the proper syntax for uploads there - FIRST.
After you have the json syntax down (and make sure your credentials work) you'd create a key (ie a rowid) do some transposing, and build a a new datastream of credentials/endpoint/constructed json. then the download tool will execute for each entry that you have.
I am a fair beginner Alteryx user so the iterate macro sounds a bit challenging for me. I will start working on it and try to fin help to set it up. Thank you for the explanation that will help a lot!!
I have not used the API prior to now. I'm trying to set it up based on what the vendor provided me. So far, once I send the POST resquest it does seem to work per POSTMAN as I received the Ok status. The pretty body gives me an access token, token type, expiration and scope but does not show the file nor data. I need to see the data in the file with both headers and value for each row that is passing through.
Is there a way I can do that in POSTMAN?
@CoG , I had a tought, what if I was trying to send out an actual json file but wanted to send one row/case at the time?