Hello Alteryx Community!
I'm currently developing a workflow in Alteryx to automate the process of sending a .csv file to a vendor via their API endpoint. Here’s an outline of my approach:
Workflow Overview:
- Input: We receive a .csv file on our side, which is located on an SFTP server.
- Objective: Automate the sending of this .csv file to the vendor's API endpoint daily, along with an org_id variable in the request body. Authentication is handled using a bearer token provided by the vendor.
Proposed Workflow Steps:
Using Alteryx Download Tool:
- Utilize the Download Tool in Alteryx to fetch the .csv file from the SFTP location.
- Save the file locally to a temporary location, ensuring it’s ready for further processing.
Python Tool for API Integration:
- Implement a Python Tool within Alteryx to:
- Construct and send an HTTP POST request to the vendor's API endpoint.
- Include the downloaded .csv file as part of the request payload, dynamically referencing its file path (utilizing the "Filename from a Field" option in the Download Tool).
- Incorporate the org_id variable into the request body to meet API requirements.
3. Automation and Schedule: The entire workflow will be scheduled to run once a day using Alteryx Scheduler to automate the process of fetching and sending the reports over.
Does this approach sound appropriate? Is there a better way or easier way to do this? Any feedback or suggestions would be greatly appreciated!
Thank you in advance for your insights!