Mar 20, 2022

How To Use Airtable To Automate Image Generation For Building Visual Marketing Assets

Learn how to automate bulk image generation with data from Airtable without writing a single line of code.

Airtable is a powerful tool that can help transform your work. Every marketer should learn how to use Airtable to take their workflow to the next level. In this tutorial, we will demonstrate how you can use Airtable to generate visual marketing assets quickly without spending hours doing repetitive and tedious design work.

Stencil has built-in Airtable integration that can work without touching any code at all. It integrates seamlessly into your existing tables with no changes to your table design. This feature is available to all plans including free trial users.

If you need to bulk create images, we guarantee that this will save your hours of repetitive work.

Let's begin!

Create a template

Choose a template that is suitable for your marketing needs or create one from scratch. We will be using this as the template for this tutorial.

Our template consists of dynamic image that we will change based on the data we pull from Airtable. Same goes with the title and the rest of the layers.

Set up your Airtable

In order to properly integrate with Airtable, there are few things that you need to do. Don't worry it's not complicated at all.

1. Get your API key and Base ID

Go to your account settings to retrieve your API Key.

To get you base ID, go to your base's documentation page. Look for line "The ID of this base is ..."

2. Ensure output column has the right field type

Stencil will populate the output column with the generated images. This column can be named anything but its type must be attachment.

Output is our output column

Set up Airtable Integration

Once you have both base ID and API key, you can continue to set up Airtable integration in Stencil. Again, this is really easy to do.

1. Set Airtable API key to your project

Go to your project's setting page and paste the API key that you retrieved previously.

2. Set up Airtable integration for your template

Go to your project and choose the template that you want to populate with data from Airtable.

To go to Airtable integration section, navigate to Console then under Integrations tab you should see Airtable. Another way to access Airtable integration by clicking Airtable Integration directly under the additional options (ellipsis).

GIF that shows how to access Airtable integration

Then, create new action and fill in the rest of the information. Here, you will also need the Base ID from previous step.

3. Map template to Airtable

All you have to do now is to map the relevant layers from your template to the corresponding columns from your Airtable.

If there things that don't need to be replaced, simply leave the input field empty.

For output field, ensure that your column in Airtable is of type "Attachment" as mentioned in the prerequisite above.

Then, save the action.

4. Run your action

All you have to do now is run the action whenever you need to generate your images. By default, Stencil will only generate image for rows that have their output column empty.

Generated images are automatically uploaded to your Airtable.

Tips and Tricks

1. Use view to generate images from multiple templates

You can utilize Airtable view to filter which rows get to be generated.

If you set up one template to use a different view and another template to use a different view, you can generate images with different templates inside the same table.

2. Set and forget

You don't have to wait for all images to finish rendering. You can close the tab and do something else. Images are generated in the background and your table will be updated with the generated images.

3. Utilize the API

If you are a developer or familiar with how API works, you can trigger the action through our API too. Read more about our Airtable Endpoint API.

4. Use Airtable Automation

Use Airtable Automation to build your workflow. For example, when the images are generated, you can trigger them to upload to social media and more.

Other resources

Ready to dive in?Start your free trial today.