{
  "name": "Receive Meta Ads ad account webhooks, log to Sheets, and alert in Slack",
  "nodes": [
    {
      "id": "89527acd-0683-42a4-ae5e-e6dd74a98662",
      "name": "Webhook: Meta (ad_account)",
      "type": "n8n-nodes-base.webhook",
      "position": [
        624,
        768
      ]
    },
    {
      "id": "7564c707-9aa2-48b4-92ff-0f0f1e06b132",
      "name": "Route: verification vs webhook",
      "type": "n8n-nodes-base.switch",
      "position": [
        848,
        768
      ]
    },
    {
      "id": "b1ac3f80-2e08-45fc-bc99-0fed75d9ea71",
      "name": "Verify: token",
      "type": "n8n-nodes-base.if",
      "position": [
        960,
        528
      ]
    },
    {
      "id": "37809c0f-4671-4cff-908a-ff33a0b9a1fd",
      "name": "Respond: challenge",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1200,
        464
      ]
    },
    {
      "id": "8a310150-ba7a-4b8e-9b94-50606d7229b6",
      "name": "Route: field",
      "type": "n8n-nodes-base.switch",
      "position": [
        1072,
        992
      ]
    },
    {
      "id": "0037189f-feb0-451f-a56a-b8426a71de19",
      "name": "Respond Creative Fatigue",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1344,
        576
      ]
    },
    {
      "id": "52b43fd4-8836-43db-9b4e-fff81c279d7a",
      "name": "Respond Ad Recommendations",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1344,
        768
      ]
    },
    {
      "id": "70172dc3-e4c8-41e5-ba20-cfdc19f14d38",
      "name": "Respond Async Creation",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1344,
        960
      ]
    },
    {
      "id": "ee906d52-534d-4d7c-a782-ebb4faa79065",
      "name": "Respond In Process",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1344,
        1152
      ]
    },
    {
      "id": "2ce97e7e-1ed4-4cea-9950-c16906c34c37",
      "name": "Respond Product Set Issue",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1344,
        1344
      ]
    },
    {
      "id": "609155d1-17e5-4f13-a4d3-166e781a15a6",
      "name": "Respond With Issues",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1328,
        1536
      ]
    },
    {
      "id": "17a7b8cc-9a67-4fc0-82d0-2cfd29db738e",
      "name": "Split Out Accounts AdRec",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1920,
        768
      ]
    },
    {
      "id": "8b0b2421-fb0b-4ec8-9b25-6c0ebf03a324",
      "name": "Split Out Accounts AsCr",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1920,
        960
      ]
    },
    {
      "id": "0c52522c-7c55-47e8-b115-335afd15ca02",
      "name": "Split Out Accounts Pr",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1920,
        1152
      ]
    },
    {
      "id": "6470e42c-fb91-48ae-b14f-6771203ea465",
      "name": "Split Out Accounts SetIssue",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1920,
        1344
      ]
    },
    {
      "id": "28c52db3-05d6-4d33-8ac3-500009119079",
      "name": "Split Out Accounts Issues",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1920,
        1536
      ]
    },
    {
      "id": "6cc26e3b-02bf-468c-a443-824f471fc4e8",
      "name": "Split Out Accounts CF",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        1920,
        576
      ]
    },
    {
      "id": "b65ecf93-2c9c-4358-9526-6258af522c11",
      "name": "Split Out Changes CF",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        2128,
        576
      ]
    },
    {
      "id": "c192ad61-1343-4821-a553-b9ad7eba68ab",
      "name": "Split Out Changes AdRec",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        2128,
        768
      ]
    },
    {
      "id": "e72f095b-88f8-4a6d-bcec-29b28d707f73",
      "name": "Log Creative Fatigue",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2336,
        576
      ]
    },
    {
      "id": "90a82793-42ea-4ff1-8cb3-49562042f48e",
      "name": "Log Ad Recommendations",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2336,
        768
      ]
    },
    {
      "id": "4f7a55dc-e4cb-420d-8050-a0a96a91fcc2",
      "name": "Log Async Creation",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2336,
        960
      ]
    },
    {
      "id": "f046d10c-7225-40de-864c-0ce191b6d7c6",
      "name": "Split Out Changes AsCr",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        2128,
        960
      ]
    },
    {
      "id": "e28f01fb-ee56-4ee6-92d6-fc729e5e2efd",
      "name": "Split Out Changes Pr",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        2128,
        1152
      ]
    },
    {
      "id": "65ee04ce-545a-4d18-9dac-417c292458ec",
      "name": "Log In-process ad objects",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2336,
        1152
      ]
    },
    {
      "id": "de853e05-9ee0-48cf-beb6-5dbb427f0bd1",
      "name": "Split Out Changes SetIssue",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        2128,
        1344
      ]
    },
    {
      "id": "5e198061-fb10-4c01-a49f-975a5ad49ff7",
      "name": "Log product set issues",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2336,
        1344
      ]
    },
    {
      "id": "11a16a53-9edc-4b42-9fd4-57b2143a3a06",
      "name": "Split Out Changes SetIssue1",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        2128,
        1536
      ]
    },
    {
      "id": "b8965c2c-d6e9-4c9e-9bc3-6c6985cea0c9",
      "name": "Log with-issues ad objects",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2336,
        1536
      ]
    },
    {
      "id": "16c00b71-a9a2-4e1f-97a3-c3c482aa3445",
      "name": "Set: event field",
      "type": "n8n-nodes-base.set",
      "position": [
        2544,
        960
      ]
    },
    {
      "id": "fe7474ef-46e4-44cd-bf5e-2ac28d4a5c83",
      "name": "Summarize",
      "type": "n8n-nodes-base.summarize",
      "position": [
        2752,
        960
      ]
    },
    {
      "id": "db3f1ce2-62a2-44bd-979a-bfecc0abba65",
      "name": "Sticky Note - Overview",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -448,
        528
      ],
      "parameters": {
        "width": 668,
        "height": 816,
        "content": "# Meta Ads webhook dispatcher (ad_account)\n\n## How it works\n\n- Receives **Meta Ads Webhooks** for the **Ad Account** object\n- Sends the required **acknowledgement** back to Meta (verification + event "
      }
    },
    {
      "id": "f66ce378-d468-47c9-8fa8-1a63ca4a265b",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1568,
        432
      ],
      "parameters": {
        "width": 944,
        "height": 1344,
        "content": "##  Log data to flat table\n\n**Split webhook payload**\nMeta can send arrays in the webhook payload.\nSplit them into individual items to make processing and logging easier.\n\n**Save data**\nLog all webhoo"
      }
    },
    {
      "id": "52099702-5e95-4645-b532-aae8a41dcc9a",
      "name": "Sticky Note11",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2528,
        656
      ],
      "parameters": {
        "width": 582,
        "height": 576,
        "content": "## Send data to message\n\n**Set: event field**\nMerge all webhook events before summarizing\n\n**Summarize**\nCount how many events were received to send a compact message.\nUse `{{$json.count}}` in the Sla"
      }
    },
    {
      "id": "a60fc605-925d-43e9-a407-8abcafe8d01b",
      "name": "Slack: send summary",
      "type": "n8n-nodes-base.slack",
      "position": [
        2928,
        960
      ]
    },
    {
      "id": "1c9a3da9-5b89-46ed-86c3-a3c403625721",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        240,
        432
      ],
      "parameters": {
        "width": 1232,
        "height": 1248,
        "content": "## Get Webhook\n\n**Webhook: Meta (ad_account)**\n- Set the webhook **path** (Callback URL).\nThis is where Meta will send webhook events and where the workflow starts.\nUse the **Production URL** for live"
      }
    }
  ],
  "connections": {
    "Summarize": {
      "main": [
        [
          {
            "node": "Slack: send summary",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Route: field": {
      "main": [
        [
          {
            "node": "Respond Creative Fatigue",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Respond Ad Recommendations",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Respond Async Creation",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Respond In Process",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Respond Product Set Issue",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Respond With Issues",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Verify: token": {
      "main": [
        [
          {
            "node": "Respond: challenge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set: event field": {
      "main": [
        [
          {
            "node": "Summarize",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log Async Creation": {
      "main": [
        [
          {
            "node": "Set: event field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Respond In Process": {
      "main": [
        [
          {
            "node": "Split Out Accounts Pr",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Respond With Issues": {
      "main": [
        [
          {
            "node": "Split Out Accounts Issues",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log Creative Fatigue": {
      "main": [
        [
          {
            "node": "Set: event field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Changes CF": {
      "main": [
        [
          {
            "node": "Log Creative Fatigue",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Changes Pr": {
      "main": [
        [
          {
            "node": "Log In-process ad objects",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Accounts CF": {
      "main": [
        [
          {
            "node": "Split Out Changes CF",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Accounts Pr": {
      "main": [
        [
          {
            "node": "Split Out Changes Pr",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log Ad Recommendations": {
      "main": [
        [
          {
            "node": "Set: event field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log product set issues": {
      "main": [
        [
          {
            "node": "Set: event field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Respond Async Creation": {
      "main": [
        [
          {
            "node": "Split Out Accounts AsCr",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Changes AsCr": {
      "main": [
        [
          {
            "node": "Log Async Creation",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Accounts AsCr": {
      "main": [
        [
          {
            "node": "Split Out Changes AsCr",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Changes AdRec": {
      "main": [
        [
          {
            "node": "Log Ad Recommendations",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Respond Creative Fatigue": {
      "main": [
        [
          {
            "node": "Split Out Accounts CF",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Accounts AdRec": {
      "main": [
        [
          {
            "node": "Split Out Changes AdRec",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log In-process ad objects": {
      "main": [
        [
          {
            "node": "Set: event field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Respond Product Set Issue": {
      "main": [
        [
          {
            "node": "Split Out Accounts SetIssue",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Accounts Issues": {
      "main": [
        [
          {
            "node": "Split Out Changes SetIssue1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Log with-issues ad objects": {
      "main": [
        [
          {
            "node": "Set: event field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Respond Ad Recommendations": {
      "main": [
        [
          {
            "node": "Split Out Accounts AdRec",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Changes SetIssue": {
      "main": [
        [
          {
            "node": "Log product set issues",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Webhook: Meta (ad_account)": {
      "main": [
        [
          {
            "node": "Route: verification vs webhook",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Route: verification vs webhook",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Accounts SetIssue": {
      "main": [
        [
          {
            "node": "Split Out Changes SetIssue",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Out Changes SetIssue1": {
      "main": [
        [
          {
            "node": "Log with-issues ad objects",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Route: verification vs webhook": {
      "main": [
        [
          {
            "node": "Verify: token",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Route: field",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}