Help

Bulk Download of photos from an AirTable?

17674 40
cancel
Showing results for 
Search instead for 
Did you mean: 
David_Laufer
6 - Interface Innovator
6 - Interface Innovator

Is there a way to do a mass download of photos from my airtable? The Bulk Upload worked well, now I need to do the reverse! Thanks, All

40 Replies 40

Yes. I’ve done this, but I had to write script using the API. What’s the target location of the photos? Perhaps a Google Drive?

This could also be done using Integromat if you want to save the files to Google Drive, Dropbox, etc.

Hi Bill thanks for the quick response - the target file is currently on Dropbox.

As I look at the airtable, I see that the photos are not all named with their subject, so I need to rename each photo with its name and year (both fields are in the AirTable) and then sort them by year. so if the year were the first part of the new filename, they would self-sort.

Is this within the powers of the programmer’s dark arts, or do I need to have someone do it by hand?

Quick tip about replying to a thread via email: remove your signature. I have a hunch that’s why the post is flagged for review.

To the point of your post, the renaming of the files could also be handled by the same Integromat scenario that saves them to Dropbox. If you want to go this route and would like some help setting it up, let me know.

David_Laufer
6 - Interface Innovator
6 - Interface Innovator

Justin- My Bad, thanks for the heads up. Is there a way to delete the signature from the post?

I think this can be done with a Zapier process as @Justin_Barrett has suggested. And I think the use of adjacent fields for file names is also doable.

Best to exhaust this approach first before writing API code.

Sal_Ohcin
6 - Interface Innovator
6 - Interface Innovator

Check out:

App Store for Airtable - miniExtensions

Tools that empower Airtable users to process unlimited records in bulk with scheduling and automation features. An alternative to Zapier and Integromat.


Awesome extension. only $5. well worth it.
It works even when there are multiple photos within a field
Can download all images in bulk and even set the filename based on any other field. (or do as I did and create a formula field that links multiple columns) and use that as the new name.
If you want to maintain the original name, then you can do that as well. simply don’t fill out that optional “filename” field.
If you have 2 images with the same name, fear not… the extension will automatically add a digit to the next image so it creates a unique name and doesn’t overwrite the original one.

Pete
7 - App Architect
7 - App Architect

Hey David,

Echoing other folks on this thread – Airtable doesn’t currently support bulk download of attachments.

Still, you can set up a Zapier integration that moves all files in an attachment field to Google Drive, where it’s easy to bulk-download files. As a note, Zapier has some limits around how many tasks you can run per month, depending on what pricing plan you use (they have both free and paid plans). Moving attachments via the zap setup suggested below will result in 1 task per attachment exported, so I’d recommend keeping that in mind as you consider whether or not this is the right solution for you. If you decide to use this zap, first create a new grid view on the table with the attachments you’d like to export. Name this view “Exports.” In this view, create a new checkbox field and check off just a single record that has an attachment. Then, configure a filter in this view that only shows records where the checkbox field is checked. Likewise, only the one checked record should be visible. 71ab72844d406b67a2a9592ed5a0c2a25f64eb9b.gif
Next, create a new Zap in Zapier. (If you’re new to Zapier, I’d recommend taking a look at this guide.) Set a new record entering the export view as the trigger for the zap. For the Trigger Step, select the following:

  • Trigger App: Airtable

  • Airtable Trigger: New record in view

  • Account: Here you’ll need to provide your API key (from Airtable.com/account) to grant Zapier access to your Airtable Account.

  • Set up Options: Select the Export View

68c1d9b35d81a97c539091c369f8b8bd14708632.png
Test this step and click Continue. For the next (action) step, set up the following:

  • Action App: Google Drive

  • Google Drive Action: Upload a file

  • Choose Account: Select your Google Drive account.

  • Set up template: It’s possible to precisely specify where the files are uploaded to in Google Drive. It’s most important to set File to {Name of attachment field} URL. In this case, since the attachment field is named Attachments, it’s “Attachments URL”

e25468e418f28f592e3a376066a03fa57ed65c2d.png
If you like, the File Name can be pulled from the table’s primary field. 656f6e7692c1c37516e8aed62dd75eb47d8db2cf.png
After testing, save the Zap and turn it on. The file(s) in the attachment field in Export View should now be in your Google Drive. If it is, check the checkbox field for all the records with attachments that you’d like to export to Google Drive. As these records enter the Export View, Zapier will send their attachments to Google Drive. Depending on your Zapier plan, it may take as long as fifteen minutes for this to happen. Finally, navigate to the “Recent” section in your Google Drive. Select many files at once by shift-clicking. With the files selected, you can download them all at once. 12eefff3a57e158914ab48514eec5cb46ddc4060.gif

Hope this is a bit helpful.

Josh_Doyle
5 - Automation Enthusiast
5 - Automation Enthusiast

@Pete Thank you for these thorough walk-thru of how to build the bulk download zap. I’m having trouble getting Zap to send ALL of the attached images from a record. Right now I’m only seeing the first image in my google drive. So that means the Zap is working (sort of). Any suggestions of what I might be missing?

@Bill.French I’d love to learn more about your scripting solution. I tried using a Zap but it’s only copying 1 image from Airtable to my Google Drive. My goal is to be able to copy over multiple images to Drive from a selected Airtable view. Thank you!

@Pete, when I do a mass checking of all the records following your steps, it does not work. It seems I have to manually click each checkbox individually for the Zap to recognize. Is this a known issue? I’ve seen this happen before and now I think it must be a limitation.

I don’t have a scripting solution; I shared only an approach that worked and required some carefully-written script automation and a target storage service.

In the case where I commented, I used Google Apps Script and Firebase (as the data store) because the client needed a vast object store with real-time access that was receiving files from more than simply Airtable. Critical to this process was the ability to prime the datastore of images and then also maintain it in real-time. As such and given this was pre event-actions supported by Airtable, a script process reviews Airtable every five minutes looking for new images to sync into the Firebase datastore. This can be handled with greater elegance from event actions in Airtable now.

I don’t believe Zapier has the notion of recognizing multiple attachments in a single field. I suspect that Integromat does (@ScottWorld might know).

And by use of the term “selected”, are you implying that this will be (or could optimally be) manually driven from Airtable itself? If so, you should entertain a script block that would allow users to select the view and run the process. The challenge that will face you is there is no magical way to create a file in Google Drive without using the Drive SDK, a complicated and costly proposition and especially the case if I’m asked to build it.

I would look at Integromat or miniExtensions.

Yes, Integromat can easily iterate through multiple attachments in a single field, and then take actions on each one of those attachments separately.

Zapier is nowhere near as advanced as Integromat as a platform, and it doesn’t even have full Airtable support. Integromat has 100% full Airtable support. Personally, I would never recommend Zapier to anyone, unless it was a last resort if they had native support for some app that Integromat didn’t support.

I am a professional Airtable consultant and a Registered Integromat Partner. If you have a budget for your project and need to hire a consultant to help you out, feel free to contact me through my website at scottworld.com. (The Integromat link above contains my personal referral code.)

Hi @Josh_Doyle - another option is using our On2Air: Backups product to backup to Google Drive. It will incrementally push any new attachments from any table configured on a scheduled basis. Depending on the tier, it can go as often as hourly to check for new attachments.

Oooh, that’s a very cool feature to know about! And the On2Air: Backups product does so much more, too, since it is a comprehensive backup solution.

Oh, and speaking of On2Air products, you can get significantly deeper Airtable support within Zapier by adding in another On2Air product: On2Air: Actions.

Thank you @Bill.French for the Integromat idea and for tagging @ScottWorld for verification.
Scott, I really appreciate the tips. I used your referral link to sign up for a trial to see if it solves my problems. If I can’t then I’ll reach out for some pro support from ya. Thanks again!

Orun_Bhuiyan
5 - Automation Enthusiast
5 - Automation Enthusiast

I did it in 2 minutes with no 3rd party tooling, just the shell/terminal.

This works because it seems you don’t need to be authenticated to get files. Tested this in MacOS and should be fine for any *nix.

Steps

  1. Copy the whole column of images you want (or multi select the ones you want and copy to clipboard) and paste into a file, for example, sources.txt

  2. You’ll have to grab the URLs in the parentheses, which easy with sed, just run
    sed -i "" "s/.*(\(.*\))/\1/" sources.txt

  3. Now wget your way through the file:
    xargs < wget <sources.txt

Notes

  • This will download all the files to the current folder. You can also specific the folder you want with -P for wget. Like xargs < wget -P ~/Desktop/images <sources.txt

  • If you don’t want to use wget, you can use curl

  • Instead of step 2, you can just use your code editor to grab the context within the parentheses

It’s certainly a “no-code” approach. :winking_face:

You lost me at step #2. I even tried to do it, too.

Just an FYI that this is not a UNIX programming community. This is a community which is primarily made up of no-coders and low-coders.

(Update: I finally got step #2 to work, but I couldn’t get step #3 to work.)