{
  "name": "Datahyena - Target account monitoring (all signals)",
  "nodes": [
    {
      "id": "687cd715-3f6a-4444-ac4c-1910faa3c5a6",
      "name": "About this workflow",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -520,
        -300
      ],
      "parameters": {
        "width": 480,
        "height": 460,
        "content": "## Target account monitoring (all signals)\n\n**How it works**\nWatches funding, acquisitions, and exec moves and alerts you when any of them hits a company on your target list. Your intent layer on your own accounts.\n\n**Setup**\n1. On each **Fetch** node, set up a Header Auth credential (Name: `X-API-Key`, Value: your Datahyena key). Free at https://datahyena.com\n2. In **Target Accounts**, edit the `domains` array with your accounts.\n3. Connect Slack on the three **Post** nodes, pick a channel, activate."
      },
      "typeVersion": 1
    },
    {
      "id": "126b40c0-53ba-4f0f-ade4-507b92282688",
      "name": "Every Morning at 9am",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -480,
        300
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "days",
              "daysInterval": 1,
              "triggerAtHour": 9
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "b1e61b33-4ad8-4dcc-bfff-ebbf4ba31e32",
      "name": "Target Accounts",
      "type": "n8n-nodes-base.code",
      "position": [
        -240,
        300
      ],
      "parameters": {
        "jsCode": "// EDIT: the company domains you want to watch\nreturn [{ json: { domains: ['stripe.com', 'notion.so', 'ramp.com'] } }];"
      },
      "typeVersion": 2
    },
    {
      "id": "86f6a78d-0d0c-4f61-be57-481f25ea9c4f",
      "name": "Funding signals on your accounts",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        140,
        -130
      ],
      "parameters": {
        "color": 7,
        "width": 1240,
        "height": 260,
        "content": "## Funding signals on your accounts\nA round at one of your accounts."
      },
      "typeVersion": 1
    },
    {
      "id": "57b68ac8-9af0-4195-87f5-d34e40830ee0",
      "name": "Acquisition signals on your accounts",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        140,
        170
      ],
      "parameters": {
        "color": 7,
        "width": 1240,
        "height": 260,
        "content": "## Acquisition signals on your accounts\nOne of your accounts is an acquirer or target."
      },
      "typeVersion": 1
    },
    {
      "id": "127b112c-c4ce-4be4-990f-eb63540061f2",
      "name": "Exec-move signals on your accounts",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        140,
        470
      ],
      "parameters": {
        "color": 7,
        "width": 1240,
        "height": 260,
        "content": "## Exec-move signals on your accounts\nA leader joins or leaves one of your accounts."
      },
      "typeVersion": 1
    },
    {
      "id": "eb78d0ec-4577-4eac-a782-2ac8472965e4",
      "name": "Fetch Funding",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        200,
        0
      ],
      "parameters": {
        "url": "https://api.datahyena.com/v1/funding-events",
        "options": {},
        "sendQuery": true,
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "queryParameters": {
          "parameters": [
            {
              "name": "limit",
              "value": "50"
            },
            {
              "name": "since",
              "value": "={{ $now.minus({ days: 1 }).toISO() }}"
            }
          ]
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "08e0fdc9-1d48-4bab-9dcf-4278a2bc4e1b",
      "name": "Split Funding",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        500,
        0
      ],
      "parameters": {
        "options": {},
        "fieldToSplitOut": "data"
      },
      "typeVersion": 1
    },
    {
      "id": "4c3e34d5-92a2-476b-9ed2-2190d493ff35",
      "name": "Funding on My Accounts",
      "type": "n8n-nodes-base.code",
      "position": [
        800,
        0
      ],
      "parameters": {
        "jsCode": "const domains = $('Target Accounts').first().json.domains.map((d) => d.toLowerCase());\nreturn $input.all().filter((it) => {\n  const d = ([it.json.company && it.json.company.domain]).filter(Boolean).map((x) => x.toLowerCase());\n  return d.some((x) => domains.includes(x));\n});"
      },
      "typeVersion": 2
    },
    {
      "id": "2f751b41-4d52-4622-999d-ff9a3e779fb7",
      "name": "Post Funding to Slack",
      "type": "n8n-nodes-base.slack",
      "position": [
        1100,
        0
      ],
      "parameters": {
        "text": "=:moneybag: *{{ $json.company.name }}* (on your list) raised {{ $json.amountUsd ? '$' + ($json.amountUsd / 1000000) + 'M' : 'a round' }}{{ $json.round ? ' (' + $json.round + ')' : '' }}\n{{ $json.company.domain }} \u00b7 {{ ($json.announcedAt || '').slice(0, 10) }}\n{{ ($json.sources && $json.sources.length) ? 'Sources: ' + $json.sources.map((s, i) => '<' + s.url + '|source ' + (i + 1) + '>').join(', ') : '' }}",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultName": ""
        },
        "otherOptions": {}
      },
      "credentials": {
        "slackApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.3
    },
    {
      "id": "5c10958b-1e71-47ea-95e0-844df316ebb0",
      "name": "Fetch Acquisitions",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        200,
        300
      ],
      "parameters": {
        "url": "https://api.datahyena.com/v1/acquisitions",
        "options": {},
        "sendQuery": true,
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "queryParameters": {
          "parameters": [
            {
              "name": "limit",
              "value": "50"
            },
            {
              "name": "since",
              "value": "={{ $now.minus({ days: 1 }).toISO() }}"
            }
          ]
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "95ad55ff-016d-4296-a4c3-3ba11c6a79a3",
      "name": "Split Acquisitions",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        500,
        300
      ],
      "parameters": {
        "options": {},
        "fieldToSplitOut": "data"
      },
      "typeVersion": 1
    },
    {
      "id": "c69301f5-53b9-4162-ac43-104b7eb1a8ca",
      "name": "Acquisitions on My Accounts",
      "type": "n8n-nodes-base.code",
      "position": [
        800,
        300
      ],
      "parameters": {
        "jsCode": "const domains = $('Target Accounts').first().json.domains.map((d) => d.toLowerCase());\nreturn $input.all().filter((it) => {\n  const d = ([it.json.acquirer && it.json.acquirer.domain, it.json.target && it.json.target.domain]).filter(Boolean).map((x) => x.toLowerCase());\n  return d.some((x) => domains.includes(x));\n});"
      },
      "typeVersion": 2
    },
    {
      "id": "c0b7e766-0d4f-494a-8637-d7360f1ad103",
      "name": "Post Acquisitions to Slack",
      "type": "n8n-nodes-base.slack",
      "position": [
        1100,
        300
      ],
      "parameters": {
        "text": "=:handshake: *{{ $json.acquirer.name }}* {{ $json.isMerger ? 'merged with' : 'acquired' }} *{{ $json.target.name }}* (on your list)\n{{ ($json.announcedAt || '').slice(0, 10) }}\n{{ ($json.sources && $json.sources.length) ? 'Sources: ' + $json.sources.map((s, i) => '<' + s.url + '|source ' + (i + 1) + '>').join(', ') : '' }}",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultName": ""
        },
        "otherOptions": {}
      },
      "credentials": {
        "slackApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.3
    },
    {
      "id": "d3286ed9-6ab4-4441-ad9d-20160265c1b0",
      "name": "Fetch Exec Moves",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        200,
        600
      ],
      "parameters": {
        "url": "https://api.datahyena.com/v1/exec-moves",
        "options": {},
        "sendQuery": true,
        "authentication": "genericCredentialType",
        "genericAuthType": "httpHeaderAuth",
        "queryParameters": {
          "parameters": [
            {
              "name": "limit",
              "value": "50"
            },
            {
              "name": "since",
              "value": "={{ $now.minus({ days: 1 }).toISO() }}"
            }
          ]
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "f5ad73bc-ca38-46ed-9044-05d5262cdc8d",
      "name": "Split Exec Moves",
      "type": "n8n-nodes-base.splitOut",
      "position": [
        500,
        600
      ],
      "parameters": {
        "options": {},
        "fieldToSplitOut": "data"
      },
      "typeVersion": 1
    },
    {
      "id": "990ea8cb-4a29-4f04-b261-b2aab1c09e01",
      "name": "Exec Moves on My Accounts",
      "type": "n8n-nodes-base.code",
      "position": [
        800,
        600
      ],
      "parameters": {
        "jsCode": "const domains = $('Target Accounts').first().json.domains.map((d) => d.toLowerCase());\nreturn $input.all().filter((it) => {\n  const d = ([it.json.company && it.json.company.domain, it.json.fromCompany && it.json.fromCompany.domain]).filter(Boolean).map((x) => x.toLowerCase());\n  return d.some((x) => domains.includes(x));\n});"
      },
      "typeVersion": 2
    },
    {
      "id": "ab65530b-5fbf-4210-93ea-fb46008f70cc",
      "name": "Post Exec Moves to Slack",
      "type": "n8n-nodes-base.slack",
      "position": [
        1100,
        600
      ],
      "parameters": {
        "text": "=:bust_in_silhouette: *{{ $json.person.name }}* ({{ $json.moveType }}) - {{ $json.role }} at *{{ $json.company.name }}* (on your list)\n{{ $json.company.domain }} \u00b7 {{ ($json.announcedAt || '').slice(0, 10) }}\n{{ ($json.sources && $json.sources.length) ? 'Sources: ' + $json.sources.map((s, i) => '<' + s.url + '|source ' + (i + 1) + '>').join(', ') : '' }}",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "list",
          "value": "",
          "cachedResultName": ""
        },
        "otherOptions": {}
      },
      "credentials": {
        "slackApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.3
    }
  ],
  "settings": {
    "executionOrder": "v1"
  },
  "connections": {
    "Fetch Funding": {
      "main": [
        [
          {
            "node": "Split Funding",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Funding": {
      "main": [
        [
          {
            "node": "Funding on My Accounts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Target Accounts": {
      "main": [
        [
          {
            "node": "Fetch Funding",
            "type": "main",
            "index": 0
          },
          {
            "node": "Fetch Acquisitions",
            "type": "main",
            "index": 0
          },
          {
            "node": "Fetch Exec Moves",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Exec Moves": {
      "main": [
        [
          {
            "node": "Split Exec Moves",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Exec Moves": {
      "main": [
        [
          {
            "node": "Exec Moves on My Accounts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Acquisitions": {
      "main": [
        [
          {
            "node": "Split Acquisitions",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Split Acquisitions": {
      "main": [
        [
          {
            "node": "Acquisitions on My Accounts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Every Morning at 9am": {
      "main": [
        [
          {
            "node": "Target Accounts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Funding on My Accounts": {
      "main": [
        [
          {
            "node": "Post Funding to Slack",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Exec Moves on My Accounts": {
      "main": [
        [
          {
            "node": "Post Exec Moves to Slack",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Acquisitions on My Accounts": {
      "main": [
        [
          {
            "node": "Post Acquisitions to Slack",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}