{
  "name": "Google Calendar \u2192 Daily Briefing",
  "nodes": [
    {
      "parameters": {
        "calendarId": "primary"
      },
      "id": "cal",
      "name": "Today's Events",
      "type": "n8n-nodes-base.googleCalendar",
      "typeVersion": 1.2,
      "position": [
        250,
        300
      ]
    },
    {
      "parameters": {
        "jsCode": "const ev=$input.all().map(e=>e.json); let h='<h1>Your Day</h1>'; ev.forEach(e=>{h+='<p><b>'+e.summary+'</b> '+ (e.start?.dateTime||'')+'</p>'}); return {html:h,count:ev.length};"
      },
      "id": "comp",
      "name": "Compose",
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        450,
        300
      ]
    },
    {
      "parameters": {
        "fromEmail": "briefing@example.com",
        "toEmail": "you@example.com",
        "subject": "Your Day Ahead",
        "html": "={{ $json.html }}"
      },
      "id": "email",
      "name": "Send",
      "type": "n8n-nodes-base.emailSend",
      "typeVersion": 2,
      "position": [
        650,
        300
      ]
    }
  ],
  "connections": {
    "Today's Events": {
      "main": [
        [
          {
            "node": "Compose",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Compose": {
      "main": [
        [
          {
            "node": "Send",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}