LEAD GENERATION

Route event scans to the right rep by territory using a Postgres ownership table

Resolves each scanned attendee against a Postgres account-ownership table to find the rep who owns that company or territory.

CategoryLead Generation
Enginesim
Difficultyadvanced
Triggerwebhook
Steps6
Setup~25 min

How it runs

The automated pipeline, trigger to output.

  • TriggerScan batch posted to webhookHTTP webhook
  • LogicDedupe batch and extract company domains
  • ActionResolve owner from Postgres ownership tablePostgreSQLPostgres
  • LogicBranch: owned domain vs round-robin fallback
  • ActionCreate assigned lead in HubSpotHubSpotHubSpot
  • OutputNotify assigned rep in SlackSlack

What it does

Your source of truth for who owns which account isn't the CRM — it's a Postgres ownership table keyed by company domain and territory rules. This workflow takes event scans, asks Postgres who the rightful owner is, and creates the HubSpot lead already assigned to that rep, falling back to a round-robin pool when no owner exists.

When to use it

Use it when account ownership is governed by a database (named accounts, geo territories, segment rules) rather than CRM assignment. Run it on each batch of scans so routing always reflects the live ownership model.

How it works

  1. 1A webhook receives a batch of scanned attendees.
  2. 2The flow dedupes the batch and extracts each company domain.
  3. 3Each domain is queried against the Postgres ownership table to resolve the owning rep or territory.
  4. 4A branch handles owned domains versus unowned ones (sent to a round-robin fallback).
  5. 5A HubSpot contact and lead are created, pre-assigned to the resolved owner.
  6. 6The assigned rep is notified in Slack with the lead and the matched territory rule.

Set it up

What you configure once, before turning it on.

  1. 1
    Connect HTTP webhookTrigger any URL on agent actions.
  2. 2
    Connect PostgresAny Postgres URL — query, write, migrate.
  3. 3
    Connect HubSpotCRM, deals, marketing, support.
  4. 4
    Connect SlackChannels, DMs, threads, mentions.
  5. 5
    Set each agent's modelWe leave models unset so you pick the tier — fast + cheap, or top-quality.
  6. 6
    Tune it to your dataEdit the prompts, filters, and field mappings so it matches how your team works.
  7. 7
    Test, then turn it onRun once against a sample, confirm the output, then enable the trigger.

Run this workflow in your colony.

14-day trial. No DevOps. No Sales call. Provisioned in under a minute.