{
  "id": "rzsA39jMfVBHWXw6",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "Extract Product Information from Website Screenshots using Dumpling AI and Google Sheets",
  "tags": [],
  "nodes": [
    {
      "id": "c9ac00c8-038f-4490-a5a5-517a3c0cd143",
      "name": "Watch for New Screenshot URLs in Google Sheets",
      "type": "n8n-nodes-base.googleSheetsTrigger",
      "position": [
        -320,
        -80
      ],
      "parameters": {
        "event": "rowAdded",
        "options": {},
        "pollTimes": {
          "item": [
            {
              "mode": "everyMinute"
            }
          ]
        },
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1So9Yh1Xa5Z_ebQ2i_YwQ4p6Q-kwR1zTVzvjUTE4RveU/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1So9Yh1Xa5Z_ebQ2i_YwQ4p6Q-kwR1zTVzvjUTE4RveU/edit?usp=drivesdk",
          "cachedResultName": "URL-n8n"
        }
      },
      "credentials": {
        "googleSheetsTriggerOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "568cbb00-dda1-45d1-a1be-4fc0e2c6820c",
      "name": "Create Screenshot File via Dumpling AI",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -100,
        -80
      ],
      "parameters": {
        "url": "https://app.dumplingai.com/api/v1/screenshot",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"url\":\"{{ $('Watch for New Screenshot URLs in Google Sheets').item.json.Site}}\",\n  \"blockCookieBanners\": true,\n  \"autoScroll\": true\n}\n",
        "sendBody": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth"
      },
      "credentials": {
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "bdc11a1f-7730-436f-9778-7304f36629a4",
      "name": "Download Screenshot Image File from Dumpling AI",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        120,
        -80
      ],
      "parameters": {
        "url": "={{ $json.screenshotUrl }}",
        "options": {}
      },
      "typeVersion": 4.2
    },
    {
      "id": "277f34b9-670a-4f7b-9b89-144e9e54f9fb",
      "name": "Extract Text from Screenshot with Dumpling AI",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        560,
        -80
      ],
      "parameters": {
        "url": "https://app.dumplingai.com/api/v1/extract-image",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"inputMethod\": \"base64\",\n  \"images\": [\"{{$json.data}}\"],\n  \"prompt\": \"Look at the image and extract the following details if they are visible: the product name, the price, any discount or sale information, and the star rating. Only include information that is clearly shown in the image. Do not guess or assume anything that is not visible.\",\n  \"jsonMode\": true\n}\n",
        "sendBody": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth"
      },
      "credentials": {
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "60ca0901-44c6-4d37-9a6b-4bf7535f48f1",
      "name": "Convert Image File to Base64",
      "type": "n8n-nodes-base.extractFromFile",
      "position": [
        340,
        -80
      ],
      "parameters": {
        "options": {},
        "operation": "binaryToPropery"
      },
      "typeVersion": 1
    },
    {
      "id": "a6e902a8-c89b-493b-bb37-a013eef534b4",
      "name": "Format Extracted Data for Google Sheets",
      "type": "n8n-nodes-base.set",
      "position": [
        780,
        -80
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "48f8ee4b-098e-4d03-9fa2-3ce5639cd7c9",
              "name": "results",
              "type": "string",
              "value": "={{ $json.results }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "f4964366-293e-4889-999d-e5ee35b9eac2",
      "name": "Save extracted data to Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1000,
        -80
      ],
      "parameters": {
        "columns": {
          "value": {
            "Site": "={{ $('Watch for New Screenshot URLs in Google Sheets').item.json.Site }}",
            "product": "={{ $json.results }}"
          },
          "schema": [
            {
              "id": "Site",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "Site",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "product",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "product",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "Site"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "appendOrUpdate",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1So9Yh1Xa5Z_ebQ2i_YwQ4p6Q-kwR1zTVzvjUTE4RveU/edit#gid=0",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1So9Yh1Xa5Z_ebQ2i_YwQ4p6Q-kwR1zTVzvjUTE4RveU",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1So9Yh1Xa5Z_ebQ2i_YwQ4p6Q-kwR1zTVzvjUTE4RveU/edit?usp=drivesdk",
          "cachedResultName": "URL-n8n"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "c0494151-6f50-4f9b-ab90-52eb20f65402",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -300,
        -340
      ],
      "parameters": {
        "width": 680,
        "height": 300,
        "content": "### \ud83d\uddbc\ufe0f Automated Product Data Extraction from Website Screenshots\n\nThis workflow starts when a new row is added in Google Sheets containing a product page URL. It triggers Dumpling AI to capture a screenshot of the site. The image is downloaded using an HTTP Request, then converted from binary to base64. Dumpling AI is called again to extract product information (like product name, price, discount, and ratings) directly from the screenshot. The Edit Fields node maps all the extracted details, and the final Google Sheets node updates your spreadsheet with the structured product data next to the original URL.\n\nUse this workflow to save hours of manual copy-paste work, speed up cataloging, and ensure your product database is always fresh and accurate.\n\n"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "23ffdb67-8e7e-410c-a0cf-60c674716aba",
  "connections": {
    "Convert Image File to Base64": {
      "main": [
        [
          {
            "node": "Extract Text from Screenshot with Dumpling AI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Save extracted data to Google Sheets": {
      "main": [
        []
      ]
    },
    "Create Screenshot File via Dumpling AI": {
      "main": [
        [
          {
            "node": "Download Screenshot Image File from Dumpling AI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Format Extracted Data for Google Sheets": {
      "main": [
        [
          {
            "node": "Save extracted data to Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Text from Screenshot with Dumpling AI": {
      "main": [
        [
          {
            "node": "Format Extracted Data for Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Watch for New Screenshot URLs in Google Sheets": {
      "main": [
        [
          {
            "node": "Create Screenshot File via Dumpling AI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download Screenshot Image File from Dumpling AI": {
      "main": [
        [
          {
            "node": "Convert Image File to Base64",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}