{
  "name": "Extract YouTube auto-generated transcripts for AI analysis and storage",
  "nodes": [
    {
      "id": "2e715548-dc0c-4f27-893d-aa944dda57b9",
      "name": "Trigger: Execute Workflow",
      "type": "n8n-nodes-base.executeWorkflowTrigger",
      "position": [
        272,
        1056
      ]
    },
    {
      "id": "fd592f64-4d34-4a53-a91a-ba1a4f3f07a9",
      "name": "Fetch: YouTube Page HTML",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        496,
        1056
      ]
    },
    {
      "id": "b988bc18-3e14-46b6-8df3-aca439a78f86",
      "name": "Extract: API Key & Video ID",
      "type": "n8n-nodes-base.code",
      "position": [
        720,
        1056
      ]
    },
    {
      "id": "6e21195d-17b1-4653-ac34-e7cf9770c48e",
      "name": "API: Get Video Metadata",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        944,
        1056
      ]
    },
    {
      "id": "0737b208-4ca0-4ac8-bc9d-342a666ede8b",
      "name": "Extract: Auto-Generated Transcript URL",
      "type": "n8n-nodes-base.code",
      "position": [
        1168,
        1056
      ]
    },
    {
      "id": "08d78016-4fd2-485f-91a6-33bdad8587e0",
      "name": "Fetch: Transcript XML",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1392,
        960
      ]
    },
    {
      "id": "259c3e38-5c10-4f0b-9204-6f587e675efb",
      "name": "Parse: XML to JSON",
      "type": "n8n-nodes-base.xml",
      "position": [
        1616,
        960
      ]
    },
    {
      "id": "496cfcbd-7ff9-4b70-95dd-889aabb68eb9",
      "name": "Transform: Process Transcript",
      "type": "n8n-nodes-base.code",
      "position": [
        1840,
        960
      ]
    },
    {
      "id": "825ec3eb-2c08-4f1b-a3bf-b902bba8253c",
      "name": "📋 Sticky: Overview",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -496,
        656
      ],
      "parameters": {
        "width": 700,
        "height": 1046,
        "content": "## 🎬 Extract and save YouTube auto-generated transcripts\n\nThis template extracts the **auto-generated transcript** from a YouTube video using YouTube's internal caption metadata.\n\nIt is useful for:\n- "
      }
    },
    {
      "id": "e46be3b4-da28-4acb-bfdc-8b75ead92a02",
      "name": "Stop and Error",
      "type": "n8n-nodes-base.stopAndError",
      "position": [
        1392,
        1152
      ]
    },
    {
      "id": "e514abc4-9c26-472a-a358-92e5a0c4b0b6",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        336,
        752
      ],
      "parameters": {
        "width": 928,
        "height": 240,
        "content": "🔑 PHASE 1: Credentials & Metadata Acquisition\n\nThis phase extracts the necessary information to access \nthe transcriptions:\n\n1. Fetch YouTube page HTML\n2. Extract INNERTUBE_API_KEY and videoId\n3. Call"
      }
    },
    {
      "id": "b40e621e-2ce5-445e-a080-f6c3666d8013",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1328,
        1312
      ],
      "parameters": {
        "width": 672,
        "height": 240,
        "content": "📝 PHASE 2: Transcript Download & Transformation\n\nThis phase processes the extracted transcription:\n\n1. Download XML file from obtained URL\n2. Convert XML to JSON\n3. Decode HTML entities\n4. Concatenate"
      }
    }
  ],
  "connections": {
    "Parse: XML to JSON": {
      "main": [
        [
          {
            "node": "Transform: Process Transcript",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch: Transcript XML": {
      "main": [
        [
          {
            "node": "Parse: XML to JSON",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "API: Get Video Metadata": {
      "main": [
        [
          {
            "node": "Extract: Auto-Generated Transcript URL",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch: YouTube Page HTML": {
      "main": [
        [
          {
            "node": "Extract: API Key & Video ID",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Trigger: Execute Workflow": {
      "main": [
        [
          {
            "node": "Fetch: YouTube Page HTML",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract: API Key & Video ID": {
      "main": [
        [
          {
            "node": "API: Get Video Metadata",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract: Auto-Generated Transcript URL": {
      "main": [
        [
          {
            "node": "Fetch: Transcript XML",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Stop and Error",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}