Apps Script workflow to generate invoice rows, render PDFs, and email them from Google Sheets.
- Generates transaction rows with formulas and lookups.
- Creates invoice PDFs from a Docs template.
- Sends invoices using Gmail draft templates.
Apps Script, Google Sheets, Gmail, Google Drive
Initialize_sheets.js- setup notes and formulas for sheet structure.txn_generator.js- transaction generation helpers.pdf_generator.js- PDF generation for invoices.mail_merge.js- email invoices via Gmail draft.
- Open the Google Sheet and go to Extensions -> Apps Script.
- Paste the scripts into the project.
- Review sheet/tab names referenced in the scripts and update as needed.
- Create a Gmail draft used by
mail_merge.js.
- Run initialization steps to create headers and formulas.
- Generate transactions, build PDFs, then send emails.
- Gmail quotas apply.