AutomationFlowsAI & RAG › Workflow 2 — Content Review and Regeneration

Workflow 2 — Content Review and Regeneration

Workflow 2 — Content Review and Regeneration. Uses dataTable, chainLlm, httpRequest, lmChatOpenAi. Webhook trigger; 22 nodes.

Webhook trigger★★★★☆ complexityAI-powered22 nodesData TableChain LlmHTTP RequestOpenAI Chat
AI & RAG Trigger: Webhook Nodes: 22 Complexity: ★★★★☆ AI nodes: yes Added:

This workflow follows the Chainllm → HTTP Request recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "name": "Workflow 2 \u2014 Content Review and Regeneration",
  "nodes": [
    {
      "parameters": {
        "operation": "get",
        "dataTableId": {
          "__rl": true,
          "value": "",
          "mode": "list",
          "cachedResultName": "content_sessions",
          "cachedResultUrl": ""
        },
        "filters": {
          "conditions": [
            {
              "keyName": "session_id",
              "keyValue": "={{$json.body.session_id}}"
            }
          ]
        },
        "returnAll": true
      },
      "type": "n8n-nodes-base.dataTable",
      "typeVersion": 1.1,
      "position": [
        272,
        0
      ],
      "id": "c70d2ccd-7ae5-40a1-ad86-4a9698162851",
      "name": "Get row(s)"
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "b95f34d7-d280-4cc4-88f7-d148d0843c6d",
              "name": "review_action",
              "value": "={{ $('Webhook').item.json.body.review_action }}",
              "type": "string"
            },
            {
              "id": "ae834d79-b4e9-409b-bd89-67e283820086",
              "name": "status",
              "value": "={{ $json.status }}",
              "type": "string"
            },
            {
              "id": "f6cd2148-64a2-4a57-aaad-5a1af8a11e20",
              "name": "session_id",
              "value": "={{ $json.session_id }}",
              "type": "string"
            },
            {
              "id": "eae17468-1a3c-4547-8a28-94dd7804bc13",
              "name": "title_current",
              "value": "={{ $json.title_current }}",
              "type": "string"
            },
            {
              "id": "6059040c-e8b0-4079-8f2b-446af1fa470e",
              "name": "content_current",
              "value": "={{ $json.content_current }}",
              "type": "string"
            },
            {
              "id": "427d2925-a880-4ff9-be5a-6e700d819e10",
              "name": "category_current",
              "value": "={{ $json.category_current }}",
              "type": "string"
            },
            {
              "id": "4d83d634-500b-48b6-a294-814161187814",
              "name": "tags_current",
              "value": "={{ Array.isArray($json.tags_current) ? $json.tags_current : String($json.tags_current || \"\").startsWith(\"[\") ? JSON.parse($json.tags_current) : [] }}",
              "type": "array"
            },
            {
              "id": "91332666-d423-42ea-9a92-2e88e2dcba72",
              "name": "keyword_current",
              "value": "={{ $json.keyword_current }}",
              "type": "string"
            },
            {
              "id": "4f26eb19-3f76-4225-bdd9-6296e4180c7f",
              "name": "image_prompt_current",
              "value": "={{ $json.image_prompt_current }}",
              "type": "string"
            },
            {
              "id": "650cfcbb-f9bf-45bd-a0d5-dffb1a432ac9",
              "name": "publication_type",
              "value": "={{ $json.publication_type }}",
              "type": "string"
            },
            {
              "id": "e54f82e2-615b-4f8e-a06b-5dcde69956a2",
              "name": "formato_texto",
              "value": "={{ $json.formato_texto }}",
              "type": "string"
            },
            {
              "id": "ef1a8018-8c75-4d75-a092-bea7f910d49c",
              "name": "tono",
              "value": "={{ $json.tono }}",
              "type": "string"
            },
            {
              "id": "5b5b20eb-0475-4b61-aa55-f34ab43528ac",
              "name": "objetivo",
              "value": "={{ $json.objetivo }}",
              "type": "string"
            },
            {
              "id": "e38afa02-bc52-472f-90fa-19befe379456",
              "name": "publico_objetivo",
              "value": "={{ $json.publico_objetivo }}",
              "type": "string"
            },
            {
              "id": "ce6fec84-84fb-42bc-a6f8-2f70d8a57f9c",
              "name": "nivel_tecnico",
              "value": "={{ $json.nivel_tecnico}}",
              "type": "string"
            },
            {
              "id": "bf3752fc-15d7-4f51-b5ab-1d72031a7827",
              "name": "cta",
              "value": "={{ $json.cta }}",
              "type": "string"
            },
            {
              "id": "b42da08c-0668-45d9-a88d-29d3ab2f1f8e",
              "name": "custom_cta",
              "value": "={{ $json.custom_cta }}",
              "type": "string"
            },
            {
              "id": "d1ca2794-296c-4bf3-9838-e32e3183ff29",
              "name": "cta_intensity",
              "value": "={{ $json.cta_intensity }}",
              "type": "string"
            },
            {
              "id": "b104d822-7225-48ce-b05f-4c466b881a94",
              "name": "visual_style",
              "value": "={{ $json.visual_style }}",
              "type": "string"
            },
            {
              "id": "3b72fabb-6f92-4b0d-b15c-cacdfe544c3a",
              "name": "image_format",
              "value": "={{ $json.image_format }}",
              "type": "string"
            },
            {
              "id": "2adfe001-e35a-433f-97b2-df890d10ce39",
              "name": "visual_reference",
              "value": "={{ $json.visual_reference }}",
              "type": "string"
            },
            {
              "id": "fa08a67e-c401-4775-ad71-fd8c52276f6d",
              "name": "storytelling_format",
              "value": "={{ Boolean($json.storytelling_format) }}",
              "type": "boolean"
            },
            {
              "id": "76ae6c87-8d38-4e62-8248-9dfa7ea762cb",
              "name": "viral_format",
              "value": "={{ Boolean($json.viral_format) }}",
              "type": "boolean"
            },
            {
              "id": "450577ec-4e1a-4154-abbe-180c89cf523d",
              "name": "professional_linkedin_format",
              "value": "={{ Boolean($json.professional_linkedin_format) }}",
              "type": "boolean"
            },
            {
              "id": "0447ef47-618e-4a3c-89f0-341c559ced39",
              "name": "generate_image",
              "value": "={{ Boolean($json.generate_image) }}",
              "type": "boolean"
            },
            {
              "id": "281de770-5dd5-44cd-81f8-f47bf2fdf4e8",
              "name": "featured_media_id",
              "value": "={{ $json.featured_media_id }}",
              "type": "string"
            },
            {
              "id": "4d56e238-5866-45d3-bf0f-3785e7c807e0",
              "name": "image_current",
              "value": "={{ $json.image_current }}",
              "type": "string"
            },
            {
              "id": "930c1ac1-d709-477b-92a1-9d3444447109",
              "name": "image_current_id",
              "value": "={{ $json.image_current_id }}",
              "type": "string"
            },
            {
              "id": "32cc9f8f-29e7-4220-95d9-51169e16b0cc",
              "name": "text_versions",
              "value": "={{ JSON.stringify([\n  ...JSON.parse($json.text_versions || \"[]\"),\n  {\n    version: JSON.parse($json.text_versions || \"[]\").length + 1,\n    source: \"regenerated_text\",\n    title: $json.title_current,\n    content: $json.content_current\n  }\n]) }}",
              "type": "string"
            },
            {
              "id": "e83a21ef-cd4f-427e-b55b-5ae337000ba0",
              "name": "image_versions",
              "value": "={{ JSON.stringify([\n  ...JSON.parse($json.image_versions || \"[]\"),\n  {\n    version: JSON.parse($json.image_versions || \"[]\").length + 1,\n    source: \"regenerated_image\",\n    image: $json.image_current,\n    image_id: $json.featured_media_id\n  }\n]) }}",
              "type": "string"
            },
            {
              "id": "dcde72d1-1f25-41a3-bb1f-d62c4722ed27",
              "name": "created_at",
              "value": "={{ $json.created_at }}",
              "type": "string"
            },
            {
              "id": "99268e13-aaa3-48dc-bf3a-75e4086c1200",
              "name": "updated_at",
              "value": "={{ $now }}",
              "type": "string"
            },
            {
              "id": "0e07949d-92d5-401f-8071-159fd79d86a1",
              "name": "title_wordpress",
              "value": "={{ $json.title_wordpress }}",
              "type": "string"
            },
            {
              "id": "b9b95d5e-7841-4a07-9f06-92c4c56ebc9f",
              "name": "content_wordpress",
              "value": "={{ $json.content_wordpress }}",
              "type": "string"
            },
            {
              "id": "e1f87604-fee8-4b1c-8b07-129bb8921dcb",
              "name": "tags_wordpress",
              "value": "={{ $json.tags_wordpress }}",
              "type": "string"
            },
            {
              "id": "44a5f925-1beb-4207-aa0b-5f5f79bb615a",
              "name": "title_linkedin",
              "value": "={{ $json.title_linkedin }}",
              "type": "string"
            },
            {
              "id": "1d28bd62-fc0f-439a-8b6f-ebe87bdc2f35",
              "name": "content_linkedin",
              "value": "={{ $json.content_linkedin }}",
              "type": "string"
            },
            {
              "id": "9112773c-56fb-4a24-adcf-8dae3d81cf04",
              "name": "tags_linkedin",
              "value": "={{ $json.tags_linkedin }}",
              "type": "string"
            },
            {
              "id": "7f66ee85-85c6-4652-b40b-4e8733fa512b",
              "name": "title_facebook",
              "value": "={{ $json.title_facebook }}",
              "type": "string"
            },
            {
              "id": "2d8bc10f-e206-4ee5-a18c-5a4cdc7b6d4d",
              "name": "content_facebook",
              "value": "={{ $json.content_facebook }}",
              "type": "string"
            },
            {
              "id": "41f291e1-3988-4b72-a07e-2c59c0aab09d",
              "name": "tags_facebook",
              "value": "={{ $json.tags_facebook }}",
              "type": "string"
            },
            {
              "id": "90cc6b10-577c-4548-a3a8-f13312274177",
              "name": "title_instagram",
              "value": "={{ $json.title_instagram }}",
              "type": "string"
            },
            {
              "id": "8e010673-5c6d-45a8-9c86-6ab9fe82c3b6",
              "name": "content_instagram",
              "value": "={{ $json.content_instagram }}",
              "type": "string"
            },
            {
              "id": "660c0254-0147-4bec-9b47-5d23727dbd3f",
              "name": "tags_instagram",
              "value": "={{ $json.tags_instagram }}",
              "type": "string"
            },
            {
              "id": "cd326987-2289-4af6-9051-35498cfe7cdc",
              "name": "title_x",
              "value": "={{ $json.title_x }}",
              "type": "string"
            },
            {
              "id": "14aa6fc0-3deb-4937-acfa-4ad78b641a84",
              "name": "content_x",
              "value": "={{ $json.content_x }}",
              "type": "string"
            },
            {
              "id": "0795ac39-7d67-44b9-b437-13c6dc39617d",
              "name": "tags_x",
              "value": "={{ $json.tags_x }}",
              "type": "string"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        528,
        0
      ],
      "id": "baf1ff2c-2691-446a-abb1-bfb7a70994e5",
      "name": "Edit Fields"
    },
    {
      "parameters": {
        "rules": {
          "values": [
            {
              "conditions": {
                "options": {
                  "caseSensitive": true,
                  "leftValue": "",
                  "typeValidation": "strict",
                  "version": 3
                },
                "conditions": [
                  {
                    "id": "49489895-9848-4273-b2c8-c835fd76ab69",
                    "leftValue": "={{ $json.review_action }}",
                    "rightValue": "regenerate_text",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    }
                  }
                ],
                "combinator": "and"
              }
            },
            {
              "conditions": {
                "options": {
                  "caseSensitive": true,
                  "leftValue": "",
                  "typeValidation": "strict",
                  "version": 3
                },
                "conditions": [
                  {
                    "id": "9c76c6f0-df4b-423b-8638-f7e109371997",
                    "leftValue": "={{ $json.review_action }}",
                    "rightValue": "regenerate_image",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    }
                  }
                ],
                "combinator": "and"
              }
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.switch",
      "typeVersion": 3.4,
      "position": [
        1040,
        0
      ],
      "id": "49038362-2e54-47d9-b108-16371d4b697c",
      "name": "Switch (review_action)"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=Act\u00faa como un estratega senior de contenido, copywriter SEO, experto en growth marketing y especialista en contenido multicanal.\n\nLa publicaci\u00f3n ya fue generada anteriormente y ahora debe regenerarse como una NUEVA VERSI\u00d3N multicanal completa.\n\nDebes regenerar el contenido para:\n\n- WordPress / Blog\n- LinkedIn\n- X (Twitter)\n- Facebook\n- Instagram\n\nNO regeneres solo WordPress.\nNO devuelvas formato antiguo tipo TITLE / CONTENT.\nDevuelve SOLO JSON v\u00e1lido.\n\n====================================================================\nDATOS ACTUALES GUARDADOS\n====================================================================\n\nCategor\u00eda actual:\n{{ $('Get row(s)').item.json.category_current }}\n\nKeyword actual:\n{{ $('Get row(s)').item.json.keyword_current || \"\" }}\n\nT\u00edtulo WordPress actual:\n{{ $('Get row(s)').item.json.title_wordpress || $('Get row(s)').item.json.title_current }}\n\nContenido WordPress actual:\n{{ $('Get row(s)').item.json.content_wordpress || $('Get row(s)').item.json.content_current }}\n\nTags WordPress actuales:\n{{ $('Get row(s)').item.json.tags_wordpress || $('Get row(s)').item.json.tags_current }}\n\nT\u00edtulo LinkedIn actual:\n{{ $('Get row(s)').item.json.title_linkedin }}\n\nContenido LinkedIn actual:\n{{ $('Get row(s)').item.json.content_linkedin }}\n\nTags LinkedIn actuales:\n{{ $('Get row(s)').item.json.tags_linkedin }}\n\nT\u00edtulo X actual:\n{{ $('Get row(s)').item.json.title_x }}\n\nContenido X actual:\n{{ $('Get row(s)').item.json.content_x }}\n\nTags X actuales:\n{{ $('Get row(s)').item.json.tags_x }}\n\nT\u00edtulo Facebook actual:\n{{ $('Get row(s)').item.json.title_facebook }}\n\nContenido Facebook actual:\n{{ $('Get row(s)').item.json.content_facebook }}\n\nTags Facebook actuales:\n{{ $('Get row(s)').item.json.tags_facebook }}\n\nT\u00edtulo Instagram actual:\n{{ $('Get row(s)').item.json.title_instagram }}\n\nContenido Instagram actual:\n{{ $('Get row(s)').item.json.content_instagram }}\n\nTags Instagram actuales:\n{{ $('Get row(s)').item.json.tags_instagram }}\n\nImage prompt actual:\n{{ $('Get row(s)').item.json.image_prompt_current || \"\" }}\n\n====================================================================\nCONFIGURACI\u00d3N DEL USUARIO\n====================================================================\n\nIdioma:\n{{ $json.idioma || $json.payload?.idioma || $('Get row(s)').item.json.idioma }}\n\nTama\u00f1o:\n{{ $json.tamano || $json.payload?.tamano || $('Get row(s)').item.json.tamano }}\n\nDescripci\u00f3n / contexto:\n{{ $json.descripcion || $json.payload?.descripcion || $('Get row(s)').item.json.descripcion }}\n\nTono:\n{{ $json.tono || $json.payload?.tono || $('Get row(s)').item.json.tono }}\n\nObjetivo:\n{{ $json.objetivo || $json.payload?.objetivo || $('Get row(s)').item.json.objetivo }}\n\nP\u00fablico objetivo:\n{{ $json.publico_objetivo || $json.payload?.publicoObjetivo || $('Get row(s)').item.json.publico_objetivo }}\n\nNivel t\u00e9cnico:\n{{ $json.nivel_tecnico || $json.payload?.nivelTecnico || $('Get row(s)').item.json.nivel_tecnico }}\n\nFormato de texto:\n{{ $json.formato_texto || JSON.stringify($json.payload?.formatoTexto || \"\") || $('Get row(s)').item.json.formato_texto }}\n\nCTA:\n{{ $json.cta || $json.payload?.cta || $('Get row(s)').item.json.cta }}\n\nCTA personalizado:\n{{ $json.custom_cta || $json.payload?.customCta || $('Get row(s)').item.json.custom_cta }}\n\nIntensidad CTA:\n{{ $json.cta_intensity || $json.payload?.ctaIntensity || $('Get row(s)').item.json.cta_intensity }}\n\nTipo de publicaci\u00f3n:\n{{ $json.publication_type || $json.payload?.publication_type || $('Get row(s)').item.json.publication_type }}\n\nFormato storytelling:\n{{ $json.storytelling_format ?? $json.payload?.storytelling_format ?? $('Get row(s)').item.json.storytelling_format }}\n\nFormato viral:\n{{ $json.viral_format ?? $json.payload?.viral_format ?? $('Get row(s)').item.json.viral_format }}\n\nFormato LinkedIn profesional:\n{{ $json.professional_linkedin_format ?? $json.payload?.professional_linkedin_format ?? $('Get row(s)').item.json.professional_linkedin_format }}\n\n====================================================================\nOBJETIVO\n====================================================================\n\nGenera una nueva versi\u00f3n mejorada de los 5 contenidos.\n\nDebe mejorar:\n- claridad\n- estructura\n- engagement\n- legibilidad\n- SEO\n- autoridad\n- naturalidad\n- valor percibido\n- conversi\u00f3n\n\nNo hagas una simple par\u00e1frasis.\nReescribe y mejora el enfoque manteniendo el tema principal.\n\nMant\u00e9n:\n- misma categor\u00eda\n- misma keyword principal\n- mismo enfoque general\n- misma intenci\u00f3n de negocio\n\n====================================================================\nADAPTACI\u00d3N POR PLATAFORMA\n====================================================================\n\nWORDPRESS:\n- Art\u00edculo SEO en HTML.\n- Usa estructura clara.\n- Puede usar: <p>, <h2>, <h3>, <ul>, <ol>, <li>, <strong>, <b>.\n- No uses <h1>.\n- Longitud seg\u00fan tama\u00f1o:\n  - corto: 300-450 palabras\n  - estandar: 600-900 palabras\n  - largo/extenso: 1200-1600 palabras\n  - muy_extenso: 2000-3000 palabras\n\nLINKEDIN:\n- Profesional, humano, estrat\u00e9gico.\n- Hook inicial potente.\n- P\u00e1rrafos cortos.\n- Orientado a negocio.\n- Entre 800 y 2200 caracteres.\n\nX:\n- Directo, breve y de alto impacto.\n- M\u00e1ximo 280 caracteres por tweet.\n- Puede ser mini-hilo si es necesario, m\u00e1ximo 6 tweets.\n\nFACEBOOK:\n- Cercano, conversacional y \u00fatil.\n- Entre 500 y 1500 caracteres.\n\nINSTAGRAM:\n- Visual, emocional, escaneable.\n- Emojis moderados.\n- Entre 400 y 2200 caracteres.\n\n====================================================================\nFORMATO DE RESPUESTA OBLIGATORIO\n====================================================================\n\nDevuelve SOLO JSON v\u00e1lido.\nNo uses markdown.\nNo uses bloques de c\u00f3digo.\nNo a\u00f1adas texto fuera del JSON.\nTodos los campos deben existir.\n\n{\n  \"category\": \"\",\n  \"keyword\": \"\",\n\n  \"title_wordpress\": \"\",\n  \"content_wordpress\": \"\",\n  \"tags_wordpress\": \"\",\n\n  \"title_linkedin\": \"\",\n  \"content_linkedin\": \"\",\n  \"tags_linkedin\": \"\",\n\n  \"title_x\": \"\",\n  \"content_x\": \"\",\n  \"tags_x\": \"\",\n\n  \"title_facebook\": \"\",\n  \"content_facebook\": \"\",\n  \"tags_facebook\": \"\",\n\n  \"title_instagram\": \"\",\n  \"content_instagram\": \"\",\n  \"tags_instagram\": \"\",\n\n  \"image_prompt\": \"\"\n}",
        "batching": {}
      },
      "type": "@n8n/n8n-nodes-langchain.chainLlm",
      "typeVersion": 1.9,
      "position": [
        1408,
        -368
      ],
      "id": "ff871126-d3c5-4a5f-b090-9baa9dd5b2e6",
      "name": "Basic LLM Chain (texto)"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "=You are an expert AI art director specialized in creating high-converting editorial and social media visuals for blogs, LinkedIn, business websites and digital marketing campaigns.\n\nYour task is to generate a highly detailed and visually powerful image generation prompt in English.\n\nThe image must feel:\n- premium,\n- modern,\n- visually engaging,\n- professionally composed,\n- commercially attractive,\n- and aligned with the publication strategy provided below.\n\n========================\nCURRENT ARTICLE DATA\n========================\n\nCurrent title:\n{{ $('Get row(s)').item.json.title_current }}\n\nCurrent content:\n{{ $('Get row(s)').item.json.content_current }}\n\nCurrent category:\n{{ $('Get row(s)').item.json.category_current }}\n\nCurrent image description:\n{{ $json.caption?.rendered || $json.alt_text || \"\" }}\n\n========================\nUSER CONFIGURATION\n========================\n\nLanguage:\n{{ $json.payload.idioma }}\n\nSize:\n{{ $json.payload.tamano }}\n\nSuggested title:\n{{ $json.payload.titulo }}\n\nDescription:\n{{ $json.payload.descripcion }}\n\nCategory:\n{{ $json.payload.category }}\n\nCustom category:\n{{ $json.payload.customCategory }}\n\nKeyword:\n{{ $json.payload.keyword }}\n\nTags:\n{{ $json.payload.tags }}\n\nTone:\n{{ $json.payload.tono }}\n\nObjective:\n{{ $json.payload.objetivo }}\n\nTarget audience:\n{{ $json.payload.publicoObjetivo }}\n\nTechnical level:\n{{ $json.payload.nivelTecnico }}\n\nText format:\n{{ JSON.stringify($json.payload.formatoTexto) }}\n\nCTA:\n{{ $json.payload.cta }}\n\nCTA intensity:\n{{ $json.payload.ctaIntensity }}\n\nPublication type:\n{{ $json.payload.publication_type }}\n\nStorytelling format:\n{{ $json.payload.storytelling_format }}\n\nViral format:\n{{ $json.payload.viral_format }}\n\nProfessional LinkedIn format:\n{{ $json.payload.professional_linkedin_format }}\n\nVisual style:\n{{ $json.payload.visual_style }}\n\nImage format:\n{{ $json.payload.image_format }}\n\nVisual reference:\n{{ $json.payload.visual_reference }}\n\n========================\nCREATIVE DIRECTION\n========================\n\nCreate an image concept that:\n- perfectly represents the article topic,\n- feels visually unique,\n- avoids generic AI stock-image aesthetics,\n- and looks like a premium editorial cover image.\n\nThe image must visually reinforce:\n- the article message,\n- the emotional tone,\n- and the business objective.\n\n========================\nVISUAL STRATEGY\n========================\n\n1. Adapt the visual composition to the business objective:\n\n- If objective is \"Generate leads\":\n\u00a0\u00a0create trust, professionalism, aspiration and authority.\n\n- If objective is \"Branding\":\n\u00a0\u00a0prioritize premium aesthetics and strong visual identity.\n\n- If objective is \"Engagement\":\n\u00a0\u00a0create emotional impact, curiosity and visual dynamism.\n\n- If objective is \"Education\":\n\u00a0\u00a0focus on clarity, conceptual visualization and clean composition.\n\n- If objective is \"Sales\":\n\u00a0\u00a0emphasize transformation, results and business value.\n\n2. Adapt the image style to the target audience:\n\n- Clients / executives:\n\u00a0\u00a0premium corporate style, realistic environments, elegant composition.\n\n- Technical audience:\n\u00a0\u00a0more advanced technological interfaces, data visualization, futuristic details.\n\n- General audience:\n\u00a0\u00a0simplified concepts, cleaner storytelling visuals, accessible aesthetics.\n\n3. Adapt to the requested tone:\n- professional,\n- minimalist,\n- futuristic,\n- innovative,\n- elegant,\n- disruptive,\n- emotional,\n- etc.\n\n4. If storytelling_format = true:\n- create a cinematic narrative scene,\n- show action, progression or transformation,\n- include realistic contextual storytelling.\n\n5. If viral_format = true:\n- create a highly eye-catching composition,\n- stronger contrast,\n- dramatic lighting,\n- visual tension,\n- modern social-media-ready aesthetics.\n\n6. If professional_linkedin_format = true:\n- create a polished LinkedIn-style business visual,\n- elegant corporate branding feel,\n- premium editorial composition,\n- subtle business realism.\n\n========================\nIMAGE REQUIREMENTS\n========================\n\nMandatory:\n- No text inside the image\n- No letters\n- No captions\n- No logos\n- No watermarks\n\nThe image must be:\n- ultra detailed,\n- visually balanced,\n- realistic or semi-realistic,\n- highly polished,\n- professionally lit,\n- modern,\n- aesthetically premium.\n\nComposition:\n- clean focal point,\n- depth,\n- layered composition,\n- cinematic lighting,\n- realistic shadows,\n- high-end color grading.\n\nStyle:\nUse the requested visual style as the main artistic direction:\n{{ $json.payload.visual_style }}\n\nReference inspiration:\n{{ $json.payload.visual_reference }}\n\nAspect ratio:\n{{ $json.payload.image_format }}\n\n========================\nIMPORTANT\n========================\n\nAvoid:\n- generic AI visuals,\n- clich\u00e9 robot imagery,\n- floating holograms everywhere,\n- random business handshakes,\n- overused stock-photo aesthetics,\n- low-detail scenes,\n- chaotic compositions,\n- unrealistic anatomy,\n- visual clutter.\n\nThe image must feel:\n- premium,\n- intentional,\n- visually memorable,\n- and suitable for a high-quality professional publication.\n\n========================\nOUTPUT\n========================\n\nReturn ONLY the final image generation prompt in English.\n\nDo not add explanations.\nDo not use markdown.\nDo not add titles or labels.",
        "batching": {}
      },
      "type": "@n8n/n8n-nodes-langchain.chainLlm",
      "typeVersion": 1.9,
      "position": [
        1408,
        176
      ],
      "id": "15c70a27-b356-483c-9b38-6c2fa5a02913",
      "name": "Basic LLM Chain (imagen)"
    },
    {
      "parameters": {
        "content": "## Block 1 \u2013 Load Review Session\n",
        "height": 480,
        "width": 1316
      },
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -16,
        -176
      ],
      "id": "7be45fa0-08cc-4108-9f5b-c8f22655f1cd",
      "name": "Sticky Note"
    },
    {
      "parameters": {
        "content": "## Block 2 \u2013 Text Regeneration\n**Switch Output 1 always needs to be done manually again until you choose Output 0 or Output 2**",
        "height": 512,
        "width": 2052,
        "color": "#CCFFDB"
      },
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        1344,
        -496
      ],
      "id": "0c9fece3-d876-4004-80dc-294d27d589ce",
      "name": "Sticky Note1"
    },
    {
      "parameters": {
        "content": "## Block 2 \u2013 Image Regeneration\n\n**Switch Output 1 always needs to be done manually again until you choose Output 0 or Output 2**",
        "height": 592,
        "width": 1808,
        "color": "#B2FAB7"
      },
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        1344,
        32
      ],
      "id": "193ee3cf-5367-439a-9ebd-dc4af4897243",
      "name": "Sticky Note2"
    },
    {
      "parameters": {
        "mode": "runOnceForEachItem",
        "jsCode": "const row = $('Get row(s)').item.json;\nconst media = $('Upload Image').item.json;\n\n// URL e ID de la nueva imagen subida a WordPress\nconst newImageUrl =\n  media.source_url ||\n  media.guid?.rendered ||\n  media.guid?.raw ||\n  media.image_url ||\n  \"\";\n\nconst newFeaturedMediaId = media.id\n  ? Number(media.id)\n  : media.featured_media_id\n    ? Number(media.featured_media_id)\n    : null;\n\n// Versiones actuales de imagen\nconst currentVersionsRaw = row.image_versions || \"[]\";\n\nlet currentVersions = [];\ntry {\n  currentVersions =\n    typeof currentVersionsRaw === \"string\"\n      ? JSON.parse(row.image_versions || \"[]\")\n      : Array.isArray(row.image_versions)\n        ? row.image_versions\n        : [];\n} catch (e) {\n  currentVersions = [];\n}\n\n// A\u00f1adir nueva versi\u00f3n\ncurrentVersions.push({\n  version: currentVersions.length + 1,\n  source: \"regenerated_image\",\n\n  image: newImageUrl,\n  url: newImageUrl,\n  image_url: newImageUrl,\n\n  image_id: newFeaturedMediaId,\n  featured_media_id: newFeaturedMediaId,\n  media_id: newFeaturedMediaId,\n\n  accepted: true,\n  created_at: new Date().toISOString(),\n});\n\nreturn {\n  json: {\n    id: row.id,\n    session_id: row.session_id,\n\n    title_current: row.title_current,\n    content_current: row.content_current,\n\n    category_current: row.category_current,\n    tags_current: row.tags_current,\n\n    image_current: newImageUrl,\n    image_current_id: newFeaturedMediaId,\n    featured_media_id: newFeaturedMediaId,\n    featured_media: newFeaturedMediaId,\n\n    text_versions: row.text_versions,\n    image_versions: JSON.stringify(currentVersions),\n\n    keyword_current: row.keyword_current,\n    image_prompt_current: row.image_prompt_current,\n\n    idioma: row.idioma,\n    tamano: row.tamano,\n    descripcion: row.descripcion,\n    custom_category: row.custom_category,\n\n    publication_type: row.publication_type,\n    formato_texto: row.formato_texto,\n    tono: row.tono,\n    objetivo: row.objetivo,\n    publico_objetivo: row.publico_objetivo,\n    nivel_tecnico: row.nivel_tecnico,\n\n    cta: row.cta,\n    custom_cta: row.custom_cta,\n    cta_intensity: row.cta_intensity,\n\n    visual_style: row.visual_style,\n    image_format: row.image_format,\n    visual_reference: row.visual_reference,\n\n    storytelling_format: row.storytelling_format,\n    viral_format: row.viral_format,\n    professional_linkedin_format: row.professional_linkedin_format,\n    generate_image: row.generate_image,\n\n    review_action: \"none\",\n    status: \"reviewed\",\n    updated_at: new Date().toISOString(),\n  },\n};"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        2208,
        176
      ],
      "id": "7f2cd1bc-08eb-47de-a17e-203ebd6212a3",
      "name": "new image_versions"
    },
    {
      "parameters": {
        "url": "=https://image.pollinations.ai/prompt/{{ encodeURIComponent($json[\"text\"]) }}",
        "options": {
          "response": {
            "response": {
              "responseFormat": "file"
            }
          }
        }
      },
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.4,
      "position": [
        1696,
        176
      ],
      "id": "dcb784a0-2c58-49e6-83f4-01ce9381ef33",
      "name": "PollinationsAI"
    },
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "regenerate-social-content",
        "responseMode": "responseNode",
        "options": {}
      },
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2.1,
      "position": [
        0,
        0
      ],
      "id": "e6e94bea-2b33-4b16-b55e-779a3b9a7abe",
      "name": "Webhook"
    },
    {
      "parameters": {
        "options": {}
      },
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.5,
      "position": [
        3072,
        -384
      ],
      "id": "193f364b-382b-4c36-a8f3-80e0dacb03ff",
      "name": "Respond to Webhook"
    },
    {
      "parameters": {
        "options": {}
      },
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.5,
      "position": [
        2896,
        176
      ],
      "id": "f3be385e-e78b-45e9-a955-8b3f772349d0",
      "name": "Respond to Webhook1"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "",
          "mode": "list",
          "cachedResultName": "",
          "cachedResultUrl": ""
        },
        "builtInTools": {},
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.3,
      "position": [
        1408,
        -192
      ],
      "id": "ce82eeea-5ef5-4add-8959-bf4d0e64475a",
      "name": "OpenAI Chat Model",
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "",
          "mode": "list",
          "cachedResultName": "",
          "cachedResultUrl": ""
        },
        "builtInTools": {},
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.3,
      "position": [
        1408,
        368
      ],
      "id": "5d1d8c36-093c-4aca-8d4d-a0c2f52fe6a5",
      "name": "OpenAI Chat Model1",
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "operation": "update",
        "dataTableId": {
          "__rl": true,
          "value": "",
          "mode": "list",
          "cachedResultName": "content_sessions",
          "cachedResultUrl": ""
        },
        "filters": {
          "conditions": [
            {
              "keyValue": "={{ $json.id }}"
            }
          ]
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "status": "={{ $json.status }}",
            "review_action": "={{ $json.review_action }}",
            "content_current": "={{ $json.content_current }}",
            "text_versions": "={{ $json.text_versions }}",
            "featured_media_id": "={{ $json.featured_media_id }}",
            "featured_media": "={{ $json.featured_media_id }}",
            "session_id": "={{ $json.session_id }}",
            "title_current": "={{ $json.title_current }}",
            "category_current": "={{ $json.category_current }}",
            "tags_current": "={{ $json.tags_current }}",
            "image_current": "={{ $json.image_current }}",
            "image_versions": "={{ $json.image_versions }}",
            "updated_at": "={{ $json.updated_at }}",
            "keyword_current": "={{ $json.keyword_current }}",
            "visual_style": "={{ $json.visual_style }}",
            "image_format": "={{ $json.image_format }}",
            "tono": "={{ $json.tono }}",
            "formato_texto": "={{ $json.formato_texto }}",
            "publication_type": "={{ $json.publication_type }}",
            "nivel_tecnico": "={{ $json.nivel_tecnico }}",
            "publico_objetivo": "={{ $json.publico_objetivo }}",
            "objetivo": "={{ $json.objetivo }}",
            "visual_reference": "={{ $json.visual_reference }}",
            "storytelling_format": "={{ $json.storytelling_format }}",
            "viral_format": "={{ $json.viral_format }}",
            "professional_linkedin_format": "={{ $json.professional_linkedin_format }}",
            "cta": "={{ $json.cta }}",
            "custom_cta": "={{ $json.custom_cta }}",
            "cta_intensity": "={{ $json.cta_intensity }}",
            "idioma": "={{ $json.idioma }}",
            "tamano": "={{ $json.tamano }}",
            "custom_category": "={{ $json.custom_category }}",
            "descripcion": "={{ $json.descripcion }}",
            "image_prompt_current": "={{ $json.image_prompt_current }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "session_id",
              "displayName": "session_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "status",
              "displayName": "status",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_current",
              "displayName": "title_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_current",
              "displayName": "content_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "excerpt_current",
              "displayName": "excerpt_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "meta_current",
              "displayName": "meta_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "category_current",
              "displayName": "category_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "image_current",
              "displayName": "image_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tags_current",
              "displayName": "tags_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "text_versions",
              "displayName": "text_versions",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "image_versions",
              "displayName": "image_versions",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "created_at",
              "displayName": "created_at",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "dateTime",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "updated_at",
              "displayName": "updated_at",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "dateTime",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "review_action",
              "displayName": "review_action",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "wp_post_id",
              "displayName": "wp_post_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "wp_post_url",
              "displayName": "wp_post_url",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "featured_media_id",
              "displayName": "featured_media_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "featured_media",
              "displayName": "featured_media",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "number",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "keyword_current",
              "displayName": "keyword_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "image_prompt_current",
              "displayName": "image_prompt_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "objetivo",
              "displayName": "objetivo",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "publico_objetivo",
              "displayName": "publico_objetivo",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "nivel_tecnico",
              "displayName": "nivel_tecnico",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tono",
              "displayName": "tono",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "formato_texto",
              "displayName": "formato_texto",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "publication_type",
              "displayName": "publication_type",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "visual_style",
              "displayName": "visual_style",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "image_format",
              "displayName": "image_format",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "visual_reference",
              "displayName": "visual_reference",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "storytelling_format",
              "displayName": "storytelling_format",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "viral_format",
              "displayName": "viral_format",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "professional_linkedin_format",
              "displayName": "professional_linkedin_format",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "cta",
              "displayName": "cta",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "custom_cta",
              "displayName": "custom_cta",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "cta_intensity",
              "displayName": "cta_intensity",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "generate_image",
              "displayName": "generate_image",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "boolean",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "idioma",
              "displayName": "idioma",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tamano",
              "displayName": "tamano",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "custom_category",
              "displayName": "custom_category",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "descripcion",
              "displayName": "descripcion",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_wordpress",
              "displayName": "title_wordpress",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_wordpress",
              "displayName": "content_wordpress",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tags_wordpress",
              "displayName": "tags_wordpress",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_linkedin",
              "displayName": "title_linkedin",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_linkedin",
              "displayName": "content_linkedin",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tags_linkedin",
              "displayName": "tags_linkedin",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_x",
              "displayName": "title_x",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_x",
              "displayName": "content_x",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tags_x",
              "displayName": "tags_x",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_instagram",
              "displayName": "title_instagram",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_instagram",
              "displayName": "content_instagram",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tags_instagram",
              "displayName": "tags_instagram",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_facebook",
              "displayName": "title_facebook",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_facebook",
              "displayName": "content_facebook",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "tags_facebook",
              "displayName": "tags_facebook",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "linkedin_post_id",
              "displayName": "linkedin_post_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "facebook_post_id",
              "displayName": "facebook_post_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "instagram_post_id",
              "displayName": "instagram_post_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "x_post_id",
              "displayName": "x_post_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "linkedin_post_url",
              "displayName": "linkedin_post_url",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "facebook_post_url",
              "displayName": "facebook_post_url",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "instagram_post_url",
              "displayName": "instagram_post_url",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "x_post_url",
              "displayName": "x_post_url",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.dataTable",
      "typeVersion": 1.1,
      "position": [
        2448,
        176
      ],
      "id": "e04bd35e-7bf8-4608-ab0e-db396611dc9c",
      "name": "Update new image_versions"
    },
    {
      "parameters": {
        "operation": "update",
        "dataTableId": {
          "__rl": true,
          "value": "",
          "mode": "list",
          "cachedResultName": "content_sessions",
          "cachedResultUrl": ""
        },
        "filters": {
          "conditions": [
            {
              "keyValue": "={{ $json.id }}"
            }
          ]
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "status": "={{ $json.status }}",
            "review_action": "={{ $json.review_action }}",
            "content_current": "={{ $json.content_current }}",
            "text_versions": "={{ $json.text_versions }}",
            "featured_media_id": "={{ $json.featured_media_id }}",
            "featured_media": "={{ $json.featured_media_id }}",
            "session_id": "={{ $json.session_id }}",
            "title_current": "={{ $json.title_current }}",
            "category_current": "={{ $json.category_current }}",
            "image_current": "={{ $json.image_current }}",
            "image_versions": "={{ $json.image_versions }}",
            "updated_at": "={{ $json.updated_at }}",
            "keyword_current": "={{ $json.keyword_current }}",
            "visual_style": "={{ $json.visual_style }}",
            "image_format": "={{ $json.image_format }}",
            "tono": "={{ $json.tono }}",
            "formato_texto": "={{ $json.formato_texto }}",
            "publication_type": "={{ $json.publication_type }}",
            "nivel_tecnico": "={{ $json.nivel_tecnico }}",
            "publico_objetivo": "={{ $json.publico_objetivo }}",
            "objetivo": "={{ $json.objetivo }}",
            "visual_reference": "={{ $json.visual_reference }}",
            "storytelling_format": "={{ $json.storytelling_format }}",
            "viral_format": "={{ $json.viral_format }}",
            "professional_linkedin_format": "={{ $json.professional_linkedin_format }}",
            "cta": "={{ $json.cta }}",
            "custom_cta": "={{ $json.custom_cta }}",
            "cta_intensity": "={{ $json.cta_intensity }}",
            "idioma": "={{ $json.idioma }}",
            "tamano": "={{ $json.tamano }}",
            "custom_category": "={{ $json.custom_category }}",
            "descripcion": "={{ $json.descripcion }}",
            "image_prompt_current": "={{ $json.image_prompt_current }}",
            "title_wordpress": "={{ $json.title_wordpress }}",
            "content_wordpress": "={{ $json.content_wordpress }}",
            "content_linkedin": "={{ $json.content_linkedin }}",
            "tags_wordpress": "={{ $json.tags_wordpress }}",
            "title_x": "={{ $json.title_x }}",
            "title_linkedin": "={{ $json.title_linkedin }}",
            "tags_linkedin": "={{ $json.tags_linkedin }}",
            "tags_facebook": "={{ $json.tags_facebook }}",
            "content_x": "={{ $json.content_x }}",
            "content_instagram": "={{ $json.content_instagram }}",
            "tags_x": "={{ $json.tags_x }}",
            "title_facebook": "={{ $json.title_facebook }}",
            "title_instagram": "={{ $json.title_instagram }}",
            "tags_instagram": "={{ $json.tags_instagram }}",
            "content_facebook": "={{ $json.content_facebook }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "session_id",
              "displayName": "session_id",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "status",
              "displayName": "status",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "title_current",
              "displayName": "title_current",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "readOnly": false,
              "removed": false
            },
            {
              "id": "content_current",
              "displayName": "content_current",
              "required": false,
              "defaultMatch": f

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

Workflow 2 — Content Review and Regeneration. Uses dataTable, chainLlm, httpRequest, lmChatOpenAi. Webhook trigger; 22 nodes.

Source: https://github.com/arturolg20/n8n-social-media-automation-/blob/main/workflow-2-review-regeneration.json — original creator credit. Request a take-down →

More AI & RAG workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

AI & RAG

This workflow transforms natural language queries into research reports through a five-stage AI pipeline. When triggered via webhook (typically from Google Sheets using the companion [](https://gist.g

Redis, Agent, Output Parser Structured +7
AI & RAG

generación_publicaciones (workflow 1) webhook all platforms publicar git. Uses httpRequest, dataTable, lmChatOpenAi, chainLlm. Webhook trigger; 43 nodes.

HTTP Request, Data Table, OpenAI Chat +1
AI & RAG

Transform any Google Sheets cell into an intelligent web scraper! Type and get AI-filtered result from every website in ~20 seconds.

Agent, Mcp Client Tool, HTTP Request +4
AI & RAG

CLINICAINTEGRAL_secretary. Uses postgres, mcpClientTool, googleDriveTool, toolWorkflow. Webhook trigger; 89 nodes.

Postgres, Mcp Client Tool, Google Drive Tool +14
AI & RAG

This n8n workflow orchestrates a powerful suite of AI Agents and automations to manage and optimize various aspects of an e-commerce operation, particularly for platforms like Shopify. It leverages La

Google Sheets, HTTP Request, Slack +10