The aim of this project is to create an open source python tool which will allow you to create multiple social media/marketing images to use from a csv data source you provide.
git clone https://github.com/kylekirkby/SocialMediaImageAutomation.gitSocial Media Image Automation is an open source Python tool designed to streamline the creation of multiple marketing and social media images at scale. It accepts CSV data sources as input, enabling users to automate the generation of image variations without manual design work. The tool is built for marketers, content creators, and businesses that need to produce consistent, data-driven imagery for campaigns across multiple platforms. By connecting CSV data directly to image generation, it reduces production time and eliminates repetitive design tasks.
["Prepare your data: Create a CSV file with columns for text overlays, image paths, and any dynamic elements (e.g., discounts, hashtags). Ensure filenames match the images in your assets folder.","Choose a template: Select or design a Canva/Figma template that supports dynamic data insertion (e.g., text placeholders, image swaps). Save it as a JSON or CSV-compatible file.","Run the tool: Use the command `python social_media_image_automation.py --template [TEMPLATE_PATH] --data [CSV_PATH] --output [FOLDER] --platform [PLATFORM]`. For advanced users, customize the script with Python to add filters (e.g., grayscale for Instagram Stories) or batch processing.","Review and refine: Check the generated images for consistency. Adjust the CSV or template if errors occur (e.g., missing images, text overflow). Use tools like Pillow or OpenCV for post-processing (e.g., resizing, adding watermarks).","Schedule posts: Export the images to your social media scheduler (e.g., Hootsuite, Buffer) or manually upload them. Include the CSV-generated captions for consistency across platforms."]
Generate product promotion images for multiple SKUs from inventory CSV
Create social media post variations for campaign content calendars
Produce personalized marketing images with dynamic text from customer data
Batch create event or announcement graphics with varying dates and details
No install command available. Check the GitHub repository for manual installation instructions.
git clone https://github.com/kylekirkby/SocialMediaImageAutomationCopy the install command above and run it in your terminal.
Launch Claude Code, Cursor, or your preferred AI coding agent.
Use the prompt template or examples below to test the skill.
Adapt the skill to your specific use case and workflow.
Generate [NUMBER] social media images for [PLATFORM] (e.g., Instagram, LinkedIn, Twitter) using the design template '[TEMPLATE_NAME]' and data from '[CSV_FILE_PATH]'. For each image, apply the following customizations: [CUSTOMIZATION_RULES]. Ensure all images follow [BRAND_GUIDELINES] for colors, fonts, and logo placement. Export the final images to the '[OUTPUT_FOLDER]' directory in [FORMAT] (e.g., PNG, JPG) with filenames formatted as '[NAMING_CONVENTION]' (e.g., 'campaign_post_[INDEX].png').
Generated 5 Instagram carousel images for a summer campaign using the 'beach_vibes' template and data from 'summer_promo.csv'. The customizations applied were: 1) Background color set to '#FF6B35' (coral), 2) Text overlay for product name in 'Montserrat Bold' at 32pt, 3) Discount percentage dynamically pulled from the CSV (e.g., '30% OFF'), and 4) Product image swapped for each slide based on SKU. All images followed the brand guidelines with the company logo (top-right, 5% opacity) and used the hex codes #FFFFFF for text and #000000 for accents. The final images were exported to 'output/instagram_campaign/' as 'summer_promo_01.png' through 'summer_promo_05.png' in 1080x1080px PNG format. Each image included a call-to-action button ('Shop Now') positioned at 70% opacity in the bottom-right corner.
Example image 1 (summer_promo_01.png):
- Background: Coral gradient (#FF6B35 to #FF8C42).
- Text: 'Tropical Tee • 30% OFF • Limited Time!'
- Product image: 'tee_spring_blue.png' centered.
- CTA button: 'Shop Now' in white (#FFFFFF) with rounded corners.
Example image 3 (summer_promo_03.png):
- Background: Coral gradient (#FF6B35 to #FF8C42).
- Text: 'Beach Towel • 25% OFF • New Arrivals!'
- Product image: 'towel_striped.png' positioned at 60% width.
- CTA button: 'Shop Now' in white (#FFFFFF) with rounded corners.
All images were optimized for Instagram's 1:1 aspect ratio and included a subtle drop shadow for depth. The CSV data included columns for 'product_name', 'discount', 'image_filename', and 'cta_text', ensuring dynamic content generation.Take a free 3-minute scan and get personalized AI skill recommendations.
Take free scan