8
n8n 中文网amn8n.com

使用 youtube-transcript.io 获取免费 YouTube 字幕并保存到 Supabase

高级

这是一个自动化工作流,包含 37 个节点。主要使用 If, Set, Code, Wait, Merge 等节点。 使用 youtube-transcript.io 获取免费 YouTube 字幕并保存到 Supabase

前置要求
  • Supabase URL 和 API Key
  • 可能需要目标 API 的认证凭证

分类

-
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "meta": {
    "instanceId": "8bdf363d6f1444e891759be2b805fdd240d84e9615b1a1f01b8f4c91c2145754",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "dd646cab-5e67-44b8-bc0f-4732d17fa239",
      "name": "等待",
      "type": "n8n-nodes-base.wait",
      "position": [
        6208,
        304
      ],
      "webhookId": "e232fe90-b3f7-47b5-bb5b-92eae61a03cc",
      "parameters": {
        "amount": 30
      },
      "typeVersion": 1.1
    },
    {
      "id": "e6ad7969-fc50-48e5-869a-8969f23fabe5",
      "name": "频道信息",
      "type": "n8n-nodes-base.set",
      "position": [
        1072,
        192
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "7f952495-fb69-43fd-a42e-518d631b7456",
              "name": "youtubeChannels",
              "type": "string",
              "value": "={{ $json.source_identifier }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "30d46acf-b6ea-4d7d-80ae-0d7b1bc2af93",
      "name": "频道信息 + 频道 ID",
      "type": "n8n-nodes-base.set",
      "position": [
        1568,
        192
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "91bee9e2-9c54-4b87-920f-0221e6939c88",
              "name": "rssUrl",
              "type": "string",
              "value": "={{ $json.rssUrl }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "e2b70f78-b995-4eb4-8b91-822d01bc416a",
      "name": "转录成功?",
      "type": "n8n-nodes-base.if",
      "position": [
        5104,
        112
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "fd22fed6-00aa-4d9a-94d5-58bb78f16bd1",
              "operator": {
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $json.statusMessage }}",
              "rightValue": "OK"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "9169295f-4ad4-43a4-9c81-f94f3dc6db5c",
      "name": "新视频信息",
      "type": "n8n-nodes-base.set",
      "notes": "TEST CONTENT:\n[\n  {\n    \"client_id\": \"80d1c63b-59d6-479b-b7f7-ee91e859987e\",\n    \"max_content_age_days\": \"60\",\n    \"author\": \"Ted Talk\",\n    \"title\": \"Mental Toughness\",\n    \"link\": \"https://www.youtube.com/watch?v=rNxC16mlO60\",\n    \"pubDate\": \"2025-08-14T01:17:49.000Z\",\n    \"isMyContent\": null,\n    \"authority_score\": null,\n    \"niche_keywords\": null\n  }\n]\n",
      "position": [
        4336,
        128
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "a87b5163-a235-4806-bb4a-d5795ac3634a",
              "name": "author",
              "type": "string",
              "value": "={{ $json.author }}"
            },
            {
              "id": "eb2aebb9-820b-43a8-81b7-e56d559ec8c4",
              "name": "title",
              "type": "string",
              "value": "={{ $json.title }}"
            },
            {
              "id": "6b2efe1f-c03a-4952-8599-7f9c6581699e",
              "name": "link",
              "type": "string",
              "value": "={{ $json.link }}"
            },
            {
              "id": "e31d8325-c92a-48f2-9741-024f4d4fe0fe",
              "name": "pubDate",
              "type": "string",
              "value": "={{ $json.pubDate }}"
            }
          ]
        },
        "includeOtherFields": true
      },
      "typeVersion": 3.4
    },
    {
      "id": "3e2bec8f-26a2-4fe2-a044-20a146ac2cd3",
      "name": "验证频道 ID + 创建 RSS 链接",
      "type": "n8n-nodes-base.code",
      "position": [
        1296,
        192
      ],
      "parameters": {
        "mode": "runOnceForEachItem",
        "jsCode": "// ── Pull the fields we need from the incoming item ─────────────────────────────\nconst channelId       = $json[\"youtubeChannels\"];\nconst authorityScore  = $json[\"authority_score\"];\nconst nicheKeywords   = $json[\"niche_keywords\"];\n\nconsole.log(\n  `Channel: ${channelId}, authority: ${authorityScore}, ` +\n  `keywords: ${nicheKeywords?.length || 0}`\n);\n\n// ── Skip if the channel ID is missing or blank ────────────────────────────────\nif (!channelId || channelId.trim() === '') {\n  return null;\n}\n\n// ── Only keep well-formed YouTube channel IDs (start with “UC”, 24 chars) ─────\nif (channelId.startsWith('UC') && channelId.length === 24) {\n  return {\n    channelId,\n    rssUrl: `https://www.youtube.com/feeds/videos.xml?channel_id=${channelId}`,\n    authority_score: authorityScore,\n    niche_keywords: nicheKeywords,\n    success: true\n  };\n} else {\n  console.log(`❌ Invalid Channel ID format: ${channelId}`);\n  return null;  // Skip invalid IDs\n}"
      },
      "retryOnFail": true,
      "typeVersion": 2,
      "alwaysOutputData": true
    },
    {
      "id": "e6b9852b-72a0-4926-a94d-2ae76268c294",
      "name": "尝试重新获取 video_id",
      "type": "n8n-nodes-base.code",
      "position": [
        4304,
        -32
      ],
      "parameters": {
        "jsCode": "// YouTube Video ID Extractor - returns `video_id`\nfunction extractYouTubeVideoId(url) {\n  if (!url || typeof url !== 'string') {\n    return null;\n  }\n  const regex = /(?:youtube\\.com\\/(?:[^\\/\\n\\s]+\\/\\S+\\/|(?:v|e(?:mbed)?|shorts)\\/|.*[?&]v=)|youtu\\.be\\/)([a-zA-Z0-9_-]{11})/i;\n  const match = url.match(regex);\n  return match && match[1] ? match[1] : null;\n}\n\nconst input = $input.all();\nconst results = [];\n\nfor (const item of input) {\n  const url =\n    item.json.url ||\n    item.json.video_url ||\n    item.json.youtube_url ||\n    (typeof item.json === 'string' ? item.json : '');\n  const id = extractYouTubeVideoId(url);\n  results.push({\n    original_url: url,\n    video_id: id,\n    is_valid: id !== null,\n    clean_url: id ? `https://www.youtube.com/watch?v=${id}` : null,\n  });\n}\n\nreturn results;\n"
      },
      "typeVersion": 2
    },
    {
      "id": "1331abca-fcc2-46de-9144-2f89be68213d",
      "name": "遍历每个频道",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        1840,
        192
      ],
      "parameters": {
        "options": {}
      },
      "retryOnFail": true,
      "typeVersion": 3,
      "waitBetweenTries": 3000
    },
    {
      "id": "c04ca824-9f49-44e1-a9b4-db579ef796b9",
      "name": "遍历新视频",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        2512,
        -96
      ],
      "parameters": {
        "options": {}
      },
      "retryOnFail": true,
      "typeVersion": 3
    },
    {
      "id": "17a7a2fe-e3ac-44b2-8d06-5b9df4b32dc7",
      "name": "是否找到视频 ID?",
      "type": "n8n-nodes-base.if",
      "position": [
        3920,
        -96
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "ddb872f1-00b7-45e4-9d9c-02fbcacc8173",
              "operator": {
                "type": "boolean",
                "operation": "true",
                "singleValue": true
              },
              "leftValue": "={{ $json.is_valid }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "4d7a1a8d-bbd5-4563-bbe8-48e0b8f6e57a",
      "name": "将转录添加到视频数据",
      "type": "n8n-nodes-base.merge",
      "position": [
        5568,
        -80
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "combineBy": "combineByPosition"
      },
      "typeVersion": 3.2
    },
    {
      "id": "112ff980-abe2-48c5-baff-132f8112fb84",
      "name": "转录失败",
      "type": "n8n-nodes-base.stopAndError",
      "position": [
        5360,
        288
      ],
      "parameters": {
        "errorMessage": "Transcript Failed"
      },
      "typeVersion": 1
    },
    {
      "id": "a6ed463f-8109-48d8-8732-315ac82cb7ab",
      "name": "合并视频 ID 与视频数据",
      "type": "n8n-nodes-base.merge",
      "position": [
        4544,
        -96
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "combineBy": "combineByPosition"
      },
      "typeVersion": 3.2
    },
    {
      "id": "45bc327e-e5b3-49bc-b844-b7f45d971de7",
      "name": "重命名 URL",
      "type": "n8n-nodes-base.set",
      "position": [
        4112,
        -32
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "6e3e0929-a6d9-44a8-85f8-aab2a863b15b",
              "name": "url",
              "type": "string",
              "value": "={{ $json.original_url }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "c06e03b7-61c2-44af-a700-791a742e0fb5",
      "name": "重命名原始 URL",
      "type": "n8n-nodes-base.set",
      "position": [
        3024,
        -96
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "78fb6dce-dd95-4d98-9df6-436a1491683a",
              "name": "original_url",
              "type": "string",
              "value": "={{ $json.link }}"
            }
          ]
        },
        "includeOtherFields": true
      },
      "typeVersion": 3.4
    },
    {
      "id": "363eb243-6ccb-4fbb-80f5-b12ea716fd73",
      "name": "查找视频 ID",
      "type": "n8n-nodes-base.set",
      "position": [
        3248,
        -96
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "f5928422-6fb1-44d8-9c7e-4e3c3fc643ae",
              "name": "video_id",
              "type": "string",
              "value": "={{ $json.original_url.match(/(?:youtube\\.com\\/(?:[^\\/\\n\\s]+\\/\\S+\\/|(?:v|e(?:mbed)?|shorts)\\/|.*[?&]v=)|youtu\\.be\\/)([a-zA-Z0-9_-]{11})/i)?.[1] || null }}"
            }
          ]
        },
        "includeOtherFields": true
      },
      "typeVersion": 3.4
    },
    {
      "id": "502e8cf5-4f21-4f5c-aa23-d9ca3ca6c3db",
      "name": "视频 ID 是否有效?",
      "type": "n8n-nodes-base.set",
      "position": [
        3472,
        -96
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "b0a840da-4cef-4a4c-bfd2-14e0afa06f5d",
              "name": "is_valid",
              "type": "boolean",
              "value": "={{ $json.original_url.match(/(?:youtube\\.com\\/(?:[^\\/\\n\\s]+\\/\\S+\\/|(?:v|e(?:mbed)?|shorts)\\/|.*[?&]v=)|youtu\\.be\\/)([a-zA-Z0-9_-]{11})/i) !== null }}"
            }
          ]
        },
        "includeOtherFields": true
      },
      "typeVersion": 3.4
    },
    {
      "id": "85381b7a-8d37-4a7c-913c-12b358be8050",
      "name": "清理 URL",
      "type": "n8n-nodes-base.set",
      "position": [
        3696,
        -96
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "3add2b91-4a26-4a33-b982-bd90a3bf2790",
              "name": "clean_url",
              "type": "string",
              "value": "={{ $json.video_id ? `https://www.youtube.com/watch?v=${$json.video_id}` : null }}"
            }
          ]
        },
        "includeOtherFields": true
      },
      "typeVersion": 3.4
    },
    {
      "id": "7db930ef-f892-45fa-836b-012657b70df0",
      "name": "便签1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        384,
        -240
      ],
      "parameters": {
        "color": 3,
        "width": 2016,
        "height": 768,
        "content": "## **第 1 部分:获取最新视频**"
      },
      "typeVersion": 1
    },
    {
      "id": "4c5f0b41-f6df-49cd-b0e7-98d59006ecbc",
      "name": "便签3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2416,
        -240
      ],
      "parameters": {
        "color": 5,
        "width": 3984,
        "height": 768,
        "content": "## **第 2 部分:视频转录**"
      },
      "typeVersion": 1
    },
    {
      "id": "c2a1b787-4f13-4723-9836-36dba96e6173",
      "name": "便签4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        5744,
        -192
      ],
      "parameters": {
        "color": 4,
        "width": 304,
        "height": 560,
        "content": "## **第 3 部分:将转录保存到某处!"
      },
      "typeVersion": 1
    },
    {
      "id": "90ae1bb6-9422-41ab-85d7-e82e18f088c1",
      "name": "查找频道的视频",
      "type": "n8n-nodes-base.rssFeedRead",
      "position": [
        2080,
        288
      ],
      "parameters": {
        "url": "={{ $json.rssUrl }}",
        "options": {}
      },
      "retryOnFail": true,
      "typeVersion": 1.1
    },
    {
      "id": "60253e86-9d4f-4963-8b57-8d699da9b085",
      "name": "要跟踪的频道",
      "type": "n8n-nodes-base.set",
      "position": [
        544,
        192
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "71df3a21-e1b2-4906-b0ef-dd0d93f6cca5",
              "name": "source_identifier",
              "type": "array",
              "value": "={{ ['UCaEkuhQejDMyindRnUbISIg', 'UCIPPMRA040LQr5QPyJEbmXA'] }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "6a613354-f29e-4bc4-9684-207ef19d5b7d",
      "name": "拆分输出",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        816,
        192
      ],
      "parameters": {
        "options": {},
        "fieldToSplitOut": "source_identifier"
      },
      "typeVersion": 1
    },
    {
      "id": "59f43f15-dbbc-4dac-8162-4dc367996503",
      "name": "### 需要帮助?",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        736,
        -80
      ],
      "parameters": {
        "color": 4,
        "width": 256,
        "height": 448,
        "content": "## 将所有网站拆分为各自的项目,以便它们逐个进入循环"
      },
      "typeVersion": 1
    },
    {
      "id": "019d5e36-c365-48b2-bdb3-665dc5051708",
      "name": "## 试试看!",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        464,
        -80
      ],
      "parameters": {
        "color": 5,
        "width": 256,
        "height": 448,
        "content": "## 存储您正在跟踪的 YouTube 频道的频道 ID"
      },
      "typeVersion": 1
    },
    {
      "id": "3ea72eea-053f-4d93-8bbe-05734648f4af",
      "name": "## 1. 创建新的自定义 OpenAI 凭据",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        112,
        -240
      ],
      "parameters": {
        "color": 5,
        "width": 256,
        "height": 448,
        "content": "## 您希望此工作流运行频率如何?"
      },
      "typeVersion": 1
    },
    {
      "id": "6719410f-abdf-4c94-a471-a31fb9d1fab5",
      "name": "便签10",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1216,
        80
      ],
      "parameters": {
        "color": 6,
        "width": 256,
        "height": 288,
        "content": "## 转换为有效的 RSS 订阅链接"
      },
      "typeVersion": 1
    },
    {
      "id": "f37d6a83-467e-4b9a-9890-3c2e7241444d",
      "name": "便签5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2544,
        80
      ],
      "parameters": {
        "width": 688,
        "height": 384,
        "content": "## 过滤掉 YouTube Shorts?"
      },
      "typeVersion": 1
    },
    {
      "id": "04af7999-8494-47a2-87f8-4a745c33f7ae",
      "name": "便签 12",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        4720,
        0
      ],
      "parameters": {
        "width": 336,
        "height": 464,
        "content": "## 免费 YouTube 转录服务"
      },
      "typeVersion": 1
    },
    {
      "id": "f56930b5-6a43-4240-bbfb-65b78b4d4623",
      "name": "便利贴13",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        6144,
        128
      ],
      "parameters": {
        "color": 3,
        "width": 224,
        "height": 336,
        "content": "## 等待片刻"
      },
      "typeVersion": 1
    },
    {
      "id": "690af084-1fc8-466a-afe4-105c431490ce",
      "name": "便签14",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -992,
        -240
      ],
      "parameters": {
        "width": 1088,
        "height": 448,
        "content": "## **YouTube 视频转录器**"
      },
      "typeVersion": 1
    },
    {
      "id": "e173f5ab-0734-42f4-b99c-cea881b6fed6",
      "name": "当点击“执行工作流”时",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        192,
        -64
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "d7803fcd-79ce-43eb-98ad-6b09f92315de",
      "name": "从 API 获取转录",
      "type": "n8n-nodes-base.httpRequest",
      "notes": "Failures:\n\n[\n  {\n    \"body\": {\n      \"error\": {\n        \"code\": 503,\n        \"message\": \"The model is overloaded. Please try again later.\",\n        \"status\": \"UNAVAILABLE\"\n      }\n    },\n    \"headers\": {\n      \"vary\": \"Origin, X-Origin, Referer\",\n      \"content-type\": \"application/json; charset=UTF-8\",\n      \"date\": \"Wed, 13 Aug 2025 18:07:09 GMT\",\n      \"server\": \"scaffolding on HTTPServer2\",\n      \"x-xss-protection\": \"0\",\n      \"x-frame-options\": \"SAMEORIGIN\",\n      \"x-content-type-options\": \"nosniff\",\n      \"server-timing\": \"gfet4t7; dur=19896\",\n      \"alt-svc\": \"h3=\\\":443\\\"; ma=2592000,h3-29=\\\":443\\\"; ma=2592000\",\n      \"connection\": \"close\",\n      \"transfer-encoding\": \"chunked\"\n    },\n    \"statusCode\": 503,\n    \"statusMessage\": \"Service Unavailable\"\n  }\n]",
      "position": [
        4832,
        112
      ],
      "parameters": {
        "url": "https://www.youtube-transcript.io/api/transcripts",
        "method": "POST",
        "options": {
          "response": {
            "response": {
              "neverError": true,
              "fullResponse": true,
              "responseFormat": "text"
            }
          }
        },
        "jsonBody": "={\n  \"ids\": [\n    \"{{$json.video_id}}\"\n  ]\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "headerParameters": {
          "parameters": [
            {
              "name": "Content-Type",
              "value": "application/json"
            }
          ]
        }
      },
      "credentials": {
        "httpQueryAuth": {
          "id": "dXT903VZuMUSiH5L",
          "name": "video guy"
        },
        "httpHeaderAuth": {
          "id": "7WXaS18PgenWHxmi",
          "name": "youtube-transcript-io"
        }
      },
      "retryOnFail": true,
      "typeVersion": 4.2,
      "waitBetweenTries": 5000
    },
    {
      "id": "22c1026c-1ff5-4409-ab3a-8c20e7a3ec7d",
      "name": "从 API 响应解析转录",
      "type": "n8n-nodes-base.code",
      "position": [
        5360,
        96
      ],
      "parameters": {
        "jsCode": "const trackToText = (track) => track.transcript.map(t => t.text).join(' ');\n\nconst results = [];\n\nfor (const cur of $input.all()) {\n  // Parse data field if it’s a string\n  let dataArray;\n  if (typeof cur.json.data === 'string') {\n    try {\n      dataArray = JSON.parse(cur.json.data);\n    } catch {\n      continue;\n    }\n  } else {\n    dataArray = cur.json.data;\n  }\n\n  const item = Array.isArray(dataArray) ? dataArray[0] : null;\n  if (!item || !item.tracks?.[0]) continue;\n\n  results.push({\n    json: {\n      id: item.id,\n      transcript: trackToText(item.tracks[0])\n    }\n  });\n}\n\nreturn results;\n"
      },
      "typeVersion": 2
    },
    {
      "id": "26bc1e33-ec0f-441b-919a-38ec2a168557",
      "name": "保存数据到 Supabase",
      "type": "n8n-nodes-base.supabase",
      "onError": "continueRegularOutput",
      "position": [
        5840,
        -80
      ],
      "parameters": {
        "tableId": "content_queue_1",
        "fieldsUi": {
          "fieldValues": [
            {
              "fieldId": "content_type",
              "fieldValue": "youtube"
            },
            {
              "fieldId": "title",
              "fieldValue": "={{ $json.title }}"
            },
            {
              "fieldId": "source_url",
              "fieldValue": "={{ $json.link }}"
            },
            {
              "fieldId": "content_snippet",
              "fieldValue": "={{ $json.transcript }}"
            },
            {
              "fieldId": "published_date",
              "fieldValue": "={{ $json.pubDate }}"
            },
            {
              "fieldId": "creator",
              "fieldValue": "={{ $json.author }}"
            }
          ]
        }
      },
      "credentials": {
        "supabaseApi": {
          "id": "oB3fYG1lWHXnOQN6",
          "name": "Content Automation Hub"
        }
      },
      "retryOnFail": true,
      "typeVersion": 1,
      "alwaysOutputData": true
    },
    {
      "id": "2d24ec43-3d00-40a8-bba3-1f67042092f6",
      "name": "过滤掉 YouTube Shorts",
      "type": "n8n-nodes-base.if",
      "position": [
        2800,
        144
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "af405725-90d8-4c1a-8497-0a92e273ced7",
              "operator": {
                "type": "string",
                "operation": "exists",
                "singleValue": true
              },
              "leftValue": "={{$json.link}}",
              "rightValue": ""
            },
            {
              "id": "2c3a30eb-489f-4ce9-bdf2-9f63c683456e",
              "operator": {
                "type": "string",
                "operation": "notContains"
              },
              "leftValue": "={{ $json.link }}",
              "rightValue": "youtube.com/shorts"
            }
          ]
        }
      },
      "typeVersion": 2.2
    }
  ],
  "pinData": {},
  "connections": {
    "Wait": {
      "main": [
        [
          {
            "node": "Loop Over New Videos",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out": {
      "main": [
        [
          {
            "node": "Channel Info",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Rename URL": {
      "main": [
        [
          {
            "node": "try to get video_id again",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Channel Info": {
      "main": [
        [
          {
            "node": "Verify Channel ID + Create RSS Link",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Clean Up URL": {
      "main": [
        [
          {
            "node": "Was Video ID Found?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Find Video ID": {
      "main": [
        [
          {
            "node": "Is Video ID valid?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Channels To Track": {
      "main": [
        [
          {
            "node": "Split Out",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Is Video ID valid?": {
      "main": [
        [
          {
            "node": "Clean Up URL",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Transcript Worked?": {
      "main": [
        [
          {
            "node": "Parse Transcript from API Response",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Transcript Failed",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Rename Original URL": {
      "main": [
        [
          {
            "node": "Find Video ID",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Was Video ID Found?": {
      "main": [
        [
          {
            "node": "Merge Video ID With Video Data",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Rename URL",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over New Videos": {
      "main": [
        [],
        [
          {
            "node": "Filter Out YouTube Shorts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Find Channel's Videos": {
      "main": [
        [
          {
            "node": "Loop Over Each Channel",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "New Video Information": {
      "main": [
        [
          {
            "node": "Merge Video ID With Video Data",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Save Data to Supabase": {
      "main": [
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Each Channel": {
      "main": [
        [
          {
            "node": "Loop Over New Videos",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Find Channel's Videos",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Transcript From API": {
      "main": [
        [
          {
            "node": "Transcript Worked?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Channel Info + Channel ID": {
      "main": [
        [
          {
            "node": "Loop Over Each Channel",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Filter Out YouTube Shorts": {
      "main": [
        [
          {
            "node": "Rename Original URL",
            "type": "main",
            "index": 0
          },
          {
            "node": "New Video Information",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Loop Over New Videos",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "try to get video_id again": {
      "main": [
        [
          {
            "node": "Merge Video ID With Video Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Add Transcript to Video Data": {
      "main": [
        [
          {
            "node": "Save Data to Supabase",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge Video ID With Video Data": {
      "main": [
        [
          {
            "node": "Get Transcript From API",
            "type": "main",
            "index": 0
          },
          {
            "node": "Add Transcript to Video Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse Transcript from API Response": {
      "main": [
        [
          {
            "node": "Add Transcript to Video Data",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Verify Channel ID + Create RSS Link": {
      "main": [
        [
          {
            "node": "Channel Info + Channel ID",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Channels To Track",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
常见问题

如何使用这个工作流?

复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。

这个工作流适合什么场景?

高级

需要付费吗?

本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。

工作流信息
难度等级
高级
节点数量37
分类-
节点类型13
难度说明

适合高级用户,包含 16+ 个节点的复杂工作流

作者

On a mission to automate all aspects of social media. Each of my templates covered more in depth in my Skool Community.

外部链接
在 n8n.io 查看

分享此工作流