{
  "name": "Xiaohongshu (RedNote) Comments & Customer Sentiment Scraper — Automated Extraction to CSV & Sheets (UnitBytes)",
  "nodes": [
    {
      "parameters": {
        "content": "## ⚡ Xiaohongshu (RedNote) Comments & Customer Sentiment Scraper — Automated n8n Pipeline\n**Powered by [UnitBytes on Apify](https://apify.com/unitbytes/xiaohongshu-rednote-comments-scraper?fpr=939u3w&fp_sid=n8n_template)** ($0.00249 / item)\n\n### 🚀 30-Second Setup Instructions\n1. **Get your free Apify API Token**: Open [xiaohongshu-rednote-comments-scraper on Apify Store](https://apify.com/unitbytes/xiaohongshu-rednote-comments-scraper?fpr=939u3w&fp_sid=n8n_template) and copy your API token from **Settings → Integrations**.\n2. **Paste your token & search parameters**: Double-click the **\"1. Set Apify Token & Input\"** node and replace `YOUR_APIFY_API_TOKEN` with your token.\n3. **Click \"Test Workflow\"**: The HTTP Request node calls the synchronous UnitBytes Apify endpoint, normalizes the extracted records, and exports a clean CSV file ready for Google Sheets, Airtable, Slack, or OpenAI.\n\n📖 **Documentation & Schema Reference**: [https://unitbytes.com/actors/xiaohongshu-comments-scraper/](https://unitbytes.com/actors/xiaohongshu-comments-scraper/)",
        "height": 340,
        "width": 520,
        "color": 4
      },
      "id": "e45f5c35-7219-50ee-bb4d-df98d6cac821",
      "name": "Sticky Note — Setup Guide",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        180,
        80
      ]
    },
    {
      "parameters": {
        "content": "### 📊 Connect Your Destination\nThe **\"3. Normalize Output Fields\"** node outputs flat records (`id, noteId, noteUrl, content, likeCount`).\n\n- **Google Sheets / Airtable**: Connect a Google Sheets (`Append or Update Row`) node after Step 3.\n- **Slack / Telegram / Email Alerts**: Connect a Filter node + Slack node to alert your team on new deals or reviews.\n- **AI Agent / OpenAI**: Connect an OpenAI / LLM Chain node to summarize or classify extracted items.",
        "height": 220,
        "width": 420,
        "color": 5
      },
      "id": "e00aa7ac-ffda-5da9-ade9-62ba83e74c0e",
      "name": "Sticky Note — Destinations",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        880,
        140
      ]
    },
    {
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "hours",
              "hoursInterval": 24
            }
          ]
        }
      },
      "id": "bcec0cca-195c-5bb1-b7c0-e6610f15ee17",
      "name": "Schedule Trigger",
      "type": "n8n-nodes-base.scheduleTrigger",
      "typeVersion": 1.2,
      "position": [
        220,
        480
      ]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "9b8e9e41-fee9-52fe-82e3-a911b075100e",
              "name": "apifyToken",
              "value": "YOUR_APIFY_API_TOKEN",
              "type": "string"
            },
            {
              "id": "68e460d6-8ce6-5094-aaea-835a83d2950c",
              "name": "actorInput",
              "value": "{\"startUrls\": [{\"url\": \"https://www.xiaohongshu.com/explore/64256e08000000001300575e?xsec_token=ABivcR3TWdHqjbjX2xyNQkAS3_CZsrXHUX9r1tNqo4148=&xsec_source=pc_feed\"}], \"maxCommentsPerNote\": 50, \"maxSubCommentsPerComment\": 10, \"proxyConfiguration\": {\"useApifyProxy\": true, \"apifyProxyGroups\": [\"RESIDENTIAL\"], \"apifyProxyCountry\": \"HK\"}}",
              "type": "object"
            }
          ]
        },
        "options": {}
      },
      "id": "3c25b2e2-83d1-5903-aee5-b027beecb6fa",
      "name": "1. Set Apify Token & Input",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        460,
        480
      ]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "=https://api.apify.com/v2/acts/unitbytes~xiaohongshu-rednote-comments-scraper/run-sync-get-dataset-items?token={{ $json.apifyToken }}&format=json&clean=true",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "={{ JSON.stringify($json.actorInput) }}",
        "options": {
          "timeout": 300000
        }
      },
      "id": "095e864d-e4bb-5293-be5f-9207a1db7f72",
      "name": "2. Run UnitBytes (xiaohongshu-rednote-comments-scraper)",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [
        700,
        480
      ]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "53f7ea39-9ed7-57c8-af2e-cb5c4839b9e0",
              "name": "id",
              "value": "={{ $json.id }}",
              "type": "string"
            },
            {
              "id": "d933ab7f-6628-5041-8126-3afbe964b7fc",
              "name": "noteId",
              "value": "={{ $json.noteId }}",
              "type": "string"
            },
            {
              "id": "106cdf9a-1c7f-5fd9-bc14-80899cce9eed",
              "name": "noteUrl",
              "value": "={{ $json.noteUrl }}",
              "type": "string"
            },
            {
              "id": "4fd43712-69fc-5291-8fb1-19a28649513e",
              "name": "content",
              "value": "={{ $json.content }}",
              "type": "string"
            },
            {
              "id": "a48654bb-7877-57c1-a5f9-8ec553e323e2",
              "name": "likeCount",
              "value": "={{ $json.likeCount }}",
              "type": "string"
            },
            {
              "id": "580a6fec-4be9-513b-bba6-b04ae4fb027b",
              "name": "subCommentCount",
              "value": "={{ $json.subCommentCount }}",
              "type": "string"
            }
          ]
        },
        "includeOtherFields": true,
        "options": {}
      },
      "id": "7d2b4eba-de8b-5918-ab32-88dd022980df",
      "name": "3. Normalize Output Fields",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        940,
        480
      ]
    },
    {
      "parameters": {
        "operation": "csv",
        "options": {
          "fileName": "xiaohongshu-comments-scraper-dataset-export.csv"
        }
      },
      "id": "ace2ea6c-0d8b-5518-9cec-df08a64f164a",
      "name": "4. Export to CSV File",
      "type": "n8n-nodes-base.convertToFile",
      "typeVersion": 1.1,
      "position": [
        1180,
        480
      ]
    }
  ],
  "connections": {
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "1. Set Apify Token & Input",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "1. Set Apify Token & Input": {
      "main": [
        [
          {
            "node": "2. Run UnitBytes (xiaohongshu-rednote-comments-scraper)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2. Run UnitBytes (xiaohongshu-rednote-comments-scraper)": {
      "main": [
        [
          {
            "node": "3. Normalize Output Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3. Normalize Output Fields": {
      "main": [
        [
          {
            "node": "4. Export to CSV File",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "meta": {
    "templateCredsSetupCompleted": false,
    "instanceId": "030f9420-0ca8-5240-8fe8-208e287a8b19"
  },
  "tags": [
    {
      "name": "Web Scraping"
    },
    {
      "name": "Apify"
    },
    {
      "name": "UnitBytes"
    },
    {
      "name": "APAC E-Commerce & Social"
    }
  ]
}