{
  "name": "Log new Google top-10 keywords to Airtable with DataForSEO and Slack alerts",
  "nodes": [
    {
      "id": "71b5d365-4f62-4903-b199-1a4ce9329bc3",
      "name": "Aggregate",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        1248,
        64
      ]
    },
    {
      "id": "6d88155f-060a-4fc9-81a6-00d3d9a69293",
      "name": "Get ranked keywords",
      "type": "n8n-nodes-dataforseo.dataForSeoLabsApi",
      "position": [
        640,
        368
      ]
    },
    {
      "id": "d9e9828f-c00e-44da-b0b9-bb0a533513dd",
      "name": "Find new keywords",
      "type": "n8n-nodes-base.code",
      "position": [
        768,
        832
      ]
    },
    {
      "id": "7304aa30-f78a-4c08-a221-ea3133cc6846",
      "name": "Run every Monday",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        0,
        64
      ]
    },
    {
      "id": "80de1cbe-b149-4076-8ab0-48659916a1d7",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -624,
        80
      ],
      "parameters": {
        "width": 480,
        "height": 528,
        "content": "This workflow uses the DataForSEO Labs API to detect new search queries for which your domain(s) started ranking in Google’s top 10 results. Newly discovered keywords are recorded in Airtable, and a s"
      }
    },
    {
      "id": "558f72a0-2fa4-4af4-af7e-6c11ccba322f",
      "name": "Aggregate1",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        544,
        832
      ]
    },
    {
      "id": "89a179f1-20e1-43b8-8789-fa3746618a16",
      "name": "Merge",
      "type": "n8n-nodes-base.merge",
      "position": [
        848,
        64
      ]
    },
    {
      "id": "717cbba9-ee71-4041-82ee-c4c01325a935",
      "name": "Search keywords",
      "type": "n8n-nodes-base.airtable",
      "position": [
        208,
        64
      ]
    },
    {
      "id": "9603f932-c8cc-46fa-99b7-9f704bea714d",
      "name": "Search Targets",
      "type": "n8n-nodes-base.airtable",
      "position": [
        1488,
        64
      ]
    },
    {
      "id": "34fc39a2-9fa9-471f-b7b3-aa6a28dc251d",
      "name": "Create a record (keyword)",
      "type": "n8n-nodes-base.airtable",
      "position": [
        336,
        832
      ]
    },
    {
      "id": "d759be6a-add6-4a82-9874-07625f720bae",
      "name": "Send a message",
      "type": "n8n-nodes-base.slack",
      "position": [
        1200,
        832
      ]
    },
    {
      "id": "7b9567dd-6923-4443-bfb9-2a3599d6f766",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        160,
        -160
      ],
      "parameters": {
        "width": 1216,
        "height": 384,
        "content": "## Get previous keywords and clear the table\nSelect your table with Ranked Keywords. The table is expected to have these columns: Keyword, Target, Date, URL, Search Volume, Intent, Rank.\n"
      }
    },
    {
      "id": "1c9d9a45-36a1-4564-b32d-b577beb4da6a",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1392,
        -160
      ],
      "parameters": {
        "width": 224,
        "height": 384,
        "content": "## Get targets\nSelect your table with targets. The table is expected to have these columns: Domain, Location, and Language."
      }
    },
    {
      "id": "66138377-9651-400c-b366-2560fb417655",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        160,
        288
      ],
      "parameters": {
        "width": 1328,
        "height": 320,
        "content": "## Getn new keywords ranked in Google’s top 10 results with DataForSEO\nCreate a DataForSEO connection and set up additional parameters if needed."
      }
    },
    {
      "id": "528f3be8-7a89-4689-94b8-5136d9a23acf",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        96,
        688
      ],
      "parameters": {
        "width": 1216,
        "height": 320,
        "content": "## Save keywords ranked in Google’s top 10 results to Airtable and send new keywords to Slack\nSelect your table with Ranked Keywords. \nCreate a Slack connection and set a receiver. Add additional info"
      }
    },
    {
      "id": "e1bbf7f7-a2cf-4204-b25a-e5e525444915",
      "name": "If (table is not empty)",
      "type": "n8n-nodes-base.if",
      "position": [
        416,
        64
      ]
    },
    {
      "id": "8ff1ff0e-36b9-49c0-b7f3-70293b73f443",
      "name": "Set \"keyword\" and \"target\" fields",
      "type": "n8n-nodes-base.set",
      "position": [
        1056,
        64
      ]
    },
    {
      "id": "6330ff02-0863-4f42-96dd-1434a6be4e77",
      "name": "Initialize \"items\" field",
      "type": "n8n-nodes-base.set",
      "position": [
        208,
        432
      ]
    },
    {
      "id": "8d25a8cd-ecbc-4d64-b9eb-c7f391e1a4c7",
      "name": "Set \"items\" field",
      "type": "n8n-nodes-base.set",
      "position": [
        432,
        432
      ]
    },
    {
      "id": "77e866ef-b079-43c3-a10d-4756301b4c8f",
      "name": "Merge \"items\" with DFS response",
      "type": "n8n-nodes-base.set",
      "position": [
        880,
        368
      ]
    },
    {
      "id": "26c73414-e804-44e9-b086-514f33f06d5c",
      "name": "Has more pages?",
      "type": "n8n-nodes-base.if",
      "position": [
        1104,
        432
      ]
    },
    {
      "id": "27b6e975-0952-4a14-af56-1e9c4884d0cf",
      "name": "Merge \"items\" with last response",
      "type": "n8n-nodes-base.set",
      "position": [
        1344,
        448
      ]
    },
    {
      "id": "e504f014-b4a1-40fb-ae18-a487fa02e02d",
      "name": "Split out (items)",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        112,
        832
      ]
    },
    {
      "id": "f6dad49f-79c4-47e0-8893-c013777bc68f",
      "name": "Filter (has new keywords)",
      "type": "n8n-nodes-base.filter",
      "position": [
        976,
        832
      ]
    },
    {
      "id": "616e6cac-a903-4b78-8173-885605c0d487",
      "name": "Delete keyword",
      "type": "n8n-nodes-base.airtable",
      "position": [
        624,
        -48
      ]
    },
    {
      "id": "c2654833-b498-4c94-bdea-41bae7523be3",
      "name": "Loop over targets",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        -16,
        416
      ]
    }
  ],
  "connections": {
    "Merge": {
      "main": [
        [
          {
            "node": "Set \"keyword\" and \"target\" fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate": {
      "main": [
        [
          {
            "node": "Search Targets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Aggregate1": {
      "main": [
        [
          {
            "node": "Find new keywords",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Delete keyword": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Search Targets": {
      "main": [
        [
          {
            "node": "Loop over targets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send a message": {
      "main": [
        [
          {
            "node": "Loop over targets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Has more pages?": {
      "main": [
        [
          {
            "node": "Set \"items\" field",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Merge \"items\" with last response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Search keywords": {
      "main": [
        [
          {
            "node": "If (table is not empty)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Run every Monday": {
      "main": [
        [
          {
            "node": "Search keywords",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Find new keywords": {
      "main": [
        [
          {
            "node": "Filter (has new keywords)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop over targets": {
      "main": [
        [],
        [
          {
            "node": "Initialize \"items\" field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set \"items\" field": {
      "main": [
        [
          {
            "node": "Get ranked keywords",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split out (items)": {
      "main": [
        [
          {
            "node": "Create a record (keyword)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get ranked keywords": {
      "main": [
        [
          {
            "node": "Merge \"items\" with DFS response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If (table is not empty)": {
      "main": [
        [
          {
            "node": "Delete keyword",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Initialize \"items\" field": {
      "main": [
        [
          {
            "node": "Set \"items\" field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create a record (keyword)": {
      "main": [
        [
          {
            "node": "Aggregate1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Filter (has new keywords)": {
      "main": [
        [
          {
            "node": "Send a message",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge \"items\" with DFS response": {
      "main": [
        [
          {
            "node": "Has more pages?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge \"items\" with last response": {
      "main": [
        [
          {
            "node": "Split out (items)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set \"keyword\" and \"target\" fields": {
      "main": [
        [
          {
            "node": "Aggregate",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}