API & Webhooks
Integrate lead sources and email event tracking with LeadFlow's webhook endpoints.
Overview
LeadFlow accepts incoming data through two webhook endpoints — one for new leads from Boberdoo (or any lead provider), and one for email events from Email Bison. Both endpoints are secured and require authentication.
Boberdoo Webhook
Endpoint
Authentication
Include your API key in the X-Api-Key header. Each client workspace has a unique key that determines which agency the lead is routed to. Both agencies use the same webhook URL with different keys.
Core Contact Fields
These fields are extracted from the top level of the payload. Both Boberdoo title-case and snake_case names are accepted.
| Boberdoo Field | Snake_case Alt | Required | Description |
|---|---|---|---|
| lead_id | — | Recommended | External lead ID — used for deduplication |
| Yes | Lead's email address | ||
| First Name | first_name | Yes | Lead's first name — used in email personalization |
| Last Name | last_name | No | Lead's last name |
| Daytime Phone / Cell Phone | phone | No | Phone number |
| Address | address | No | Street address |
| City | city | No | City |
| State | state | No | Two-letter state code (e.g., FL) |
| Zip | zip | No | ZIP code |
Vehicle Fields (Vehicle 1 & Vehicle 2)
Prefix each field with Vehicle 1 or Vehicle 2. If any vehicle fields are present, the lead is auto-classified as insurance_type: "auto".
| Field | Example Key | Description |
|---|---|---|
| Year | Vehicle 1 Year | Vehicle model year |
| Make | Vehicle 1 Make | Vehicle manufacturer |
| Model | Vehicle 1 Model | Vehicle model name |
| Sub Model | Vehicle 1 Sub Model | Vehicle trim/sub-model |
| Vin | Vehicle 1 Vin | Vehicle identification number |
| Ownership | Vehicle 1 Ownership | Owned, Leased, Financed |
| Primary Use | Vehicle 1 Primary Use | Commute, Pleasure, Business |
| Average One Way Mileage | Vehicle 1 Average One Way Mileage | Average one-way commute miles |
| Annual Mileage | Vehicle 1 Annual Mileage | Total annual miles driven |
| Parking | Vehicle 1 Parking | Garage, Driveway, Street |
| Average Days Per Week Used | Vehicle 1 Average Days Per Week Used | Days per week the vehicle is driven |
| Coverage Type | Vehicle 1 Coverage Type | Full Coverage, Liability Only, etc. |
| Desired Collision Coverage | Vehicle 1 Desired Collision Coverage | Deductible amount |
| Desired Comprehensive Coverage | Vehicle 1 Desired Comprehensive Coverage | Deductible amount |
| Security System | Vehicle 1 Security System | Yes or No |
Driver Fields (Driver 1 & Driver 2)
Prefix each field with Driver 1 or Driver 2. These are title-case only — no snake_case alternatives.
| Field | Example Key |
|---|---|
| First Name | Driver 1 First Name |
| Last Name | Driver 1 Last Name |
| Address / City / State / Zip | Driver 1 Address |
| Daytime Phone / Evening Phone / Cell Phone | Driver 1 Cell Phone |
| Driver 1 Email | |
| Birthdate | Driver 1 Birthdate |
| Age | Driver 1 Age |
| Gender | Driver 1 Gender |
| Marital Status | Driver 1 Marital Status |
| Credit Rating | Driver 1 Credit Rating |
| License Status | Driver 1 License Status |
| Licensed State | Driver 1 Licensed State |
| Age When First Licensed | Driver 1 Age When First Licensed |
| Education | Driver 1 Education |
| Occupation | Driver 1 Occupation |
| Current Residence | Driver 1 Current Residence |
| Years At Current Residence | Driver 1 Years At Current Residence |
| Insurance Company | Driver 1 Insurance Company |
| Insured Past 30 Days | Driver 1 Insured Past 30 Days |
| Policy Expiration Date | Driver 1 Policy Expiration Date |
| Insured_Since | Driver 1 Insured_Since |
| Current Insurance Company Years | Driver 1 Current Insurance Company Years |
| Continuously Insured Years | Driver 1 Continuously Insured Years |
| Tickets Accidents Claims Past 3 Years | Driver 1 Tickets Accidents Claims Past 3 Years |
| Suspended Or Revoked In The Past 5 Years | Driver 1 Suspended Or Revoked In The Past 5 Years |
| DUI DWI In The Past 5 Years | Driver 1 DUI DWI In The Past 5 Years |
| Bankruptcy In Past 5 Years | Driver 1 Bankruptcy In Past 5 Years |
| Additional Drivers / Additional Vehicles | Driver 1 Additional Drivers |
| Relationship To Applicant | Driver 1 Relationship To Applicant |
Incident Fields (up to 3 per Driver)
Prefix with Driver N Incident M where N is 1-2 and M is 1-3.
| Field | Example Key |
|---|---|
| Incident Type | Driver 1 Incident 1 Incident Type |
| Approximate Date | Driver 1 Incident 1 Approximate Date |
| Damages | Driver 1 Incident 1 Damages |
| At Fault | Driver 1 Incident 1 At Fault |
| Insurance Paid Amount | Driver 1 Incident 1 Insurance Paid Amount |
Field Summary
| Group | Count |
|---|---|
| Core contact fields | 10 |
| Vehicle 1 + Vehicle 2 | 14 x 2 = 28 |
| Driver 1 + Driver 2 | 32 x 2 = 64 |
| Incidents (3 per driver x 2 drivers) | 5 x 3 x 2 = 30 |
| Optional (insurance_type, source) | 2 |
| Total | 134 |
Full Example Payload
{
"lead_id": "12345",
"First Name": "Sarah",
"Last Name": "Martinez",
"Email": "sarah.martinez@example.com",
"Cell Phone": "9545551234",
"Address": "1234 Coral Way",
"City": "Coral Springs",
"State": "FL",
"Zip": "33065",
"Vehicle 1 Year": "2024",
"Vehicle 1 Make": "Honda",
"Vehicle 1 Model": "Civic",
"Vehicle 1 Ownership": "Owned",
"Vehicle 1 Coverage Type": "Full Coverage",
"Vehicle 1 Annual Mileage": "12000",
"Driver 1 First Name": "Sarah",
"Driver 1 Last Name": "Martinez",
"Driver 1 Age": "28",
"Driver 1 Gender": "Female",
"Driver 1 Marital Status": "Single",
"Driver 1 Credit Rating": "Good",
"Driver 1 License Status": "Active",
"Driver 1 Licensed State": "FL",
"Driver 1 Insurance Company": "GEICO",
"Driver 1 Insured Past 30 Days": "Yes",
"Driver 1 Tickets Accidents Claims Past 3 Years": "0"
}Response
| HTTP Code | Body | Meaning |
|---|---|---|
| 200 | {"status": "received", "client": "greg-blanchard"} | Lead accepted and queued for AI processing |
| 200 | {"status": "duplicate", "client": "greg-blanchard"} | Lead already processed (deduped by lead_id) |
| 401 | {"detail": "Invalid API key"} | API key not found or client inactive |
| 429 | {"detail": "Rate limit exceeded"} | Too many requests — retry after Retry-After header |
cURL Example
curl -X POST https://api.leadflowss.com/api/v1/webhooks/boberdoo \
-H "Content-Type: application/json" \
-H "X-Api-Key: YOUR_API_KEY_HERE" \
-d '{
"lead_id": "12345",
"First Name": "John",
"Last Name": "Smith",
"Email": "john@example.com",
"Cell Phone": "5615551234",
"City": "Palm Beach Gardens",
"State": "FL",
"Zip": "33410",
"Vehicle 1 Year": "2024",
"Vehicle 1 Make": "Toyota",
"Vehicle 1 Model": "Camry",
"Driver 1 Age": "36",
"Driver 1 Insurance Company": "State Farm"
}'What Happens After
- Lead is deduplicated by
lead_idand stored - AI drafts a personalized email using the lead's vehicle, location, and insurance data
- Email is sent via Email Bison within seconds
- Lead appears in your dashboard under Conversations
- When the lead replies, the AI classifies the intent (interested, question, not interested)
- Interested leads are escalated — agent is CC'd on a handoff email
Email Event Webhook (Bison)
Endpoint
Tracked Events
Email Bison sends event notifications for the following actions:
| Event | Description | Dashboard Effect |
|---|---|---|
| reply | Lead replied to an email | New message in conversation thread + AI classification |
| delivered | Email was delivered successfully | Delivery confirmation in email events |
| bounced | Email bounced (invalid address) | Lead marked, bounce rate updated |
| opened | Lead opened the email | Open event tracked in analytics |
| clicked | Lead clicked a link in the email | Click event tracked in analytics |
| unsubscribed | Lead opted out | Lead suppressed — no further emails sent |
Rate Limits
| Endpoint | Limit | Window |
|---|---|---|
| Boberdoo webhook | 120 requests | Per 60 seconds per IP |
| Bison webhook | 120 requests | Per 60 seconds per IP |
If you exceed the rate limit, you'll receive a 429 Too Many Requests response with a Retry-After header indicating when you can retry.