AI 製品画像ジェネレーター - 公開テンプレート

中級

これはContent Creation, Multimodal AI分野の自動化ワークフローで、15個のノードを含みます。主にCode, GoogleDrive, HttpRequest, GoogleSheets, ConvertToFileなどのノードを使用。 OpenAI・Gemini・Google Workspace を使用した自動製品広告画像の作成

前提条件
  • Google Drive API認証情報
  • ターゲットAPIの認証情報が必要な場合あり
  • Google Sheets API認証情報
  • OpenAI API Key
ワークフロープレビュー
ノード接続関係を可視化、ズームとパンをサポート
ワークフローをエクスポート
以下のJSON設定をn8nにインポートして、このワークフローを使用できます
{
  "meta": {
    "templateCredsSetupCompleted": false
  },
  "name": "AI Product Image Generator - Public Template",
  "tags": [],
  "nodes": [
    {
      "id": "16c2ca1d-8986-4533-9bf2-aba9fd0efe61",
      "name": "download_influencer_image",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        960,
        320
      ],
      "parameters": {
        "fileId": {
          "__rl": true,
          "mode": "url",
          "value": "={{ $('Get the Raw').item.json['Model url'] }}"
        },
        "options": {},
        "operation": "download"
      },
      "credentials": {
        "googleDriveOAuth2Api": {
          "id": "YOUR_GOOGLE_DRIVE_CREDENTIAL_ID",
          "name": "Google Drive OAuth2 API"
        }
      },
      "typeVersion": 3
    },
    {
      "id": "9def7a44-23bb-4735-b363-901ac7191efb",
      "name": "upload_image",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        1040,
        736
      ],
      "parameters": {
        "name": "=Ad Image {{ $runIndex + 1 }}",
        "driveId": {
          "__rl": true,
          "mode": "list",
          "value": "My Drive",
          "cachedResultUrl": "https://drive.google.com/drive/my-drive",
          "cachedResultName": "My Drive"
        },
        "options": {},
        "folderId": {
          "__rl": true,
          "mode": "list",
          "value": "YOUR_OUTPUT_FOLDER_ID",
          "cachedResultUrl": "https://drive.google.com/drive/folders/YOUR_OUTPUT_FOLDER_ID",
          "cachedResultName": "Ad Images Output Folder"
        }
      },
      "credentials": {
        "googleDriveOAuth2Api": {
          "id": "YOUR_GOOGLE_DRIVE_CREDENTIAL_ID",
          "name": "Google Drive OAuth2 API"
        }
      },
      "typeVersion": 3
    },
    {
      "id": "42e5857c-b566-4ebd-9bc5-ef5cb900e3ce",
      "name": "Analyze image",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        -64,
        736
      ],
      "parameters": {
        "text": "Analyze the provided product image and generate a detailed ad-ready visual description. Focus on how the product can look its best in a promotional image. Include suggestions for:\n\nThe model (male or female) and how they should pose, hold, or interact with the product naturally.\n\nLighting, background, and environment that highlight the product.\n\nStyling, color harmony, and composition to make the product stand out.\n\nMood or emotion the ad should convey.\n\nDo not include details about the specific model in the image. The description should be suitable for any model and emphasize the product's features and presentation.",
        "modelId": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini",
          "cachedResultName": "GPT-4O-MINI"
        },
        "options": {},
        "resource": "image",
        "inputType": "base64",
        "operation": "analyze"
      },
      "credentials": {
        "openAiApi": {
          "id": "YOUR_OPENAI_CREDENTIAL_ID",
          "name": "OpenAI API"
        }
      },
      "typeVersion": 1.8
    },
    {
      "id": "cf18eb77-e961-4d4f-b7c4-bd6ac81e1751",
      "name": "スケジュールトリガー",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -112,
        320
      ],
      "parameters": {
        "rule": {
          "interval": [
            {}
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "ddd3fd77-5079-4c58-9bc1-cdb6862eb4f4",
      "name": "Download Product Image",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        336,
        320
      ],
      "parameters": {
        "fileId": {
          "__rl": true,
          "mode": "url",
          "value": "={{ $json['Product url'] }}"
        },
        "options": {},
        "operation": "download"
      },
      "credentials": {
        "googleDriveOAuth2Api": {
          "id": "YOUR_GOOGLE_DRIVE_CREDENTIAL_ID",
          "name": "Google Drive OAuth2 API"
        }
      },
      "typeVersion": 3
    },
    {
      "id": "5a328387-8506-4e53-8347-7f76fcf0df38",
      "name": "Convert Binary to Text",
      "type": "n8n-nodes-base.extractFromFile",
      "position": [
        672,
        320
      ],
      "parameters": {
        "options": {},
        "operation": "binaryToPropery"
      },
      "typeVersion": 1
    },
    {
      "id": "f30a0657-152a-4233-888c-3a71fc965bb4",
      "name": "Get the Raw",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        112,
        320
      ],
      "parameters": {
        "options": {},
        "filtersUI": {
          "values": [
            {
              "lookupValue": "={{ $json.Month }} {{ $json['Day of month'] }}, {{ $json.Year }}",
              "lookupColumn": "Date"
            }
          ]
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/YOUR_SPREADSHEET_ID/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "YOUR_SPREADSHEET_ID",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/YOUR_SPREADSHEET_ID/edit",
          "cachedResultName": "Product Schedule Spreadsheet"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "YOUR_GOOGLE_SHEETS_CREDENTIAL_ID",
          "name": "Google Sheets OAuth2 API"
        }
      },
      "typeVersion": 4.7
    },
    {
      "id": "8121809f-b1ec-49e7-bca3-5e1ee95b1b3b",
      "name": "influencer_image_Convert_to_Text",
      "type": "n8n-nodes-base.extractFromFile",
      "position": [
        1200,
        320
      ],
      "parameters": {
        "options": {},
        "operation": "binaryToPropery"
      },
      "typeVersion": 1
    },
    {
      "id": "b4e31c1d-29d1-4214-80cb-bc9133b72a7b",
      "name": "Image Generation",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        224,
        736
      ],
      "parameters": {
        "url": "https://openrouter.ai/api/v1/chat/completions",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"model\": \"google/gemini-2.5-flash-image-preview\",\n  \"prompt\": \"{{ $json.content }}\",\n  \"image_inputs\": [\n    {\n      \"image\": \"{{ $json.data }}\",\n      \"mime_type\": \"image/png\"\n    },\n    {\n      \"image\": \"{{ $('Convert Binary to Text').item.json.data }}\",\n      \"mime_type\": \"image/jpeg\"\n    }\n  ]\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer YOUR_OPENROUTER_API_KEY"
            },
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "cce44841-176e-48f5-9196-3abf2f284cca",
      "name": "base64 cleanup",
      "type": "n8n-nodes-base.code",
      "position": [
        464,
        736
      ],
      "parameters": {
        "jsCode": "// Loop over all items\nreturn items.map(item => {\n  // Make a copy of the item to avoid mutation\n  let newItem = { ...item };\n\n  // Check if the path exists\n  if (newItem.json.choices && newItem.json.choices[0].images && newItem.json.choices[0].images[0].image_url) {\n    let imageData = newItem.json.choices[0].images[0].image_url.url;\n\n    // Remove the prefix\n    if (imageData.startsWith(\"data:image/png;base64,\")) {\n      imageData = imageData.replace(\"data:image/png;base64,\", \"\");\n    }\n\n    // Update the value\n    newItem.json.choices[0].images[0].image_url.url = imageData;\n  }\n\n  return newItem;\n});\n"
      },
      "typeVersion": 2
    },
    {
      "id": "c91456d5-1e1f-4c70-90bf-94da0f9bfb46",
      "name": "ファイルに変換",
      "type": "n8n-nodes-base.convertToFile",
      "position": [
        672,
        736
      ],
      "parameters": {
        "options": {},
        "operation": "toBinary",
        "sourceProperty": "choices[0].images[0].image_url.url"
      },
      "typeVersion": 1.1
    },
    {
      "id": "cbc50b85-4b16-4aca-b26b-f5f7ba764c2b",
      "name": "Update Spreadsheet with Results",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1264,
        736
      ],
      "parameters": {
        "columns": {
          "value": {
            "Date": "={{ $('Get the Raw').item.json.Date }}",
            "Publish": "Publish",
            "Ad Image Ready To Post": "={{ $json.webContentLink }}"
          },
          "schema": [
            {
              "id": "Product url",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Product url",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Model url",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Model url",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Ad Image Ready To Post",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "Ad Image Ready To Post",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Date",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "Date",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Publish",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Publish",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "Date"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "appendOrUpdate",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/YOUR_SPREADSHEET_ID/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "YOUR_SPREADSHEET_ID",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/YOUR_SPREADSHEET_ID/edit",
          "cachedResultName": "Product Schedule Spreadsheet"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "YOUR_GOOGLE_SHEETS_CREDENTIAL_ID",
          "name": "Google Sheets OAuth2 API"
        }
      },
      "typeVersion": 4.7
    },
    {
      "id": "52545f4b-1a5c-4e4a-b9ed-f5a1788f536f",
      "name": "付箋",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -160,
        96
      ],
      "parameters": {
        "width": 1696,
        "height": 448,
        "content": "## Step 1: Trigger & Data Preparation\n- **Schedule Trigger** → Runs daily at a defined interval.  \n- **Google Sheets (Get Row)** → Fetch product + model image URLs for today's date.  \n- **Google Drive (Download Product Image)** → Get product image.  \n- **Google Drive (Download Influencer Image)** → Get influencer/model image.  \n- **Convert Binary → Base64 (Product)** → Prepare product image for AI input.  \n- **Convert Binary → Base64 (Influencer)** → Prepare influencer image for AI input.  \n\n***"
      },
      "typeVersion": 1
    },
    {
      "id": "b80eff1b-cdca-4679-bad1-646f0c3033eb",
      "name": "付箋1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -160,
        560
      ],
      "parameters": {
        "color": 5,
        "width": 1008,
        "height": 368,
        "content": "## Step 2: AI Analysis & Image Generation\n- **OpenAI (Analyze Image)** → Generate an ad-focused description (lighting, styling, background, mood).  \n- **HTTP Request (OpenRouter Gemini)** → Combine product + influencer images into a new ad-ready visual.  \n- **Code Node (Cleanup)** → Strip `data:image/...;base64,` prefix from the AI output.  \n- **Convert Base64 → File** → Turn AI output into a usable image file. "
      },
      "typeVersion": 1
    },
    {
      "id": "1a744b30-6ca9-45fb-b1b6-a5bb612302ba",
      "name": "付箋2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        864,
        560
      ],
      "parameters": {
        "color": 3,
        "width": 672,
        "height": 368,
        "content": "## Step 3: Save & Update\n- **Google Drive (Upload Image)** → Save the generated ad image in the correct folder.  \n- **Google Sheets (Append / Update Row)** → Store the Google Drive link + mark status as \"Publish\".  \n"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "connections": {
    "f30a0657-152a-4233-888c-3a71fc965bb4": {
      "main": [
        [
          {
            "node": "ddd3fd77-5079-4c58-9bc1-cdb6862eb4f4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9def7a44-23bb-4735-b363-901ac7191efb": {
      "main": [
        [
          {
            "node": "cbc50b85-4b16-4aca-b26b-f5f7ba764c2b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "42e5857c-b566-4ebd-9bc5-ef5cb900e3ce": {
      "main": [
        [
          {
            "node": "b4e31c1d-29d1-4214-80cb-bc9133b72a7b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "cce44841-176e-48f5-9196-3abf2f284cca": {
      "main": [
        [
          {
            "node": "Convert to File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Convert to File": {
      "main": [
        [
          {
            "node": "9def7a44-23bb-4735-b363-901ac7191efb",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "b4e31c1d-29d1-4214-80cb-bc9133b72a7b": {
      "main": [
        [
          {
            "node": "cce44841-176e-48f5-9196-3abf2f284cca",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "f30a0657-152a-4233-888c-3a71fc965bb4",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "5a328387-8506-4e53-8347-7f76fcf0df38": {
      "main": [
        [
          {
            "node": "16c2ca1d-8986-4533-9bf2-aba9fd0efe61",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "ddd3fd77-5079-4c58-9bc1-cdb6862eb4f4": {
      "main": [
        [
          {
            "node": "5a328387-8506-4e53-8347-7f76fcf0df38",
            "type": "main",
            "index": 0
          },
          {
            "node": "42e5857c-b566-4ebd-9bc5-ef5cb900e3ce",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "16c2ca1d-8986-4533-9bf2-aba9fd0efe61": {
      "main": [
        [
          {
            "node": "8121809f-b1ec-49e7-bca3-5e1ee95b1b3b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8121809f-b1ec-49e7-bca3-5e1ee95b1b3b": {
      "main": [
        [
          {
            "node": "b4e31c1d-29d1-4214-80cb-bc9133b72a7b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
よくある質問

このワークフローの使い方は?

上記のJSON設定コードをコピーし、n8nインスタンスで新しいワークフローを作成して「JSONからインポート」を選択、設定を貼り付けて認証情報を必要に応じて変更してください。

このワークフローはどんな場面に適していますか?

中級 - コンテンツ作成, マルチモーダルAI

有料ですか?

このワークフローは完全無料です。ただし、ワークフローで使用するサードパーティサービス(OpenAI APIなど)は別途料金が発生する場合があります。

関連ワークフロー

再生リスト詳細設定ボットコピー
Suno、GPT-4、Runway、Creatomate を使って AI 生成の YouTube ミュージックプレイリストを作成
If
Set
Code
+
If
Set
Code
203 ノードJoseph
コンテンツ作成
OpenAI、ElevenLabs、Hedraを使用してウイルスのな赤ちゃんポッドキャストYouTubeショートビデオを作成する
OpenAI、ElevenLabs、およびHedraを使用してウイルスのな赤ちゃんPodcastのYouTubeショートビデオを作成する
Code
Wait
Merge
+
Code
Wait
Merge
38 ノードElectrabot
コンテンツ作成
AI、Hedra、ElevenLabsでウイルスのなベイビー名前のPodcastを生成する
AI、Hedra、ElevenLabsを使ってウイルスのな赤ちゃん有名人のなポッドキャストを生成
Code
Wait
Merge
+
Code
Wait
Merge
35 ノードLeeWei
コンテンツ作成
AI駆動型動画制作&Instagram/TikTok/YouTubeへの自動アップロード
クラウドドライブからAI駆動の動画作成およびInstagram、TikTok、YouTubeへのアップロード
If
Set
Code
+
If
Set
Code
53 ノードDevCode Journey
コンテンツ作成
WordPressブログの自動化プロフェッショナル版(先端研究)v2.1マーケットプラグイン
GPT-4o、Perplexity AI、そして多言語対応を使ったSEO最適化ブログ作成の自動化
If
Set
Xml
+
If
Set
Xml
125 ノードDaniel Ng
コンテンツ作成
OpenAI、ElevenLabs、Fal.ai を使用した動画・パ odcast・ASM R向けのウイルス性コンテンツ自動作成
OpenAI、ElevenLabs、そして Fal.ai を使って動画、ポッドキャスト、ASMR に向けたウイルスのコンテンツ作成を自動化
Set
Code
Wait
+
Set
Code
Wait
97 ノードAdam Crafts
コンテンツ作成
ワークフロー情報
難易度
中級
ノード数15
カテゴリー2
ノードタイプ9
難易度説明

経験者向け、6-15ノードの中程度の複雑さのワークフロー

作成者
Avkash Kakdiya

Avkash Kakdiya

@itechnotion

🚀 Founder of iTechNotion — we build custom AI-powered automation workflows for startups, agencies, and founders. 💡 Specializing in agentic AI systems, content automation, sales funnels, and digital workers. 🔧 14+ years in tech | Building scalable no-code/low-code solutions using n8n, OpenAI, and other API-first tools. 📬 Let’s automate what slows you down.

外部リンク
n8n.ioで表示

このワークフローを共有

カテゴリー

カテゴリー: 34