Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.affzero.com/llms.txt

Use this file to discover all available pages before exploring further.

What is the Invoice System?

AffZero’s invoice system lets you create professional PDF invoices with live affiliate data filled in automatically. Invoices are generated from templates — either HTML designs you build in AffZero or Google Docs you already manage. The typical flow:
  1. Design an invoice template (HTML or Google Doc)
  2. Add a Create Invoice step to an automation
  3. The step substitutes your stats variables into the template and produces a PDF
  4. A following Send Email step attaches and delivers the PDF to the affiliate

Two Template Types

HTML Templates

Design your invoice layout in HTML/CSS with full control over fonts, colors, and structure. Best for custom branded invoices.

Google Doc Templates

Use a Google Doc as your template. AffZero replaces variable placeholders and exports to PDF. Best for teams already working in Google Workspace.

Invoice Sections

The Invoices menu has three subsections:

Invoices → Templates

All your invoice template designs. Create, edit, preview, and delete templates here. Templates are reusable across multiple automations.

Invoices → Generated

A history of every PDF invoice that has been generated by an automation. You can view, download, or delete generated invoices. Each entry shows:
  • The template used
  • The automation and run that created it
  • The filename and generation timestamp
  • A download link for the PDF

Invoices → Invoice Numbering

Configure the global invoice sequence. Once set up, every Create Invoice step automatically generates {invoice_number_global} — no separate numbering step needed. Configure it once and every automation gets the correct next number. See Invoice Numbering for full details.

Using Variables in Invoices

Invoice templates support the same variable system as email templates. Any variable available at the point in the automation where the Create Invoice step runs can be placed in the template:
<p>Affiliate: {affiliate_name_1_stats_1}</p>
<p>Revenue: {revenue_1_stats_1}</p>
<p>Payout: {payout_1_stats_1}</p>
<p>Invoice Number: {invoice_number_global}</p>
At generation time, AffZero substitutes each placeholder with the real value.

Common Invoice Workflow

Here’s a complete end-to-end invoice automation:
1

Pull Stats

Fetch the affiliate’s monthly revenue and payout data using a Pull Stats step with “Last Month” date preset.
2

Invoice Number (automatic)

If you’ve configured Invoice Numbering, {invoice_number_global} is generated automatically by the Create Invoice step — no separate step needed. Add a Generate Invoice Number step only if you need a secondary per-automation sequence.
3

Create Invoice

Select your HTML or Google Doc template. The payout, affiliate name, invoice number, and other variables are substituted into the template and a PDF is generated.
4

Send Email

Send an email with the PDF attached. The email body can also reference the same variables to include a summary before the attachment.