Creates the lead spreadsheet the inbound triage templates read from, with the right tabs, headers and sample data.
Uses
Google Sheets
Inbound lead workspace setup
Run it once by hand, before the inbound lead triage and nurture workflows, and it builds the spreadsheet they both read and write: a new Google Sheets workbook called 'Inbound leads' with four tabs, 'New leads' for form submissions, 'Accounts' for companies you already own, 'Reps' for who can receive leads and 'Ledger' for every decision made about every lead.
Each tab gets its heading row written for you, so nobody has to get forty headings right by hand. Two sample leads go into 'New leads': a genuine buyer with a deadline and a competitor named, and an agency pitching services that looks good on paper and is worthless to a rep, so you can watch the routing workflow route one and drop the other. Placeholder rows on 'Reps' and 'Accounts' mark where a real teammate and their Slack ID go, and the run ends with the new spreadsheet's link.
Only Google Sheets needs to be connected. Each run creates a fresh spreadsheet and leaves any earlier one alone, so it is safe to run again.
spreadsheetTitle to Inbound leads.Set spreadsheetTitle to Inbound leads.spreadsheetTitle. Save it as newSheet.Create spreadsheet spreadsheetTitle. Save it as newSheet.newSheet.spreadsheet_url and save it as spreadsheetUrl.Trim newSheet.spreadsheet_url and save it as spreadsheetUrl.spreadsheetUrl is emptyIf spreadsheetUrl is emptyspreadsheetUrl.Create the tab 'New leads' in spreadsheetUrl.spreadsheetUrl.Add a row to 'New leads' in spreadsheetUrl.spreadsheetUrl.Create the tab 'Accounts' in spreadsheetUrl.spreadsheetUrl.Add a row to 'Accounts' in spreadsheetUrl.spreadsheetUrl.Create the tab 'Reps' in spreadsheetUrl.spreadsheetUrl.Add a row to 'Reps' in spreadsheetUrl.spreadsheetUrl.Create the tab 'Ledger' in spreadsheetUrl.spreadsheetUrl.Add a row to 'Ledger' in spreadsheetUrl.spreadsheetUrl.Add a row to 'New leads' in spreadsheetUrl.spreadsheetUrl.Add a row to 'New leads' in spreadsheetUrl.spreadsheetUrl.Add a row to 'Accounts' in spreadsheetUrl.spreadsheetUrl.Add a row to 'Reps' in spreadsheetUrl.deleteErrorIf a step below fails, save the error as deleteErrorspreadsheetUrl.Delete the tab 'Sheet1' from spreadsheetUrl.Left the default 'Sheet1' tab in place - it is unused and safe to delete by hand..Show in the output: Left the default 'Sheet1' tab in place - it is unused and safe to delete by hand..spreadsheetUrl
Next, four things:
1. Copy that URL into the 'spreadsheetUrl' setting at the top of BOTH 'Route every new sales enquiry to the right rep' and 'Chase leads nobody has picked up and nurture the not-yet-ready'.
2. Replace every REPLACE_ME__ value in the sheet. On 'New leads', use two addresses you actually control - made-up ones are correctly judged undeliverable and both leads get dropped, which makes for a dull first run. On 'Reps' and 'Accounts', put a real teammate; the Slack ID is the one that looks like U01234567, from their Slack profile under 'Copy member ID'.
3. On 'Accounts', the Domain cell must be the domain of the addresses you just put in 'New leads'. That is what sends a lead from a company someone already owns straight to that person instead of into the round robin - the most useful rule in the whole workflow, and it silently never fires if the two disagree.
4. Two sample leads are waiting on 'New leads'. One is a genuine buyer and one is an agency pitching you, so the first run shows both paths: one Slack alert with a drafted reply, and one quiet drop recorded in the Ledger.
Point your real form at the 'New leads' tab when you are ready. The column headers are the contract - the routing workflow checks them and will tell you if they drift.