{
  "name": "Send follow-ups using Gmail to Hubspot contacts",
  "nodes": [
    {
      "id": "3a0ba7f4-ac41-49b0-a055-b993c82f2680",
      "name": "Every day at 9 am",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        340,
        1280
      ]
    },
    {
      "id": "5fa47f36-3206-44b9-965a-0d27b10acc21",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        740,
        980
      ],
      "parameters": {
        "width": 348.2877732355713,
        "height": 595.2986206729652,
        "content": "## Search for all contacts that last contact date for is known\n\n1. Setup Oauth2 creds using n8n docs\nhttps://docs.n8n.io/integrations/builtin/trigger-nodes/n8n-nodes-base.hubspottrigger/\n\n### Be caref"
      }
    },
    {
      "id": "16b6fadf-ff1d-4670-b148-151cfbd242d5",
      "name": "Send outreach email",
      "type": "n8n-nodes-base.gmail",
      "position": [
        2040,
        1060
      ]
    },
    {
      "id": "a89ec3bd-7bb0-4dde-a9eb-800842073fc9",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2000,
        1300
      ],
      "parameters": {
        "width": 289.74216745960825,
        "height": 402.1775107197669,
        "content": "## Record engagement in Hubspot\n\nOnce engagement is added, last contact date is updated and won't show up in search results for another month.\n"
      }
    },
    {
      "id": "687509ed-4d25-4597-bade-1802348e42c9",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        260,
        980
      ],
      "parameters": {
        "width": 407.25356360335365,
        "height": 242.51175804432177,
        "content": "## Send followup email using Gmail to Hubspot contacts \n\nFollowing up at the right time is one of the most important parts of sales. This workflow uses Gmail to send outreach emails to Hubspot contact"
      }
    },
    {
      "id": "e66f48c9-0e19-4089-a4a4-d9e87b56898a",
      "name": "Record engagement in HubSpot",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        2080,
        1500
      ]
    },
    {
      "id": "f90770cf-aa6c-4148-b471-2b28ed978f72",
      "name": "Get previously HubSpot contacts",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        840,
        1280
      ]
    },
    {
      "id": "751fd345-9fec-4c7c-b20b-1db86ce6df10",
      "name": "if last contacted before a month",
      "type": "n8n-nodes-base.if",
      "position": [
        1120,
        1280
      ]
    },
    {
      "id": "52596987-ef7f-4dd7-98e7-6c3aaf6c2853",
      "name": "Get Hubspot Contact to engagement",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1340,
        1280
      ]
    },
    {
      "id": "fe0bc120-8bee-41fa-a896-3c9ff8cf3a29",
      "name": "if there has been only one engagement",
      "type": "n8n-nodes-base.if",
      "position": [
        1560,
        1280
      ]
    },
    {
      "id": "512909c7-104b-4507-b91e-aa5b5a9410e5",
      "name": "Set email keys",
      "type": "n8n-nodes-base.set",
      "position": [
        1820,
        1280
      ]
    },
    {
      "id": "c0e5472d-5208-4df7-89e8-380c2dab9642",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1300,
        1060
      ],
      "parameters": {
        "width": 490.3275896931988,
        "height": 496.3776986502359,
        "content": "## Get pervious engagements. Avoid sending follow ups if first eng\n\n### Here we simply follow up if there has only been outreach email before.\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n### We could the engagements here and t"
      }
    }
  ],
  "connections": {
    "Set email keys": {
      "main": [
        [
          {
            "node": "Record engagement in HubSpot",
            "type": "main",
            "index": 0
          },
          {
            "node": "Send outreach email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Every day at 9 am": {
      "main": [
        [
          {
            "node": "Get previously HubSpot contacts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get previously HubSpot contacts": {
      "main": [
        [
          {
            "node": "if last contacted before a month",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "if last contacted before a month": {
      "main": [
        [
          {
            "node": "Get Hubspot Contact to engagement",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Hubspot Contact to engagement": {
      "main": [
        [
          {
            "node": "if there has been only one engagement",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "if there has been only one engagement": {
      "main": [
        [
          {
            "node": "Set email keys",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}