Instagram Visual Analysis with Apify Scraping, OpenAI GPT-5 & Google Sheets
Pull recent Instagram post media for any username, fetch the image binaries, and run automated visual analysis with OpenAI β all orchestrated inside n8n. This workflow uses a Google Sheet to supply target usernames, calls Apifyβs Instagram Profile Scraper to fetch recent posts, downloads the images, and passes them to an OpenAI vision-capable model for structured analysis. Results can then be logged, stored, or routed onward depending on your use case.
π§βπ» Whoβs it for
Social media managers analyzing competitor or brand posts
Marketing teams tracking visual trends and campaign content
Researchers collecting structured insights from Instagram images
βοΈ How it works
Google Sheets β Supplies Instagram usernames (one per row).
Apify Scraper β Fetches latest posts (images and metadata).
HTTP Request β Downloads each image binary.
OpenAI Vision Model β Analyzes visuals and outputs structured summaries.
Filter & Split Nodes β Ensure only the right rows and posts are processed.
π Setup Instructions
-
Connect Google Sheets (OAuth2) Go to n8n β Credentials β New β Google Sheets (OAuth2)
Sign in with your Google account and grant access
In the Get Google Sheet node, select your spreadsheet + worksheet (must contain a User column with Instagram usernames) -
Connect Apify (HTTP Query Auth) Get your Apify API token at Apify Console β Integrations/API
In n8n β Credentials β New β HTTP Query Auth, add a query param token=<YOUR_APIFY_TOKEN>
In the Scrape Details node, select that credential and use the provided URL: -
Connect OpenAI (API Key) Create an API key at OpenAI Platform
In n8n β Credentials β New β OpenAI API, paste your key
In the OpenAI Chat Model node, select your credential and choose a vision-capable model (gpt-4o-mini, gpt-4o, or gpt-5 if available)
π οΈ How to customize
Change the Google Sheet schema (e.g., add campaign tags or notes).
Adjust the OpenAI system prompt to refine what details are extracted (e.g., brand logos, colors, objects).
Route results to Slack, Notion, or Airtable instead of storing only in Sheets.
Apply filters (hashtags, captions, or timeframe) directly in the Apify scraper config.
π Requirements
n8n (Cloud or self-hosted)
Google Sheets account
Apify account + API token
OpenAI API key with a funded account
π¬ Contact
Need help customizing this (e.g., filtering by campaign, sending reports by email, or formatting your PDF)?
π§ rbreen@ynteractive.com
π Robert Breen
π ynteractive.com
Related Templates
Use OpenRouter in n8n versions <1.78
What it is: In version 1.78, n8n introduced a dedicated node to use the OpenRouter service, which lets you to use a lot...
Task Deadline Reminders with Google Sheets, ChatGPT, and Gmail
Intro This template is for project managers, team leads, or anyone who wants to automatically remind teammates of tasks ...
π€ Build Resilient AI Workflows with Automatic GPT and Gemini Failover Chain
This workflow contains community nodes that are only compatible with the self-hosted version of n8n. How it works This...
π Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments