Mis flujos de trabajo

Avanzado

Este es unContent Creation, Multimodal AIflujo de automatización del dominio deautomatización que contiene 32 nodos.Utiliza principalmente nodos como Set, Wait, Limit, Filter, SplitOut. uso Apify、GPT-4o y Facebook 广告库进行竞争广告研究与图像generación

Requisitos previos
  • Credenciales de API de Google Drive
  • Pueden requerirse credenciales de autenticación para la API de destino
  • Credenciales de API de Google Sheets
  • Clave de API de OpenAI
Vista previa del flujo de trabajo
Visualización de las conexiones entre nodos, con soporte para zoom y panorámica
Exportar flujo de trabajo
Copie la siguiente configuración JSON en n8n para importar y usar este flujo de trabajo
{
  "meta": {
    "instanceId": "7a58a3f07a0fc2e793cb37fe49f8ad79d79b1752ef823a6ac87ff5a79f5b1fc9",
    "templateCredsSetupCompleted": true
  },
  "name": "My workflow",
  "tags": [
    {
      "id": "ayzol4JLAXjiRLWi",
      "name": "N8N Course",
      "createdAt": "2025-07-19T07:19:09.524Z",
      "updatedAt": "2025-07-19T07:19:09.524Z"
    }
  ],
  "nodes": [
    {
      "id": "95c7569d-ff47-43dc-86bf-d746783da7a2",
      "name": "Nota Adhesiva2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1216,
        288
      ],
      "parameters": {
        "width": 400,
        "height": 200,
        "content": "## 📱 STEP 1: Facebook Ad Library Scraping\n\nScrapes Facebook's Ad Library for competitor analysis:\n\n**Run Ad Library Scraper**: Uses Apify to extract active ads from Facebook\n**Filter**: Removes ads without images (video-only ads)\n**Limit**: Controls batch size for testing (adjust for production)\n\n**Setup**: Replace <your-apify-api-key-here> and customize search terms in the JSON body\n\n**Output**: 20+ competitor ads with images, metadata, and performance data"
      },
      "typeVersion": 1
    },
    {
      "id": "4b67c4ce-e808-44ba-95d3-0bd0e59b79d6",
      "name": "Nota Adhesiva3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        992,
        16
      ],
      "parameters": {
        "width": 420,
        "height": 200,
        "content": "## 🏗️ STEP 2: Google Drive Organization\n\nCreates structured folder system for asset management:\n\n1. **Create Asset Parent Folder**: Named after ad archive ID for unique organization\n2. **Create Child Source Folder**: Stores original competitor ads\n3. **Create Child Spun Folder**: Stores AI-generated variations\n4. **Download Static Image Ad**: Saves original ad to source folder\n\n**Result**: Organized Google Drive structure with source ads ready for AI analysis"
      },
      "typeVersion": 1
    },
    {
      "id": "e1b8e8a3-fc7d-440a-b509-1022dab42f79",
      "name": "Nota Adhesiva4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1216,
        640
      ],
      "parameters": {
        "width": 400,
        "height": 200,
        "content": "## 🤖 STEP 3: AI Analysis & Prompt Generation\n\nAnalyzes competitor ads and generates variation prompts:\n\n1. **OpenAI Vision**: Comprehensively describes each ad image\n2. **Spin Prompts**: Creates 3 different style variations per ad\n3. **Split Out**: Separates each variation for individual processing\n4. **Edit Fields**: Prepares data for loop processing\n\n**AI Magic**: Transforms \"bright blue background\" into \"minimalistic pastel design\" with brand customization"
      },
      "typeVersion": 1
    },
    {
      "id": "cf8f11fc-6c4c-4a98-9875-433a19c646fc",
      "name": "Nota Adhesiva5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        848,
        976
      ],
      "parameters": {
        "width": 420,
        "height": 220,
        "content": "## 🎨 STEP 4: AI Image Generation & Storage\n\nGenerates new ad variations and organizes results:\n\n**Loop Processing**: Handles each variation individually with rate limiting\n**GPT Image 1**: Creates new ads based on spun prompts while maintaining layout\n**Google Drive Upload**: Saves generated images to spun assets folder\n**Google Sheets Logging**: Tracks all ads with links for easy campaign management\n\n**Output**: 3+ unique ad variations per source ad, organized and ready for campaigns"
      },
      "typeVersion": 1
    },
    {
      "id": "72e1f19f-15b4-4f13-bd7e-5e52bcc01e25",
      "name": "Al hacer clic en 'Ejecutar flujo de trabajo'",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -656,
        32
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "a76ca1c3-285c-4840-a390-d7204585407b",
      "name": "Google Drive",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        -448,
        32
      ],
      "parameters": {
        "name": "PPC Thievery",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "list",
          "value": "root",
          "cachedResultName": "/ (Root folder)"
        },
        "resource": "folder"
      },
      "typeVersion": 3
    },
    {
      "id": "5116f412-d0f3-4aaa-a95c-516bae884d88",
      "name": "Nota Adhesiva",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -720,
        -128
      ],
      "parameters": {
        "color": 6,
        "width": 1140,
        "height": 340,
        "content": "## 1. Run once to create folder & database\n\n#### This generates your database (Google Sheet) and your parent folder (Google Drive). Once you have values for each, adjust the \"Set Variables\" node."
      },
      "typeVersion": 1
    },
    {
      "id": "aef6590c-937a-4bc7-a248-24dc41639a20",
      "name": "Filtrar",
      "type": "n8n-nodes-base.filter",
      "position": [
        80,
        464
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "00a1c88b-d177-4862-b82c-6dc1ce4291f7",
              "operator": {
                "type": "string",
                "operation": "exists",
                "singleValue": true
              },
              "leftValue": "={{ $json.snapshot.images[0].original_image_url }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "409aaa70-34ae-45d8-8d62-5065a8a389e6",
      "name": "Ejecutar Ad Library Scraper",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -160,
        464
      ],
      "parameters": {
        "url": "https://api.apify.com/v2/acts/XtaWFhbtfxyzqrFmd/run-sync-get-dataset-items",
        "method": "POST",
        "options": {
          "redirect": {
            "redirect": {}
          }
        },
        "jsonBody": "{\n    \"count\": 20,\n    \"period\": \"last7d\",\n    \"scrapeAdDetails\": true,\n    \"scrapePageAds.activeStatus\": \"active\",\n    \"urls\": [\n        {\n            \"url\": \"https://www.facebook.com/ads/library/?active_status=active&ad_type=all&country=US&is_targeted_country=false&media_type=all&q=agency&search_type=keyword_unordered\",\n            \"method\": \"GET\"\n        }\n    ]\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "headerParameters": {
          "parameters": [
            {
              "name": "Accept",
              "value": "application/json"
            },
            {
              "name": "Authorization",
              "value": "Bearer <your-apify-api-key-here>"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "3ea9c85f-e228-4278-bcda-d989fd98707c",
      "name": "Límite",
      "type": "n8n-nodes-base.limit",
      "position": [
        288,
        464
      ],
      "parameters": {
        "maxItems": 2
      },
      "typeVersion": 1
    },
    {
      "id": "4ca3f2d9-9036-469c-af6f-377ee7266659",
      "name": "Google Drive1",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        1392,
        464
      ],
      "parameters": {
        "name": "={{ $binary.data.fileName }}",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "list",
          "value": "root",
          "cachedResultName": "/ (Root folder)"
        }
      },
      "typeVersion": 3
    },
    {
      "id": "e6725a15-9250-4262-8bc2-303ab6e1ca05",
      "name": "OpenAI",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        -400,
        656
      ],
      "parameters": {
        "text": "What's in this image? Describe it extremely comprehensively. Leave nothing out.",
        "modelId": {
          "__rl": true,
          "mode": "list",
          "value": "chatgpt-4o-latest",
          "cachedResultName": "CHATGPT-4O-LATEST"
        },
        "options": {},
        "resource": "image",
        "imageUrls": "=https://drive.google.com/uc?export=download&id={{ $('Google Drive1').item.json.id }}",
        "operation": "analyze"
      },
      "typeVersion": 1.8
    },
    {
      "id": "adfd39a4-0845-42c6-82a4-2d953da97e52",
      "name": "Google Drive2",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        -608,
        656
      ],
      "parameters": {
        "fileId": {
          "__rl": true,
          "mode": "id",
          "value": "={{ $json.id }}"
        },
        "options": {},
        "operation": "share",
        "permissionsUi": {
          "permissionsValues": {
            "role": "writer",
            "type": "anyone"
          }
        }
      },
      "typeVersion": 3
    },
    {
      "id": "9e54072b-0208-4755-bb41-ce82907b202b",
      "name": "Establecer Variables",
      "type": "n8n-nodes-base.set",
      "position": [
        -368,
        464
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "402a3a15-e71a-4a1b-b235-31edd676d59b",
              "name": "googleDriveFolderId",
              "type": "string",
              "value": "1O_Uh4uvtqU9C9ntk9Rk-B2XhMLYxg_1Z"
            },
            {
              "id": "91e9cf54-7a74-4255-a322-44096d3e3af3",
              "name": "changeRequest",
              "type": "string",
              "value": "Spin this ad so that it features a minimalistic, pastel design. If there is any text on the page replace it with something like \"Upgrade your systems today\" or \"Get your flows optimized today\". If there are any assets on the page leave them as-is. Add a company name, LeftClick, in the bottom right hand corner, along with a little stylized mouse pointer icon."
            },
            {
              "id": "d3bd4796-3be4-4925-9467-e0f8ab2d6573",
              "name": "spreadsheetId",
              "type": "string",
              "value": "1-R45sKQJidkfffSwYAPsI-OLL-4CKSdYXIDkKfdcTVg"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "3994acec-9182-4085-ad98-d16bf19ba2b4",
      "name": "Spin Prompts",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        -176,
        656
      ],
      "parameters": {
        "modelId": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1",
          "cachedResultName": "GPT-4.1"
        },
        "options": {
          "temperature": 0.7
        },
        "messages": {
          "values": [
            {
              "role": "system",
              "content": "You're a helpful, intelligent prompt rewriting assistant. You help rewrite prompts."
            },
            {
              "content": "=I've generated an image description. I want you to take that image description and then give me a simple \"change request\" prompt I can use to tell an AI image editor what changes to make.\n\nReturn your output in the following JSON format:\n\n{\"variants\":[\"First change request\", \"Second change request\", \"Third change request\", \"etc\"]}\n\nRules:\n- Your task is to generate *new* change suggestions that we will later feed into an image generation model.\n- Changes you can make: font style (serif, sans-serif, display), font size, font leading, font tracking, font color, saturation, brightness, background color, background patterns, design style (flat, minimalistic, sleek, photoreal, etc—go nuts here), colors of assets on the page, swapping one asset for another that is more related to the change request.\n- Make these changes reasonable—we want to stick to the source pretty closely. Do not suggest any meaningful changes to the placement of assets. We want the elements all in the exact same place in the image, so only ever suggest color, style, asset type, font type, or copy changes.\n- Use the provided company name in the change request—never the original company name.\n- Generate 3 variants. No more, no less.\n- Adjust the copy so that it's relevant to an audience that wants \"AI automation\". Also make sure your generated copy is similar in length to the copy of the original.\n"
            },
            {
              "content": "{\"originalDescription\":\"The image features a promotional graphic with a bright blue background. Centered on the left is a layered design element consisting of two images. The top image shows a person sitting with a laptop, smiling, wearing a white jacket and blue jeans, with a background of green leaves and plants. Below this image is what appears to be a partially visible document with text and a table. \\n\\nSuperimposed at the top of the image is a white download arrow icon. Beneath the images, the text reads, \"Change your practice management software,\" in bold white lettering, with the words partially highlighted by a darker blue rectangle. This suggests a call to action or advertisement for software related to practice management.\", \"changeRequest\":\"Make it a soft, pastel orange; change text to something like 'Upgrade your systems today'. LeftClick logo with a mouse pointer icon (bottom right)\"}"
            },
            {
              "role": "assistant",
              "content": "{\"variants\":[\n  \"Make the background bright orange, swap the text for 'Upgrade your systems today', change it to sans-serif. Add a LeftClick logo with a mouse pointer icon positioned in the bottom right corner. Slightly more upscale style.\",\n  \"Switch the background to a clean white. Update the headline to say 'Optimize with LeftClick.' and clean, minimalistic serif font. Place the LeftClick logo and a minimalist arrow cursor icon in the top-left corner.\",\n  \"Set the background to a gradient from deep blue to turquoise. Change the text to 'Smarter systems start here.', play with the leading and tracking and make it a standout display font. Keep the LeftClick logo in the bottom right, but make it semi-transparent.\",\n  \"Use a charcoal grey background with high-contrast white text that says 'LeftClick powers performance.' Include a small pointer icon beside the logo in the bottom center.\",\n  \"Make the background electric lime green. Replace the message with 'Your automation partner: LeftClick.' Mouse pointer icon next to the logo in the lower-right, make the fonts hyper stylized.\"\n]\n}"
            },
            {
              "content": "={\"originalDescription\":\"{{ $json.content }}\", \"changeRequest\":\"{{ $('Set Variables').item.json.changeRequest }}\"} "
            }
          ]
        },
        "jsonOutput": true
      },
      "typeVersion": 1.8
    },
    {
      "id": "24ae679c-9a77-4d48-bf22-31318a716aea",
      "name": "Generar Imagen Usando GPT Image 1",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1072,
        656
      ],
      "parameters": {
        "url": "https://api.openai.com/v1/images/edits",
        "method": "POST",
        "options": {},
        "sendBody": true,
        "contentType": "multipart-form-data",
        "authentication": "predefinedCredentialType",
        "bodyParameters": {
          "parameters": [
            {
              "name": "model",
              "value": "gpt-image-1"
            },
            {
              "name": "image[]",
              "parameterType": "formBinaryData",
              "inputDataFieldName": "data"
            },
            {
              "name": "prompt",
              "value": "=Your task is to generate an image.\n\nHere is your prompt:\n\n{{ $('Loop Over Items').item.json.variant }}\n\nRules:\n- Stick as closely as possible to the outlines of the source document.\n- Change text, colors, shapes, and styles only if explicitly specified in the prompt. If something is not specified, do not change it.\n- If there is an actor and no style is specified, change the way they look a little so it's not the same actor. Only do this if the desired style is not a rendered, drawing, or cartoon version of them."
            },
            {
              "name": "size",
              "value": "1024x1024"
            }
          ]
        },
        "nodeCredentialType": "openAiApi"
      },
      "executeOnce": true,
      "typeVersion": 4.2
    },
    {
      "id": "c4909154-ea7d-47ae-88a3-323d0cee9f02",
      "name": "Bucle Sobre Elementos",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        608,
        656
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 3
    },
    {
      "id": "407e8a41-6fac-4f36-af80-494869e305e2",
      "name": "Esperar",
      "type": "n8n-nodes-base.wait",
      "position": [
        1952,
        656
      ],
      "webhookId": "e0023d56-efc1-4a82-b312-bc27f4ff837b",
      "parameters": {
        "amount": 1
      },
      "typeVersion": 1.1
    },
    {
      "id": "84161f30-a19c-48c5-aca1-6bfa4cf1f8f5",
      "name": "Dividir",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        192,
        656
      ],
      "parameters": {
        "include": "allOtherFields",
        "options": {},
        "fieldToSplitOut": "message.content.variants"
      },
      "typeVersion": 1
    },
    {
      "id": "f08995f3-d795-4124-aad4-85d778d2e8ad",
      "name": "Editar Campos",
      "type": "n8n-nodes-base.set",
      "position": [
        416,
        656
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "de128b60-4a0b-4736-876b-4bef0add0478",
              "name": "variant",
              "type": "string",
              "value": "={{ $json[\"message.content.variants\"] }}"
            },
            {
              "id": "6aa78def-4707-408a-8e9f-9c8b8fbe9381",
              "name": "imageAdUrl",
              "type": "string",
              "value": "={{ $('Filter').item.json.snapshot.images[0].original_image_url }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "3a6dc4a2-39e9-4281-b34b-944df22a4d6f",
      "name": "Descargar Imagen Estática Ad1",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        832,
        656
      ],
      "parameters": {
        "url": "={{ $json.imageAdUrl }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "3c845061-f894-4528-aafb-0bd8679086b1",
      "name": "Convertir a Archivo",
      "type": "n8n-nodes-base.convertToFile",
      "position": [
        1296,
        656
      ],
      "parameters": {
        "options": {},
        "operation": "toBinary",
        "sourceProperty": "data[0].b64_json"
      },
      "typeVersion": 1.1
    },
    {
      "id": "8c676162-4a03-4196-86ae-3d6a4e18ea68",
      "name": "Google Drive3",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        1520,
        656
      ],
      "parameters": {
        "name": "={{ $('Google Drive1').item.json.name }}",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "list",
          "value": "root",
          "cachedResultName": "/ (Root folder)"
        }
      },
      "typeVersion": 3
    },
    {
      "id": "6b856ae9-3709-4355-a57e-d8da62d3a041",
      "name": "Crear Carpeta Principal de Assets",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        512,
        464
      ],
      "parameters": {
        "name": "={{ $json.ad_archive_id }}",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "id",
          "value": "={{ $('Set Variables').item.json.googleDriveFolderId }}"
        },
        "resource": "folder"
      },
      "typeVersion": 3
    },
    {
      "id": "e802aa82-181f-40d5-ab3c-c0b270740979",
      "name": "Crear Carpeta Secundaria de Fuente",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        736,
        464
      ],
      "parameters": {
        "name": "=1. Source Assets",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "id",
          "value": "={{$json.id}}"
        },
        "resource": "folder"
      },
      "typeVersion": 3
    },
    {
      "id": "fe7a9a94-e0cd-4a35-9666-f07447775abc",
      "name": "Crear Carpeta Secundaria de Spun",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        928,
        464
      ],
      "parameters": {
        "name": "=2. Spun Assets",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "id",
          "value": "={{ $('Create Asset Parent Folder').item.json.id }}"
        },
        "resource": "folder"
      },
      "typeVersion": 3
    },
    {
      "id": "6c06d975-dbce-4111-933e-8193e0f3cb45",
      "name": "Descargar Imagen Estática Ad",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1168,
        464
      ],
      "parameters": {
        "url": "={{ $('Run Ad Library Scraper').item.json.snapshot.images[0].original_image_url }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "543a3114-31f6-4f87-a1bc-f7c0d8160099",
      "name": "Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1728,
        656
      ],
      "parameters": {
        "columns": {
          "value": {
            "ad_body": "={{ $('Run Ad Library Scraper').item.json.snapshot.body.text }}",
            "page_id": "={{ $('Run Ad Library Scraper').item.json.page_id }}",
            "page_name": "={{ $('Run Ad Library Scraper').item.json.page_name }}",
            "timestamp": "={{ $now.toSeconds() }}",
            "spun_folder": "=https://drive.google.com/drive/u/0/folders/{{ $('Create Child Spun Folder').item.json.id }}",
            "asset_folder": "=https://drive.google.com/drive/u/0/folders/{{ $('Create Asset Parent Folder').item.json.id }}",
            "date_scraped": "={{ $('Run Ad Library Scraper').item.json.start_date }}",
            "spun_prompts": "={{ $('Download Static Image Ad1').item.json.variant }}",
            "ad_archive_id": "={{ $('Run Ad Library Scraper').item.json.ad_archive_id }}",
            "source_folder": "=https://drive.google.com/drive/u/0/folders/{{ $('Create Child Source Folder').item.json.id }}",
            "original_image_url": "={{ $('Run Ad Library Scraper').item.json.snapshot.images[0].original_image_url }}",
            "direct_spun_image_link": "={{ $json.webViewLink }}"
          },
          "schema": [
            {
              "id": "timestamp",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "timestamp",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "ad_archive_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "ad_archive_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "page_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "page_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "original_image_url",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "original_image_url",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "page_name",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "page_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "ad_body",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "ad_body",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "date_scraped",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "date_scraped",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "spun_prompts",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "spun_prompts",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "asset_folder",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "asset_folder",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "source_folder",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "source_folder",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "spun_folder",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "spun_folder",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "direct_spun_image_link",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "direct_spun_image_link",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "name",
          "value": "scraped_ads"
        },
        "documentId": {
          "__rl": true,
          "mode": "id",
          "value": "={{ $('Set Variables').item.json.spreadsheetId }}"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "7ac56ea5-37b8-40ca-b177-68fbf84f4550",
      "name": "Google Sheets1",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -240,
        32
      ],
      "parameters": {
        "title": "PPC Thievery",
        "options": {},
        "resource": "spreadsheet",
        "sheetsUi": {
          "sheetValues": [
            {
              "title": "scraped_ads"
            }
          ]
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "9cd0a069-4728-4975-b699-596f5794a6b9",
      "name": "Google Sheets2",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        208,
        32
      ],
      "parameters": {
        "columns": {
          "value": {},
          "schema": [
            {
              "id": "timestamp",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "timestamp",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "ad_archive_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "ad_archive_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "page_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "page_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "original_image_url",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "original_image_url",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "page_name",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "page_name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "ad_body",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "ad_body",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "date_scraped",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "date_scraped",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "spun_prompts",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "spun_prompts",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "asset_folder",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "asset_folder",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "source_folder",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "source_folder",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "spun_folder",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "spun_folder",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "direct_spun_image_link",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "direct_spun_image_link",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "name",
          "value": "scraped_ads"
        },
        "documentId": {
          "__rl": true,
          "mode": "id",
          "value": "={{ $('Google Sheets1').item.json.spreadsheetId }}"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "93b2d8d7-a122-4a75-8bcd-7dd1bee31f5d",
      "name": "Editar Campos1",
      "type": "n8n-nodes-base.set",
      "position": [
        0,
        32
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "298bd00b-3410-47ec-95eb-af379f2966fa",
              "name": "timestamp",
              "type": "string",
              "value": ""
            },
            {
              "id": "c922e090-09cf-40b0-8787-b89f63af41c3",
              "name": "ad_archive_id",
              "type": "string",
              "value": ""
            },
            {
              "id": "854139e6-2696-4039-95d0-33d62b413dcb",
              "name": "page_id",
              "type": "string",
              "value": ""
            },
            {
              "id": "c9422756-a649-403b-b080-38a2c6ef66d7",
              "name": "original_image_url",
              "type": "string",
              "value": ""
            },
            {
              "id": "8a3c6e68-9f8d-4955-a10b-81b24a7296c5",
              "name": "page_name",
              "type": "string",
              "value": ""
            },
            {
              "id": "6bcc6c5d-4115-4ca4-bdb4-08458a3764ba",
              "name": "ad_body",
              "type": "string",
              "value": ""
            },
            {
              "id": "fe4e7b13-f9ca-4684-8fc2-824a33fe8cb5",
              "name": "date_scraped",
              "type": "string",
              "value": ""
            },
            {
              "id": "28d2210d-1bf8-40cd-bde6-201bdc62b2c0",
              "name": "spun_prompts",
              "type": "string",
              "value": ""
            },
            {
              "id": "d8f16995-1d73-42da-b7f0-fb9cfb974ea0",
              "name": "asset_folder",
              "type": "string",
              "value": ""
            },
            {
              "id": "9323586a-7d73-4c22-978d-30f4f35b11d0",
              "name": "source_folder",
              "type": "string",
              "value": ""
            },
            {
              "id": "64abb9e9-2d0f-4120-b1dc-f0a349815223",
              "name": "spun_folder",
              "type": "string",
              "value": ""
            },
            {
              "id": "1a580ae0-0004-4b6a-85ae-23aa96e30ec8",
              "name": "direct_spun_image_link",
              "type": "string",
              "value": ""
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "5d48773d-77d7-43a9-a362-ef2fb77d861b",
      "name": "Nota Adhesiva1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -720,
        288
      ],
      "parameters": {
        "color": 6,
        "width": 2860,
        "height": 620,
        "content": "## 2. Update \"Set Variables\" and \"Run Ad Library Scraper\" and run.\n\n#### This flow starts by running an Ad Library Scraper, generating Google Drive scaffolding for organizational purposes, and then analyzes incoming image ads with OpenAI -> spins the prompt. For each spun prompt, it then generates a new, spun image, and uploads it back to your Google Drive before logging it in your Sheet."
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "",
  "connections": {
    "407e8a41-6fac-4f36-af80-494869e305e2": {
      "main": [
        [
          {
            "node": "c4909154-ea7d-47ae-88a3-323d0cee9f02",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3ea9c85f-e228-4278-bcda-d989fd98707c": {
      "main": [
        [
          {
            "node": "6b856ae9-3709-4355-a57e-d8da62d3a041",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "aef6590c-937a-4bc7-a248-24dc41639a20": {
      "main": [
        [
          {
            "node": "3ea9c85f-e228-4278-bcda-d989fd98707c",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "e6725a15-9250-4262-8bc2-303ab6e1ca05": {
      "main": [
        [
          {
            "node": "3994acec-9182-4085-ad98-d16bf19ba2b4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "84161f30-a19c-48c5-aca1-6bfa4cf1f8f5": {
      "main": [
        [
          {
            "node": "f08995f3-d795-4124-aad4-85d778d2e8ad",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "f08995f3-d795-4124-aad4-85d778d2e8ad": {
      "main": [
        [
          {
            "node": "c4909154-ea7d-47ae-88a3-323d0cee9f02",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "93b2d8d7-a122-4a75-8bcd-7dd1bee31f5d": {
      "main": [
        [
          {
            "node": "9cd0a069-4728-4975-b699-596f5794a6b9",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "a76ca1c3-285c-4840-a390-d7204585407b": {
      "main": [
        [
          {
            "node": "7ac56ea5-37b8-40ca-b177-68fbf84f4550",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3994acec-9182-4085-ad98-d16bf19ba2b4": {
      "main": [
        [
          {
            "node": "84161f30-a19c-48c5-aca1-6bfa4cf1f8f5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "4ca3f2d9-9036-469c-af6f-377ee7266659": {
      "main": [
        [
          {
            "node": "adfd39a4-0845-42c6-82a4-2d953da97e52",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "adfd39a4-0845-42c6-82a4-2d953da97e52": {
      "main": [
        [
          {
            "node": "e6725a15-9250-4262-8bc2-303ab6e1ca05",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8c676162-4a03-4196-86ae-3d6a4e18ea68": {
      "main": [
        [
          {
            "node": "543a3114-31f6-4f87-a1bc-f7c0d8160099",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "543a3114-31f6-4f87-a1bc-f7c0d8160099": {
      "main": [
        [
          {
            "node": "407e8a41-6fac-4f36-af80-494869e305e2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9e54072b-0208-4755-bb41-ce82907b202b": {
      "main": [
        [
          {
            "node": "409aaa70-34ae-45d8-8d62-5065a8a389e6",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "7ac56ea5-37b8-40ca-b177-68fbf84f4550": {
      "main": [
        [
          {
            "node": "93b2d8d7-a122-4a75-8bcd-7dd1bee31f5d",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3c845061-f894-4528-aafb-0bd8679086b1": {
      "main": [
        [
          {
            "node": "8c676162-4a03-4196-86ae-3d6a4e18ea68",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "c4909154-ea7d-47ae-88a3-323d0cee9f02": {
      "main": [
        [],
        [
          {
            "node": "3a6dc4a2-39e9-4281-b34b-944df22a4d6f",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "409aaa70-34ae-45d8-8d62-5065a8a389e6": {
      "main": [
        [
          {
            "node": "aef6590c-937a-4bc7-a248-24dc41639a20",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "fe7a9a94-e0cd-4a35-9666-f07447775abc": {
      "main": [
        [
          {
            "node": "6c06d975-dbce-4111-933e-8193e0f3cb45",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6c06d975-dbce-4111-933e-8193e0f3cb45": {
      "main": [
        [
          {
            "node": "4ca3f2d9-9036-469c-af6f-377ee7266659",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3a6dc4a2-39e9-4281-b34b-944df22a4d6f": {
      "main": [
        [
          {
            "node": "24ae679c-9a77-4d48-bf22-31318a716aea",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "6b856ae9-3709-4355-a57e-d8da62d3a041": {
      "main": [
        [
          {
            "node": "e802aa82-181f-40d5-ab3c-c0b270740979",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "e802aa82-181f-40d5-ab3c-c0b270740979": {
      "main": [
        [
          {
            "node": "fe7a9a94-e0cd-4a35-9666-f07447775abc",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "24ae679c-9a77-4d48-bf22-31318a716aea": {
      "main": [
        [
          {
            "node": "3c845061-f894-4528-aafb-0bd8679086b1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "72e1f19f-15b4-4f13-bd7e-5e52bcc01e25": {
      "main": [
        [
          {
            "node": "a76ca1c3-285c-4840-a390-d7204585407b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Preguntas frecuentes

¿Cómo usar este flujo de trabajo?

Copie el código de configuración JSON de arriba, cree un nuevo flujo de trabajo en su instancia de n8n y seleccione "Importar desde JSON", pegue la configuración y luego modifique la configuración de credenciales según sea necesario.

¿En qué escenarios es adecuado este flujo de trabajo?

Avanzado - Creación de contenido, IA Multimodal

¿Es de pago?

Este flujo de trabajo es completamente gratuito, puede importarlo y usarlo directamente. Sin embargo, tenga en cuenta que los servicios de terceros utilizados en el flujo de trabajo (como la API de OpenAI) pueden requerir un pago por su cuenta.

Flujos de trabajo relacionados recomendados

Información del flujo de trabajo
Nivel de dificultad
Avanzado
Número de nodos32
Categoría2
Tipos de nodos13
Descripción de la dificultad

Adecuado para usuarios avanzados, flujos de trabajo complejos con 16+ nodos

Autor
Nick Saraev

Nick Saraev

@nicksaraev

Hi 👋 I'm Nick. I make money with automation & teach others how they can too. If you have any questions about my templates or about my n8n builds, feel free to ask and I'll happily respond in the comments. Thanks for reading!

Enlaces externos
Ver en n8n.io

Compartir este flujo de trabajo

Categorías

Categorías: 34