{
  "name": "Send weekly GitHub digest with releases, commits and trending repos via Gmail",
  "nodes": [
    {
      "id": "5a3638b4-dd45-477c-82c8-24b33e8334c1",
      "name": "Overview",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -224,
        80
      ],
      "parameters": {
        "width": 360,
        "height": 952,
        "content": "## 🤖 Weekly GitHub Digest\n\nSends **one combined weekly email** with 3 sections:\n- 🚀 **Releases** — new releases from your watched repos\n- 👥 **Commits** — recent activity from tracked users or repos\n- "
      }
    },
    {
      "id": "15d8a903-54f0-4291-966a-0a84692a5197",
      "name": "Every Monday at 9am",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        240,
        384
      ]
    },
    {
      "id": "7f6e199c-657e-4869-9d37-f8312a2c54dc",
      "name": "Releases Section",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        688,
        -160
      ],
      "parameters": {
        "width": 664,
        "height": 356,
        "content": "## Releases\nFetches the latest release per watched repo and collects those published within the lookback window."
      }
    },
    {
      "id": "166f731a-f1b5-47ec-8536-2aaea728ad19",
      "name": "Split Watched Repos",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        704,
        -48
      ]
    },
    {
      "id": "940a1583-8ad8-40b5-8323-92f7b9c900a9",
      "name": "Aggregate Releases",
      "type": "n8n-nodes-base.code",
      "position": [
        1136,
        -48
      ]
    },
    {
      "id": "4b4091a3-440c-433f-8905-bae1e382ca32",
      "name": "Commits Section",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        688,
        400
      ],
      "parameters": {
        "width": 632,
        "height": 260,
        "content": "##  Commits\nSupports both GitHub users (`torvalds`) and repos (`huggingface/transformers`). "
      }
    },
    {
      "id": "1161e57c-c587-462e-b87c-a9a1b893b026",
      "name": "Extract Commits",
      "type": "n8n-nodes-base.code",
      "position": [
        1040,
        496
      ]
    },
    {
      "id": "24e7ab70-e28e-41c9-a14d-669ce9c76746",
      "name": "Trending Section",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        704,
        832
      ],
      "parameters": {
        "width": 512,
        "height": 292,
        "content": "## GitHub Trending Today\nScrapes the GitHub trending page for the day the workflow runs."
      }
    },
    {
      "id": "0416371c-2248-442f-8ee9-27a3425f2fc9",
      "name": "Fetch GitHub Trending Page",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        736,
        928
      ]
    },
    {
      "id": "31861753-3d34-41fc-aac1-813efcee001f",
      "name": "Parse Trending HTML",
      "type": "n8n-nodes-base.code",
      "position": [
        928,
        928
      ]
    },
    {
      "id": "5132a98d-3f32-496e-9905-8bec7dc28643",
      "name": "Merge Releases + Commits",
      "type": "n8n-nodes-base.merge",
      "position": [
        1728,
        288
      ]
    },
    {
      "id": "753b0c40-c481-4e5c-8bff-9a5ac49b6aa4",
      "name": "Merge All Data",
      "type": "n8n-nodes-base.merge",
      "position": [
        1888,
        496
      ]
    },
    {
      "id": "16f88f96-e5eb-4898-a4b1-ac1501e780d2",
      "name": "Has Any Content?",
      "type": "n8n-nodes-base.if",
      "position": [
        2080,
        496
      ]
    },
    {
      "id": "63f1d1c8-1e1b-414f-8a32-9bcfb4523b41",
      "name": "Build Combined Email",
      "type": "n8n-nodes-base.code",
      "position": [
        2288,
        416
      ]
    },
    {
      "id": "8c203c76-5a0c-4ec7-a265-8f706d1f4340",
      "name": "Send Weekly Digest",
      "type": "n8n-nodes-base.gmail",
      "position": [
        2512,
        416
      ]
    },
    {
      "id": "cbcc5fae-b715-47b6-8bab-3ecaf0c335f6",
      "name": "Fetch Latest Release",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        912,
        -48
      ]
    },
    {
      "id": "0c910eda-7a6f-4641-826c-7e886178116e",
      "name": "Fetch Entity Data",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        880,
        496
      ]
    },
    {
      "id": "a1472e9e-8c29-4dcd-95d4-6a3787da7288",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        832,
        -48
      ],
      "parameters": {
        "width": 272,
        "height": 352,
        "content": "\n\n\n\n\n\n\n\n\n\n\n\n#### Important\nGitHub's /releases/latest endpoint skips anything flagged as prerelease.\nIf you only want to fetch usual releases, use \n´https://api.github.com/repos/repo-name/releases/late"
      }
    },
    {
      "id": "1373c533-c8cb-43ea-a2a7-2f492fcab55e",
      "name": "Split Tracked Entities",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        720,
        496
      ]
    },
    {
      "id": "9b9f4c5d-daaf-4901-8604-c993b13d7ca0",
      "name": "Do Nothing",
      "type": "n8n-nodes-base.noOp",
      "position": [
        2288,
        608
      ]
    },
    {
      "id": "2aa3eb79-1f86-4c68-a48f-159cb59c5f7f",
      "name": "Set Variables",
      "type": "n8n-nodes-base.set",
      "position": [
        464,
        384
      ]
    },
    {
      "id": "3083f525-fbff-4ac7-aa0b-6b904a67978e",
      "name": "Commits Section1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2224,
        160
      ],
      "parameters": {
        "width": 264,
        "height": 388,
        "content": "##  Email Template\n\nAggregates output from all three branches into a single HTML email.   \n\nOutput fields: `html`, `subject`, `release_count`,`commit_count`, `trending_count`.\n\nFeel free to modify thi"
      }
    }
  ],
  "connections": {
    "Set Variables": {
      "main": [
        [
          {
            "node": "Split Watched Repos",
            "type": "main",
            "index": 0
          },
          {
            "node": "Fetch GitHub Trending Page",
            "type": "main",
            "index": 0
          },
          {
            "node": "Split Tracked Entities",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge All Data": {
      "main": [
        [
          {
            "node": "Has Any Content?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Commits": {
      "main": [
        [
          {
            "node": "Merge Releases + Commits",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Has Any Content?": {
      "main": [
        [
          {
            "node": "Build Combined Email",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Do Nothing",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Entity Data": {
      "main": [
        [
          {
            "node": "Extract Commits",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate Releases": {
      "main": [
        [
          {
            "node": "Merge Releases + Commits",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Every Monday at 9am": {
      "main": [
        [
          {
            "node": "Set Variables",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse Trending HTML": {
      "main": [
        [
          {
            "node": "Merge All Data",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Split Watched Repos": {
      "main": [
        [
          {
            "node": "Fetch Latest Release",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Build Combined Email": {
      "main": [
        [
          {
            "node": "Send Weekly Digest",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Latest Release": {
      "main": [
        [
          {
            "node": "Aggregate Releases",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Tracked Entities": {
      "main": [
        [
          {
            "node": "Fetch Entity Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge Releases + Commits": {
      "main": [
        [
          {
            "node": "Merge All Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch GitHub Trending Page": {
      "main": [
        [
          {
            "node": "Parse Trending HTML",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}