Forms: create a hosted lead form for a client
create_lead_formCreate a lead form that Agency Autopilot hosts for a client, and get the two-line embed snippet for the site. Each lead is stored here first, then delivered to the CRM the agency chooses: its HighLevel sub-account (through the existing connection), HubSpot (a private-app token) or any CRM through a signed webhook (Zapier, Make, Jobber…). HubSpot tokens and webhook addresses are entered on the dashboard page this returns, never in chat. On submit the form fires generate_lead and sends people to the thank-you page, so Ads and Analytics keep counting. Because Agency Autopilot hosts it, form_test can test it end to end.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| crm | No | none | |
| accent | No | Button colour as a hex code, e.g. #1f6f4a | |
| button | No | Button text, e.g. "Get my free quote" | |
| client | Yes | Client name from list_clients | |
| fields | No | Fields in order. Default: first name, last name, phone, email, message. | |
| confirm | No | Leave false to preview: nothing changes and the preview shows exactly what would happen. Set true only after the user has agreed to this exact change. | |
| services | No | Choices for the service field, if used | |
| copy_leads_to | No | Optional: a hidden copy (BCC) of each of those lead emails, e.g. the agency owner. Needs email_leads_to. | |
| thank_you_url | No | Full https:// address of the page to send people to after submitting (where the conversion tags fire). Strongly recommended. | |
| email_leads_to | No | Optional, off by default: an address (usually the client's) that gets an email for every real lead, with everything the person typed. Needs crm highlevel; it sends from that sub-account. Ask before setting it. | |
| highlevel_location_id | No | HighLevel sub-account for the leads; defaults to the client's linked one |