How to automate file uploads from your computer
To automate the process of uploading files from your computer to a website or web application, you can utilize the Upload a file step. This step allows for easy file transfers without the need for programming.
To upload files, you will need to run the Axiom.ai desktop application, click if you want to read about uploading files to the cloud.
# How to upload a file from your computer using the "Upload a file" step
Assuming you have already added a Go to page step to your automation, use the step finder to add the "Upload a file" step. Then configure the steps as follows.
Design pattern: Upload files
- 1 Go to page
- 2 Upload a file
How
- Click the "File Input Field" and select the file field where you wish to upload your file.
- Finally, insert your file path. This can be from a data source, or click "Click to Select" to add manually.
# How to upload multiple files from your computer via the same page
The "Upload a file" step can also be used in a loop to upload multiple files via a single input field. To achieve this, we use the step in conjunction with the "Loop through data" step. Importantly, we will need to pass the file path from a data source such as a Google Sheet.
Design pattern: Upload files
- 1 Read data from a Google Sheet
- 2 Go to page
- 2 Loop through data
- 2.2 Upload a file
How
- First, add your file paths into a data source such as a Google Sheet.
- Now use a "Read data from a Google Sheet" step to retrieve the file paths.
- Next insert a "Go to page" step. Load the page with the upload field.
- Add a "Loop through data" step.
- Then, add the "Upload a file" step into the loop as a sub-step.
- Click the "File Input Field" and select the file field where you wish to upload your file.
- Finally, click "Insert Data" and select the file path from the Google Sheet.
# How to upload multiple files from your computer to different web pages
The "Upload a file" step can also be used in a loop to upload files to multiple pages. The pages will need to have the same template and matching fields, for example in a CMS system. To achieve this, we use the step along with the "Loop through data" step, inserting the "Go to page" step inside the loop. Importantly, we will need to pass the URL and file path from a data source such as a Google Sheet.
Design pattern: Upload files to multiple URLs
- 1 Read data from a Google Sheet
- 2 Loop through data
- 2.1 Go to page
- 2.2 Upload a file
How
- First, add your URLs and file paths into a data source such as a Google Sheet.
- Now, use a "Read data from a Google Sheet" step to retrieve the data.
- Add a "Loop through data" step.
- Inside the loop, insert a "Go to page" step. Click "Insert Data" and select the URL from the Google Sheet.
- Then, add the "Upload a file" step into the loop as a sub-step.
- Click the "File Input Field" and select the file field where you wish to upload your file.
- Finally, click "Insert Data" and select the file path from the Google Sheet."
# How to upload files locally using the "Upload a file from Google Drive" step
The "Upload a file from Google Drive" step can also be used to upload files from a local folder on your computer. Assuming you have already added a "Go to page" step to your automation, use the step finder to add the Upload a file from Google Drive step. Then configure the steps as follows:
Design pattern: Upload files from Google Drive
- 1 Go to page
- 2 Upload a file from Google Drive
How
- Click the "File Input Field" and select the file field where you wish to upload your file.
- Enter the URL of the file in Google Drive to upload.
- Finally, toggle "Local folder" to on and set a path to upload from.
Just like the "Upload a file" step, you can also use this step inside a loop, but do not use this configuration if you are running the automation via the cloud.
# Issue when automating file uploads
If the file does not upload, please ensure the filename and path are correct and verify that the file is present in the specified location. Additionally, check the folder permissions on your local computer to ensure you have the necessary access rights for file operations.
Please note this step only works when running Axiom.ai locally. To upload files in the cloud use our Google Drive step,