{
  "name": "Create YouTube video RSS feed with Redis caching and embedded video player",
  "nodes": [
    {
      "id": "6d182711-1edf-4889-9c13-c8ee0e518843",
      "name": "Respond to Webhook",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        3424,
        -256
      ]
    },
    {
      "id": "9386dd85-0bfe-4d8d-838f-abf338966ca7",
      "name": "Get relevant RSS fields",
      "type": "n8n-nodes-base.set",
      "position": [
        2080,
        128
      ]
    },
    {
      "id": "154b038b-1eb5-404c-a93f-c77cff0fc6af",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -496,
        -416
      ],
      "parameters": {
        "width": 432,
        "height": 560,
        "content": "## 1) Set Channels to Pull Videos From\n\nModify the JSON in this node to select the YouTube channels you want to pull videos from. Only the \"id\" element containing the channel ID is required. You can a"
      }
    },
    {
      "id": "82876559-2d62-4ead-8937-b07507027bfe",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -912,
        -288
      ],
      "parameters": {
        "width": 384,
        "height": 304,
        "content": "## 4) Copy the Webhook URL\n\nCopy the production URL from this node and paste it into any RSS reader of your choosing. Optionally, you can change the URL by editing the path field."
      }
    },
    {
      "id": "23bb70f4-2f7c-46a6-900f-fc86052d3eb6",
      "name": "Manual trigger for testing",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -784,
        64
      ]
    },
    {
      "id": "dff5c80f-a170-4fde-b937-1e75778f4888",
      "name": "RSS Webhook",
      "type": "n8n-nodes-base.webhook",
      "position": [
        -784,
        -128
      ]
    },
    {
      "id": "23b31fab-636a-4d9a-a865-bacf46ab1772",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -32,
        -192
      ],
      "parameters": {
        "width": 672,
        "height": 336,
        "content": "## Read RSS feeds of YouTube Channels\n\nThese nodes read the RSS feed from youtube.com for each of the provided channels. The filter node filters out all YouTube Shorts videos and all videos that are p"
      }
    },
    {
      "id": "d15a8043-bcbf-454e-a482-970c6b6ea386",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        672,
        -368
      ],
      "parameters": {
        "width": 224,
        "height": 512,
        "content": "## 2) Add Redis Credentials\n\nA Redis database is used to cache the RSS item for each video. This is to prevent pulling video information for the same video from the YouTube API every time you refresh "
      }
    },
    {
      "id": "acaaf9d0-78d1-442e-afdb-625cfe27e7ca",
      "name": "Make Each Channel One Item",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        32,
        -32
      ]
    },
    {
      "id": "dff0de6a-dadb-4977-a5de-cd10b2f33abf",
      "name": "RSS Read YouTube Channel Feeds",
      "type": "n8n-nodes-base.rssFeedRead",
      "position": [
        256,
        -32
      ]
    },
    {
      "id": "1313dbf8-8d05-4b53-ae87-3296ac191723",
      "name": "Filter Out Shorts and Old Videos",
      "type": "n8n-nodes-base.filter",
      "position": [
        480,
        -32
      ]
    },
    {
      "id": "8f890a75-d90a-4cc5-b21a-c1f9472f25a7",
      "name": "Get Video Info From Cache",
      "type": "n8n-nodes-base.redis",
      "position": [
        736,
        -32
      ]
    },
    {
      "id": "6b2acfb9-d372-4826-8a6f-ad3585e3e4f3",
      "name": "Video in Cache?",
      "type": "n8n-nodes-base.if",
      "position": [
        960,
        -32
      ]
    },
    {
      "id": "d1aa68d6-3521-4af2-8460-93422604fe8a",
      "name": "Get Video ID",
      "type": "n8n-nodes-base.set",
      "position": [
        1184,
        128
      ]
    },
    {
      "id": "c3d7972c-3d10-471f-9e45-2f7e08f08dc5",
      "name": "Get Video Details",
      "type": "n8n-nodes-base.youTube",
      "position": [
        1520,
        128
      ]
    },
    {
      "id": "032097af-3c37-4707-b7a0-ce89ada8d0ff",
      "name": "Extract Short Description",
      "type": "n8n-nodes-base.code",
      "position": [
        1856,
        128
      ]
    },
    {
      "id": "773ff2f1-7def-4a12-9907-ddcc891d491e",
      "name": "Create RSS Items",
      "type": "n8n-nodes-base.code",
      "position": [
        2304,
        128
      ]
    },
    {
      "id": "a0c813b7-6039-49b4-989e-0e4c12401cf9",
      "name": "Get Fields to Cache",
      "type": "n8n-nodes-base.set",
      "position": [
        2528,
        160
      ]
    },
    {
      "id": "b8da92fa-8d6c-403a-a722-cc1a7587d130",
      "name": "Cache Video Info",
      "type": "n8n-nodes-base.redis",
      "position": [
        2752,
        160
      ]
    },
    {
      "id": "c6cc038b-2795-4b39-90d8-c22656d41da4",
      "name": "Get New RSS Items",
      "type": "n8n-nodes-base.set",
      "position": [
        2528,
        -160
      ]
    },
    {
      "id": "d5b68cb9-ca51-4f99-bbcf-b7c411be7f6f",
      "name": "Get Cached RSS Items",
      "type": "n8n-nodes-base.set",
      "position": [
        2528,
        -352
      ]
    },
    {
      "id": "ec795e54-980c-42ef-9120-cba68a332e85",
      "name": "Sort by Date",
      "type": "n8n-nodes-base.sort",
      "position": [
        2976,
        -256
      ]
    },
    {
      "id": "aaea0eea-fbfa-45c0-a07a-e498169c243f",
      "name": "Build RSS Feed",
      "type": "n8n-nodes-base.code",
      "position": [
        3200,
        -256
      ]
    },
    {
      "id": "93e1345c-cd0d-43ef-abac-03323711088e",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        928,
        -416
      ],
      "parameters": {
        "width": 1520,
        "height": 736,
        "content": "## Pull Video Info From Uncached Videos\n\nIf the feeds contain new videos, the player iframe and full description are pulled using the YouTube node. From this full description, a short version is made "
      }
    },
    {
      "id": "3c7fcde8-8d1c-4ba8-b0d3-bab0f13c26a5",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1344,
        0
      ],
      "parameters": {
        "width": 448,
        "height": 288,
        "content": "## 3) Add Google Credentials\n\nTo fetch data from the YouTube API, you need to provide Google credentials. See the [documentation](https://docs.n8n.io/integrations/builtin/credentials/google/) for more"
      }
    },
    {
      "id": "cb75f678-64f3-473b-9d11-2ac25b3186e7",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2480,
        32
      ],
      "parameters": {
        "width": 464,
        "height": 288,
        "content": "## Save RSS Items to Cache\n\nLastly, the new RSS items are saved to cache with an expiration time of one week."
      }
    },
    {
      "id": "4fdff9ce-8759-4da6-91b4-faaf32c9854f",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2480,
        -480
      ],
      "parameters": {
        "width": 1136,
        "height": 480,
        "content": "## Build RSS Feed\n\nBoth the cached and new RSS items are merged and sorted by date. Then the RSS feed is built from these items and returned to the webhook. Feel free to change the title and descripti"
      }
    },
    {
      "id": "6dcfa347-8f40-417b-a606-f834f42c5a90",
      "name": "Sticky Note8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        480,
        176
      ],
      "parameters": {
        "width": 416,
        "height": 496,
        "content": "## Tip: Hosting Your Own Redis Database\n\nIf you are hosting n8n yourself using Docker Compose, you can easily add a Redis database container by adding the following to your Compose file:\n```yaml\nservi"
      }
    },
    {
      "id": "70123410-0500-44ea-8347-8de053540373",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1296,
        -1312
      ],
      "parameters": {
        "width": 768,
        "height": 992,
        "content": "## Your Personal RSS Feed of YouTube Videos!\nThis workflow creates an RSS feed containing the most recent videos published by your favorite channels. Use it in combination with your favorite RSS reade"
      }
    },
    {
      "id": "a40e110b-ada6-4960-ac8f-da452f22eb83",
      "name": "Set Channels",
      "type": "n8n-nodes-base.set",
      "position": [
        -320,
        -32
      ]
    },
    {
      "id": "8b7fe325-4f5a-48bd-8ec9-26981eaa01a6",
      "name": "Merge RSS Items",
      "type": "n8n-nodes-base.merge",
      "position": [
        2752,
        -256
      ]
    }
  ],
  "connections": {
    "RSS Webhook": {
      "main": [
        [
          {
            "node": "Set Channels",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Video ID": {
      "main": [
        [
          {
            "node": "Get Video Details",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set Channels": {
      "main": [
        [
          {
            "node": "Make Each Channel One Item",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Sort by Date": {
      "main": [
        [
          {
            "node": "Build RSS Feed",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Build RSS Feed": {
      "main": [
        [
          {
            "node": "Respond to Webhook",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge RSS Items": {
      "main": [
        [
          {
            "node": "Sort by Date",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Video in Cache?": {
      "main": [
        [
          {
            "node": "Get Cached RSS Items",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Get Video ID",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create RSS Items": {
      "main": [
        [
          {
            "node": "Get Fields to Cache",
            "type": "main",
            "index": 0
          },
          {
            "node": "Get New RSS Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get New RSS Items": {
      "main": [
        [
          {
            "node": "Merge RSS Items",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Get Video Details": {
      "main": [
        [
          {
            "node": "Extract Short Description",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Fields to Cache": {
      "main": [
        [
          {
            "node": "Cache Video Info",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Cached RSS Items": {
      "main": [
        [
          {
            "node": "Merge RSS Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get relevant RSS fields": {
      "main": [
        [
          {
            "node": "Create RSS Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Short Description": {
      "main": [
        [
          {
            "node": "Get relevant RSS fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Video Info From Cache": {
      "main": [
        [
          {
            "node": "Video in Cache?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Make Each Channel One Item": {
      "main": [
        [
          {
            "node": "RSS Read YouTube Channel Feeds",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Manual trigger for testing": {
      "main": [
        [
          {
            "node": "Set Channels",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "RSS Read YouTube Channel Feeds": {
      "main": [
        [
          {
            "node": "Filter Out Shorts and Old Videos",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Filter Out Shorts and Old Videos": {
      "main": [
        [
          {
            "node": "Get Video Info From Cache",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}