Remove Image Backgrounds with APImage AI: Airtable to Google Drive
AI Background Removal Workflow
This workflow automatically removes backgrounds from images stored in Airtable using the APImage API π‘₯, then downloads and saves the processed images to Google Drive. Perfect for batch processing product photos, portraits, or any images that need clean, transparent backgrounds. The source (Airtable) and the storage (Google Drive) can be changed to any service or database you want/use.
π§© Nodes Overview
- Remove Background (Manual Trigger) This manual trigger starts the background removal process when clicked.
Customization Options:
Replace with Schedule Trigger for automatic daily/weekly processing
Replace with Webhook Trigger to start via API calls
Replace with File Trigger to process when new files are added
- Get a Record (Airtable) Retrieves media files from your Airtable "Creatives Library" database. Connects to the "Media Files" table in your Airtable base Fetches records containing image thumbnails for processing Returns all matching records with their thumbnail URLs and metadata
Required Airtable Structure: Table with image/attachment field (currently expects "Thumbnail" field) Optional fields: File Name, Media Type, Upload Date, File Size
Customization Options: Replace with Google Sheets, Notion, or any database node Add filters to process only specific records Change to different tables with image URLs
- Code (JavaScript Processing)
Processes Airtable records and prepares thumbnail data for background removal.
Extracts thumbnail URLs from each record
Chooses best quality thumbnail (large > full > original)
Creates clean filenames by removing special characters Adds processing metadata and timestamps
Key Features: // Selects best thumbnail quality if (thumbnail.thumbnails?.large?.url) { thumbnailUrl = thumbnail.thumbnails.large.url; }
// Creates clean filename cleanFileName: (record.fields['File Name'] || 'unknown') .replace(//g, '_') .toLowerCase()
Easy Customization for Different Databases:
Product Database**: Change field mappings to 'Product Name', 'SKU', 'Category'
Portfolio Database**: Use 'Project Name', 'Client', 'Tags'
Employee Database**: Use 'Full Name', 'Department', 'Position'
-
Split Out Converts the array of thumbnails into individual items for parallel processing. Enables processing multiple images simultaneously Each item contains all thumbnail metadata for downstream nodes
-
APImage API (HTTP Request) Calls the APImage service to remove backgrounds from images.
API Endpoint: POST https://apimage.org/api/ai-remove-background
Request Configuration: Header**: Authorization: Bearer YOUR_API_KEY Body**: image_url: {{ $json.originalThumbnailUrl }}
β Setup Required: Replace YOUR_API_KEY with your actual API key Get your key from APImage Dashboard π‘₯
-
Download (HTTP Request) Downloads the processed image from APImage's servers using the returned URL. Fetches the background-removed image file Prepares image data for upload to storage
-
Upload File (Google Drive) Saves processed images to your Google Drive in a "bg_removal" folder.
Customization Options: Replace with Dropbox, OneDrive, AWS S3, or FTP upload Create date-based folder structures Use dynamic filenames with metadata Upload to multiple destinations simultaneously
β¨ How To Get Started
Set up APImage API: Double-click the APImage API node Replace YOUR_API_KEY with your actual API key Keep the Bearer prefix
Configure Airtable: Ensure your Airtable has a table with image attachments Update field names in the Code node if different from defaults
Test the workflow: Click the Remove Background trigger node Verify images are processed and uploaded successfully
π Get your API Key π‘₯
π§ How to Customize
Input Customization (Left Section)
Replace the Airtable integration with any data source containing image URLs:
Google Sheets** with product catalogs
Notion** databases with image galleries
Webhooks** from external systems
File system** monitoring for new uploads
Database** queries for image records
Output Customization (Right Section)
Modify where processed images are stored:
Multiple Storage**: Upload to Google Drive + Dropbox simultaneously
Database Updates**: Update original records with processed image URLs
Email/Slack**: Send processed images via communication tools
Website Integration**: Upload directly to WordPress, Shopify, etc.
Processing Customization Batch Processing**: Limit concurrent API calls Quality Control**: Add image validation before/after processing Format Conversion**: Use Sharp node for resizing or format changes Metadata Preservation**: Extract and maintain EXIF data
π Workflow Connections Remove Background β Get a Record β Code β Split Out β APImage API β Download β Upload File
π― Perfect For
E-commerce**: Batch process product photos for clean, professional listings
Marketing Teams**: Remove backgrounds from brand assets and imagery
Photographers**: Automate background removal for portrait sessions
Content Creators**: Prepare images for presentations and social media
Design Agencies**: Streamline asset preparation workflows
π Resources
APImage API Documentation π‘₯ Airtable API Reference π‘₯ n8n Documentation π‘₯
β‘ Processing Speed: Handles multiple images in parallel for fast batch processing
π Secure: API keys stored safely in n8n credentials
π Reliable: Built-in error handling and retry mechanisms
Related Templates
USDT And TRC20 Wallet Tracker API Workflow for n8n
Overview This n8n workflow is specifically designed to monitor USDT TRC20 transactions within a specified wallet. It u...
Automate Daily Keyword Research with Google Sheets, Suggest API & Custom Search
Who's it for This workflow is perfect for SEO specialists, marketers, bloggers, and content creators who want to automa...
Bulk Automated Google Drive Files Sharing and Direct Download Link Generation
This N8N workflow automates the process of sharing files from Google Drive. It includes OAuth2 authentication, batch pro...
π Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments