Skip to main content

Analyze Meta ads creatives with Google Vision & Video Intelligence APIs

Workflow preview

Workflow preview
100%
Analyze Meta ads creatives with Google Vision & Video Intelligence APIs preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

This workflow transforms your Meta Ads creatives into a rich dataset of actionable insights. It's designed for data driven marketers, performance agencies, and analysts who want to move beyond basi...

Best for

  • Market Research automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.scheduletrigger, n8n-nodes-base.facebookgraphapi, n8n-nodes-base.if, n8n-nodes-base.httprequest, n8n-nodes-base.set, n8n-nodes-base.splitout, n8n-nodes-base.code, n8n-nodes-base.extractfromfile

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Kirill Khatkevich.

Original n8n.io source

1.1 Workflow description

Title
Analyze Meta ads creatives with Google Vision & Video Intelligence APIs
Workflow name
Analyze Meta ads creatives with Google Vision & Video Intelligence APIs

This workflow transforms your Meta Ads creatives into a rich dataset of actionable insights. It's designed for data-driven marketers, performance agencies, and analysts who want to move beyond basic metrics and understand the specific visual and textual elements that drive ad performance. By automatically analyzing every video and image with Google's powerful AI (Video Intelligence and Vision APIs), it systematically deconstructs your creatives into labeled data, ready for correlation with campaign results.

Use Case

You know some ads perform better than others, but do you know why? Is it the presence of a person, a specific object, the on-screen text, or the spoken words in a video? Answering these questions manually is nearly impossible at scale. This workflow automates the deep analysis process, allowing you to:

  • Automate Creative Analysis: Stop guessing and start making data-backed decisions about your creative strategy.
  • Uncover Hidden Performance Drivers: Identify which objects, themes, text, or spoken phrases correlate with higher engagement and conversions.
  • Build a Structured Creative Database: Create a detailed, searchable log of every element within your ads for long-term analysis and trend-spotting.
  • Save Countless Hours: Eliminate the tedious manual process of watching, tagging, and logging creative assets.
How it Works

The workflow is triggered on a schedule and follows a clear, structured path:

1. Configuration & Ad Ingestion:

  • The workflow begins on a schedule (e.g., weekly on Monday at 10 AM).
  • It starts by fetching all active ads from a specific Meta Ads Campaign, which you define in the Set Campaign ID node.

2. Intelligent Branching (Video vs. Image):

  • An IF node inspects each creative to determine its type.
  • Video creatives are routed to the Google Video Intelligence API pipeline.
  • Image creatives are routed to the Google Vision API pipeline.

3. The Video Analysis Pipeline:

  • For each video, the workflow gets a direct source URL, downloads the file, and converts it to a Base64 string.
  • It then initiates an asynchronous analysis job in the Google Video Intelligence API, requesting LABEL_DETECTION, SPEECH_TRANSCRIPTION, and TEXT_DETECTION.
  • A loop with a wait timer periodically checks the job status until the analysis is complete.
  • Finally, a Code node parses the complex JSON response, structuring the annotations (like detected objects with timestamps or full speech transcripts) into clean rows.

4. The Image Analysis Pipeline:

  • For each image, the file is downloaded, converted to Base64, and sent to the Google Vision API.
  • It requests a wide range of features, including label, text, logo, and object detection.
  • A Code node parses the response and formats the annotations into a standardized structure.

5. Data Logging & Robust Error Handling:

  • All successfully analyzed data from both pipelines is appended to a primary Google Sheet.
  • The workflow is built to be resilient. If an error occurs (e.g., a video fails to be processed by the API, or an image URL is missing), a detailed error report is logged to a separate errors sheet in your Google Sheet, ensuring no data is lost and problems are easy to track.

Setup Instructions

To use this template, you need to configure a few key nodes.

1. Credentials:

  • Connect your Meta Ads account.
  • Connect your Google account. This account needs access to Google Sheets and must have the Google Cloud Vision API and Google Cloud Video Intelligence API enabled in your GCP project.

2. The Set Campaign ID Node:

  • This is the primary configuration step. Open this Set node and replace the placeholder value with the ID of the Meta Ads campaign you want to analyze.

3. Google Sheets Nodes: You need to configure two Google Sheets nodes:

  • Add Segments data:
    • Select your spreadsheet and the specific sheet where you want to save the successful analysis results.
    • Ensure your sheet has the following headers: campaign_id, ad_id, creative_id, video_id, file_name, image_url, source, annotation_type, label_or_text, category, full_transcript, confidence, start_time_s, end_time_s, language_code, processed_at_utc.
  • Add errors:
    • Select your spreadsheet and the sheet you want to use for logging errors (e.g., a sheet named "errors").
    • Ensure this sheet has headers like: error_type, error_message, campaign_id, ad_id, creative_id, file_name, processed_at_utc.

4. Activate the Workflow:

  • Set your desired frequency in the Run Weekly on Monday at 10 AM (Schedule Trigger) node.
  • Save and activate the workflow.

Further Ideas & Customization

This workflow provides the "what" inside your creatives. The next step is to connect it to performance.

  • Build a Performance Analysis Workflow: Create a second workflow that reads this Google Sheet, fetches performance data (spend, clicks, conversions) for each ad_id from the Meta Ads API, and merges the two datasets. This will allow you to see which labels correlate with the best performance.
  • Create Dashboards: Use the structured data in your Google Sheet as a source for a Looker Studio or Tableau dashboard to visualize creative trends.
  • Incorporate Generative AI: Add a final step that sends the combined performance and annotation data to an LLM (like in the example you provided) to automatically generate qualitative summaries and recommendations for each creative.
  • Add Notifications: Use the Slack or Email nodes to send a summary after each run, reporting how many creatives were analyzed and if any errors occurred.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Run Daily at 9 AM

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.2

Block 2 - Get Active Ads

Type / Role
n8n-nodes-base.facebookGraphApi - facebookGraphApi
Config choices
Version 1

Block 3 - Is it a Video?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 4 - Get Video Source URL

Type / Role
n8n-nodes-base.facebookGraphApi - facebookGraphApi
Config choices
Version 1

Block 5 - Download Video File

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 6 - Set Campaign ID

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 7 - Split Out

Type / Role
n8n-nodes-base.splitOut - splitOut
Config choices
Version 1

Block 8 - Start Video Annotation

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 3

Block 9 - If Ready

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 10 - Parse data

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 11 - Download Image File

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 12 - Video to Base64 String

Type / Role
n8n-nodes-base.extractFromFile - extractFromFile
Config choices
Version 1

Block 13 - Image to Base64 String

Type / Role
n8n-nodes-base.extractFromFile - extractFromFile
Config choices
Version 1

Block 14 - Start Image Annotation

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 3

Block 15 - Set id data for Static

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 16 - Set id data for Video

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 17 - Parse data from images

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 18 - Has image_url?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 19 - Loop for videos

Type / Role
n8n-nodes-base.splitInBatches - splitInBatches
Config choices
Version 3

Block 20 - Add errors

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.6

Block 21 - Check Operation Status

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 3

Block 22 - Add Segments data

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.6

Block 23 - Set (Video Error Row)

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 24 - Sticky Note Config

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Showing the first 24 of 32 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Analyze Meta ads creatives with Google Vision & Video Intelligence APIs
Complexity advanced
Nodes 32
Categories Market Research, Multimodal AI
Author Kirill Khatkevich
Published 12 Aug 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/7303/7303.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Analyze Meta ads creatives with Google Vision & Video Intelligence APIs do?

This workflow transforms your Meta Ads creatives into a rich dataset of actionable insights. It's designed for data driven marketers, performance agencies, and analysts who want to move beyond basi...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Market Research, Multimodal AI use case.