Filter Typeform leads by service area with a drive-time map

The moment someone fills out your intake form, check if their address is inside your service area and post a Slack alert with drive time and a map.

Agentic Task
TypeformMapboxSlack BotSalesOperationsLead EnrichmentNotifications & Alerts
PromptCreate

Build me an agent workflow that qualifies inbound Typeform leads by whether they fall inside my service area, so my ops team stops wasting time on leads we can't reach.

Trigger: a Typeform webhook, fired every time someone submits my intake form. The form collects the prospect's name, phone, service they want, and an address (street, city, state, zip). Configure the webhook end-to-end so I don't have to touch the Typeform dashboard.

Configurable inputs I want to set once at setup time:

- My HQ / dispatch address (or its longitude,latitude).

- Service-area drive-time in minutes (default 30).

- Slack channel id for qualified leads.

- Slack channel id for out-of-area leads (also used for ambiguous / ungeocodable addresses).

- A short 'suggested next action' string to append to qualified-lead messages (e.g. 'call within 5 minutes').

On each submission, do this:

1. Pull the address, name, phone, and requested service out of the Typeform payload.

2. Call Mapbox Forward Geocode (v6) on the lead's address to get its longitude,latitude. Prefer high-confidence matches; if the result is ambiguous, low-confidence, or empty, skip to the 'needs manual review' branch below (do not silently drop the lead).

3. Call Mapbox Get Isochrone from my HQ coordinates for the configured drive-time (minutes contour, driving profile) to get the service-area polygon.

4. Determine whether the geocoded lead point sits inside that isochrone polygon (standard point-in-polygon check).

5. Call Mapbox Get Directions from HQ to the lead's coordinates (driving-traffic profile) to get a live drive-time in minutes and distance.

6. Call Mapbox Get Static Map Image to render a PNG that overlays: the isochrone polygon (semi-transparent fill), an HQ marker, and a lead marker. Size it for Slack (about 800x500).

Then branch:

- Inside service area: post a Send a Message to the qualified-leads Slack channel with the lead's name, phone, requested service, formatted address, live drive time in minutes, and the static-map image. End with the configured 'suggested next action' line so the on-call rep knows exactly what to do.

- Outside service area: post a briefer Send a Message to the out-of-area Slack channel with the address and drive time so ops has a paper trail. Include the static map so we can eyeball whether it's worth making an exception.

- Ambiguous or ungeocodable address: post to the out-of-area channel with the raw address, the Typeform response id, and a clear 'needs manual review' note. Do not drop the lead silently.

Keep the message formatting clean and scannable in Slack (fielded key/value lines, not a wall of text). Every submission should end up posted somewhere so nothing is lost.

What does this prompt do?

  • Watches your Typeform intake form and reacts the second someone submits it.
  • Turns the lead's address into a location, then checks whether it sits inside a drive-time zone around your office (default 30 minutes).
  • Posts qualified leads to your 'new qualified leads' Slack channel with contact info, requested service, live drive time, and a map preview.
  • Posts out-of-area leads to a separate Slack channel so ops has a paper trail and can decide whether to make an exception.

What do I need to use this?

  • A Typeform account with an intake form that collects address, name, phone, and the service the lead is asking about.
  • A Mapbox account (free tier works for most small businesses).
  • A Slack workspace with two channels: one for qualified leads, one for out-of-area leads.
  • The address of your office or dispatch hub, and how many minutes of drive time you consider 'in service area'.

How can I customize it?

  • Change the drive-time radius. 30 minutes is the default; bump it to 45 or 60 for wider coverage, or drop to 15 for dense urban service areas.
  • Pick which Slack channels get qualified leads versus out-of-area leads, and tune the message copy for each.
  • Add a suggested next action to the qualified-lead message, like 'call within 5 minutes' or a booking link for the requested service.

FAQs

What happens if the address is misspelled or too vague to place on a map?
Instead of silently dropping the lead, we post it to your out-of-area channel flagged 'needs manual review' with the raw address, so a human on your team can decide what to do.
Do I need to build a map or do any coding?
No. The workflow renders the map for you and drops it straight into the Slack message. You only tell it where your office is and how many minutes out is considered in service area.
Can I use this for a business that isn't home services?
Yes. It works for anything gated by geography: mobile pet care, catering, appliance repair, HVAC, cleaning, mobile beauty, tutoring, in-home fitness, event DJs, and similar. If your form collects an address and you have a service-area radius, this fits.
Will out-of-area leads be lost forever?
No. Every out-of-area submission still lands in a dedicated Slack channel with the address and drive time, so your team can make exceptions or refer them out. Nothing is dropped.
How fast does it react to a new form submission?
It runs the moment Typeform sends the submission, usually within a few seconds, so your team can call qualified leads while they are still on your site.

Related templates

Build a credential rotation checklist when someone leaves

When someone leaves, we check which shared passwords they used in their final months and post a ranked rotation list to your security channel.

1Password
Rippling
Slack Bot
+1
Agentic Task
Weekly Amazon S3 bucket security audit posted to Slack

Every Monday, check every S3 bucket for public exposure, missing encryption and weak backup settings, then get the risks ranked in Slack.

Amazon S3
Slack Bot
Google Sheets
Agentic Task
Log Agorapulse social conversations to HubSpot contacts

Twice every weekday, the conversations from your social inbox land on the right HubSpot contact timelines, with a Slack recap for sales.

Agorapulse
HubSpot
Slack Bot
Agentic Task
Clean up HubSpot contacts from your Amazon SES suppression list

Every morning, find the addresses that hard bounced or filed a spam complaint, update the matching HubSpot contacts, and post a short Slack recap.

Amazon SES
HubSpot
Slack Bot
Agentic Task
Draft polite follow-ups for emails that never got a reply

Every weekday at 4pm, spot the threads that went quiet, stage a ready-to-send nudge in your mailbox, and get a ranked Slack recap.

Aurinko
Google Sheets
Slack Bot
Agentic Task
Replay failed SQS messages when a bug fix is merged

When you merge a fix in GitHub, this agent checks the matching dead-letter queue, replays the failed messages, and reports back on the pull request and in Slack.

Amazon SQS
GitHub
Slack Bot
Agentic Task

Stop wasting sales time on leads you can't serve.

Connect Typeform, Mapbox, and Slack once. Every new intake gets gated by your service area and lands in the right channel with a map.