{% extends "admin/base.html" %} {% block title %}Lead Campaigns | Admin{% endblock %} {% block content %}
Outreach
Generate per-lead tracking links for a vehicle, see who visited, and reply with AI-generated emails.
Used by the AI to draft replies for every campaign. Reference the lead by name and the vehicle by year/make/model.
Paste leads from AutoTrader etc. Separate each lead with a blank line. First line = car + $price + CAS-#### stock number or the VIN (one of them required, anywhere in the block), then the message, then name, then phone (optional), then email. Each lead is assigned by exact CAS/VIN first; if neither is present, the title is looked up in the title → stock# reference (right) to auto-assign the car. Without a match it goes to "Unassigned Leads" for manual assignment.
One mapping per line: Title $price|CAS-####. Shows all current mappings — add new rows at the bottom and Update. Duplicates are ignored; the most recent mapping wins, so to correct an entry just add a new line. When a pasted lead has no CAS/VIN, its title is looked up here to auto-assign the car.
| Label | Vehicle | Links | Visited | Replies sent | Drafts | Errors | To reply | Texted | Created | Actions |
|---|---|---|---|---|---|---|---|---|---|---|
| {{ c.label or '—' }} | {{ c.title_en or '—' }} {{ c.public_stock_number or c.stock_number or '' }} |
{{ c.link_count }} | {{ c.visited_count }}/{{ c.link_count }} | {{ c.sent_count }}/{{ c.link_count }} | {{ c.drafted_count }} | {% if c.error_count %}{{ c.error_count }}{% else %}—{% endif %} | {{ c.missing_count }} | {{ c.texted_count }}/{{ c.phone_count }} | {{ (c.created_at or '')[:10] }} | |
| No campaigns yet. Create one above. | ||||||||||